XCode still sucks

Nope. I was right the first time. XCode sucks.

Getting back to work on Sea Glass

I’ve been taking a break for the past month or so, playing with mobile device development. I’ll get back to that, but it’s time to get back to work on Sea Glass.

Databases – persistence layer or primary entity?

So a couple of weeks ago I was in San Francisco talking with Ken Orr and my old high school/college friend Stan Switzer and Stan was holding forth on an idea that I think is pretty self-evidently true.

This is that when considering software systems, the database is the primary entity, and any applications, interfaces, etc., are secondary to it. This contrasts with a certain viewpoint in “software engineering” (more later on that) that a database acts as a sort of “persistence layer” for your software, keeping data across uses, systems, etc.

Though I think you can certainly treat a database as a persistence layer, I think that Stan’s argument is generally valid. In particular, I note that database schemas are notoriously difficult to update, because all the software that uses it must also be updated. For the same reason the data formats themselves tend to become a bit rigid with time and harder to change.

We saw this with the whole Y2K situation, where suddenly the fact that for decades our databases had only stored two digits for a year became important. The people who designed the old software were aware that this would be an issue at the century turnaround, but thought that the software would all be obsolete and replaced by then.

And most of the software was replaced, but the underlying data was not.

Stan pointed to Hibernate as an example of a “persistence layer” that didn’t really believe its own hype, but knew it had to talk the language of the persistence layer folks. Hibernate actually does what you want: it mediates between software and a database such that many crufty database details can be avoided, but without the inherent limitations of APIs and frameworks that are simply persistence layers.

I suppose I’ve always intuitively understood this. Data representation and database design is always done much earlier than any code considerations when I’m working with a project that has much in the way of data.

XCode sucks

Okay, I don’t really have enough experience with it to make that judgment, but I doubt further familiarity will change my opinion.

I’ll be including politics on the main page

I don’t think anyone cares, and I don’t think very many people are reading this blog, so I’m going to start including politics on the main page.

This simplifies my hacks to WordPress.

Against publicizing private lives

“In one short decade we have been reconditioned to be entertained by the most private areas of other people’s lives. We’ve become the family dog who’s allowed to eat anything that falls on the floor, and the press is the little kid in the family who keeps dropping food.” Aaron Sorkin

Sorkin’s larger point is about the Newsweek brouhaha about gay actors playing straight characters, which I, personally, have no problem with. I think Sorkin has the right of it.

We, as a culture, are obsessed with reality TV and celebrity gossip. We spend way too much time thinking about, or even just being informed about the lives of people we don’t know and shouldn’t care about.

Sorkin mentions Sandra Bullock’s divorce, which I admit I have heard of. (I had no idea that there was a current person named Jesse James, though. Strange.) He’s right. We shouldn’t care much about what happens in Bullock’s life, unless we know her or are her friend. Yes, I know, most religions do say we are each others’ keepers, and I tend to agree with that, but in the case of someone so unconnected with me I’ll leave it to her friends to worry about, and also the laws of our country.

I don’t care that Rock Hudson was, or Neil Patrick Harris for that matter is, gay, except insofar as their being closeted or out tells us something about our society. I never met Hudson and am unlikely to meet Harris. They’re both fine actors. That’s the only material point.

Now to contradict myself, partially. I don’t tend to watch Mel Gibson movies, partly because he’s a homophobic jerk, but mostly because there’s a point of view expressed in the movies that I don’t care for. (Yes, I’ve seen Braveheart.) That’s one example among many.

And I don’t object to outing closeted gay people when their public actions are causing great harm to the LGBT community. I think that kind of hypocrisy is despicable.

But the larger point remains, only partially obscured by the fact of human existence being a messy thing. I think it’s rare to be able to make blanket judgments of actions that could be taken in an abstract situation.

Anyway, these are just some random thoughts on the subject, based on seeing Sorkin’s article and seeing several people lift the same quote I did from it. In closing, I leave you with Walt Whitman:

Do I contradict myself?
Very well then I contradict myself,
(I am large, I contain multitudes.)
    Walt Whitman, “Song of Myself”

I modified a recipe

I was in the mood for an old recipe I got from my Dad, a zucchini frittata with cream cheese, zucchini, and other miscellaneous vegetable plus soft bread cubes in a custard. But it wanted a cup of black olives and I’m rather off olives these days…

So I decide that pancetta would be a good change. cube and render it and press out as much grease as possible, reserving just a bit in lieu of the vegetable oil that the veggies would normally be sauteed in. Then proceed as with the old recipe.

It was great! I’ll make it again!

(I’m eating the last of it as leftovers. It’s better than the first day.)

Here is the recipe for what I made. The original recipe used 1 cup of sliced black olives instead of the pancetta and sauteed them with the other veggies in 2 teaspoons of olive oil.

The web page with the recipe is printable. The print margins are larger than the on-screen margins.

Developing for the iPhone

Man, Android is a lot easier to develop for than the iPhone. Admittedly, part of this is my detestation for Objective C, but part of it is that the Android framework is very simple.

I’m having a really hard time forcing myself to even look at Objective C, let alone write it.

Mobile platform comments

I’ve recently downloaded the Palm WebOS SDK, the iPhone SDK, and the Android SDK and have been playing with developing for them. I doubt I’ll ever do anything serious, so it’s not a critical issue for purchasing a tablet.

Having written some play apps for all three I have the following observations, which are entirely my opinions, backed up with 30 years of professional programming.

Palm WebOS
I’d say that this operating system is in many ways the slickest and easiest to develop for. The Palm Pre emulator is pretty nice too. Conceptually, this is the most clean and clear operating system.

But they don’t make a tablet, and given that this is Palm, why isn’t the calendar better? In week view it doesn’t show you the names of the events, just their color and when and how long.

Of course, it’s been some years since I owned a Palm PDA and maybe I’m misremembering the built-in calendar app. I always used DateBook from Pimlico software.

I’m not a big fan of JavaScript as a development language, though.

But hey, you could probably develop for WebOS in DreamWeaver!

Google Android
This is the clunkiest operating system of the three in my opinion. Or maybe it’s just the emulator. But it’s pretty easy to develop for. It’s actually quite fun to develop for Android. And it’s not hard to use, just a bit unpolished with its look and feel.

Android has the most options in the tablet market, and that’s partly what I’m interested in, so I’m giving it a very close look.

Its calendar is excellent, especially if you wanted to sync with Google Calendars, which I’m not averse to doing. The only problem with the built-in apps is that having adding a website to a contact in their Contacts app, it doesn’t take you to the browser and open that page when you click on the website on the contact screen. This should be easy to fix, but given that this is Google, it’s rather a glaring deficiency.

I usually program in Java, so having Java as the default programming language for Android is nice for me. They don’t use the usual virtual machine and they use some different APIs for creating the look and feel, but they’re not hard to learn to use and I understand their reasons for doing what they did in most cases.

Android has been the most fun to work with.

Apple iPhone OS
Okay, I already have an iPhone. I’ve looked at the iPad. This is the mobile operating system where all the design went. All the built-in apps work together seamlessly. And it looks great! And the emulator is decent, though not zippy.

The only complaint I’ve had after using an iPhone for a year and a half is that you can’t set calendar events at arbitrary times, and you can’t set alarms at arbitrary times. And having an alarm at the time in iCal doesn’t sync correctly to the iPhone. They have their set of times and intervals and you will use them.

On the other hand, it hasn’t been a show stopper, and if I want an alarm at a specific time, there’s the Clock application, which serves the need.

Memo functions on the iPhone are very weak and have not gotten a lot better, although you can now sync in a lame fashion to your desktop. I use the SyncBook app to handle that. I tried EverNote, but got frustrated. I tried FliqNotes but got even more frustrated.

And why does Apple charge $100 for their SDK if you want to distribute your app? Just to keep out riffraff? I’m tempted to ask if anyone in the computer world’s head is as big as Steve Jobs’s and then I remember Larry Ellison.

Anyway, the biggest obstacle to me developing for the iPhone OS is Objective C. I despise the language. It’s C with SmallTalk grafted onto it. It’s a stylistically bastardized language.

I will force myself to port my Hexaflexagon flexing app to the iPhone and we’ll see what I think after that.

Common comments:

Why don’t the people that make the emulators include buttons to simulate accelerometer functions, such as shaking and turning the device on its side? Only the Apple people seem to have that, at least on the Mac. That would be very useful. Also, they should all have a way to supply a fake GPS location.

Anyway, that’s my set of observations and opinions.

Trying to sync to facebook again

We’ll see if this works.