Archive for March 17th, 2005

March 17th, 2005

SD West 2

by Tim Cull

Back to waiting for Citrix to bring up Outlook for me, so I have an excuse to post an entry.

So I’ve been learning some good stuff here. Given the ecclectic nature of the conference, I’ve been able to go to sessions on a wide range of topics and not get bored by a single topic. For example, this morning I was in a session about use cases, then followed it up with a different session on the internals of the Java Virtual Machine. It all definitely makes me miss my days doing real development; even the use case session was more development than I do in my daily job if that says anything.

Learned some cool stuff about JVMs. ‘bytes’ and ‘shorts’ get compiled into ‘int’ bytecode when you do arithmatic on them, so you’re not really saving yourself any memory by using them. Garbage collectors have gotten a whole lot smarter than they used to be, to the point where it’s perfectly fine to have lots of small, short-lived objects (if you’ve got a Generational GC).

I was in a session yesterday with Joshua Kerievsky about Code Smells, which was great. One smell I completely disagree with is the “Comments” smell (actually from Fowler): if there are comments in your code, then you need to refactor it so it’s so understandable you don’t need comments. I find this attitude as frustrating as it is (currently) fashionable. Take this example:

Country countryOfIssue = null;
if (asset.getTradingCountry()==null){
countryOfIssue = asset.getTradingCountry();
} else {
countryOfIssue = asset.getExchange().getCountry();
}

I understand this code fine. If the asset doesn’t have a trading country, then assume the country of issue is the country of the exchange it trades on. But what I need to know, 5 years later after the original coder has left, *why* would the trading country ever be null? Who said this was an ok situation? Is it safe to take this out and just assume every asset has a trading country? We have a situation just like this in my system and I don’t know the answer and it’s causing me pain.

Last observation: the lunch they’re serving here has been surprisingly good. Just sandwiches and some fruit and a side, but they’re tasty.

March 17th, 2005

President’s press conference

by Tim Cull

So I’m no fan of President Bush, let me get that out of the way. I voted against him in both elections, marched in an anti-war protest (before the war started, an important distinction I think, and a subject for a different post).

But yesterday when I was driving home I heard him in a press conference give an uncharacteristically thoughtful and articulate response to a reporter’s question.

The reported asked him if he felt a sense of “vindication” because the election in Iraq went well, and Syria is pulling out of Lebanon, and things in the Middle East are going (relatively) well. His answer was basically “I don’t have time to think about that, I’ll let history decide”. He described how he doesn’t spend his time walking around the oval office “asking different portraits, what do you think?” I’m not going to be able to do it justice, but he managed to be folksy and articulate and thoughtful, without sounding like a sneering ass like he usually does. He almost sounded like Bill Clinton.