Friday, April 27, 2007

Deterministic non-determinism

A colleague pointed me to a blog entry on a blog by the VP of VMWare. It talks about a new "replay" feature in the next version of VMWare — you can record the execution of your VM to a file, and then replay that file later. This will reproduce the VM's execution exactly as it happened the first time. This is an unbelievably cool feature for debugging things like memory stomps and race conditions.

When trying to find a bug, the easiest way is to run it in the debugger, put breakpoints near where you think the problem is happening, and then run it, hoping that it fails the same way that it did before. If it doesn't, well, try again, or tweak some part of the test case to try to cause it to be more reproducible. If it's a race condition, it's highly possible that attaching the debugger or tweaking the test changes the timing enough that the problem never shows up. With this thing, once you've reproduced a problem, you could then replay it (in the debugger!) and step through the code, knowing that the problem will reproduce. You can step "back in time" to just before the problem occurred, and then step through the problem as it happens. According to the web site, the recording process has no effect on the speed of the VM. This is not possible according to the Heisenburg Uncertainty Principle, which, strangely, is specifically referenced in the article. Ah, what did he know, anyway?

Apparently it doesn't have SMP support, so if your problem is SMP-related, this won't help you. But it looks like a very nice piece of software engineering, so kudos to the VMWare people!

Thursday, April 26, 2007

Thunderbird

I made the big email switch this week, going from Outlook to the brand-spankin' new Thunderbird 2.0. My company actually uses Lotus Notes as the "standard" email client, but after a few years of using that, I found that it sucked rocks, so I took a week and switched to Outlook. First I politely asked IT to set me up with an IMAP account, which let me access my network-stored email folders from Outlook. They did that, and I used that to suck down all my archived mail. Then I abandonded IMAP and went to straight POP, and life was good... for a while.

I think it was when I upgraded to Office 2003 that things started to go bad again. Every now and again, I'd go for several hours without receiving any email, and discover that Outlook simply stopped checking, or something. I would shut down Outlook and start it up again, and then it would download all kinds of stuff from the previous few hours. It also took forever to start up Outlook (as much as several minutes sometimes), and the search capabilities were terrible, although I found a tool called LookOut that solved that problem. However, Microsoft bought the company that made Lookout, and changed the product into something called "Windows Desktop Search". Apparently Lookout itself is no longer available. I still have an install though - email me if you want it.

I started using Firefox as my default browser several years ago, and I love it, so when I found out that the same team made an email client called Thunderbird, I immediately downloaded it. I tried using it for a couple of days, but I could never get the LDAP stuff working, so searching the company address book for a name would not work. This was a big pain, so I decided to wait until that bug was fixed, and I went back to Outlook. A year or two later, I tried it again, and ran into the same problem. I asked another guy in my department how he got his to work, and he had no idea, it just did. Then we looked at mine, and it just didn't. We even went so far as to use a packet sniffer and point Thunderbird at a perl script that my boss wrote that acted as a proxy to the real LDAP server, and got nowhere with that either. After more searching, I found that this was a known bug in Thunderbird — the LDAP stuff did not work if IPv6 was installed on the machine. Since I was working on IPv6 for SQL Anywhere, I had it installed, which explained why it didn't work for me. I followed the progress of the bug for a while, and found that it was not going to be fixed until Thunderbird 2.0, so I had to shelve my plans to switch to Thunderbird yet again, though I did switch to using it as my newsreader at that time, and have been pretty happy with it in that capacity.

When I heard last week that Thunderbird 2.0 was being released, I got all excited, and downloaded it immediately. I tested the LDAP support and it worked, and it (relatively) seamlessly imported all my Outlook contacts and mail, and I've been using it for a week now. Honestly though, other than being faster than Outlook, I can't say I'm noticing much of a difference. It's better at dealing with junk mail, but I prefer Outlook's addressing — the To and CC lists consist of a single (expanding) text box where you can enter names separated by semicolons. The names are then expanded, and if more than one match is found, Outlook underlines it and you can right-click to choose the correct one. With Thunderbird, each address is listed on a separate line (so if you're sending an email to 20 people, you have this huge list of names, rather than one text box). When you enter a short form, it searches your address books until it finds one that matches, and then replaces the name with that address and stops searching. If I type "Kurt" to send an email to the guy in my department named Kurt (who wasn't in my personal address book), it searched the company directory, found someone named Kurt (probably the first one alphabetically), and used that address. There is no indication that the name wasn't unique. However, you can click "Contacts", which opens up a little sidebar that gives you similar functionality. I'm sure I'll get used to it and it'll be good enough — I'm just used to the way Outlook did it, not requiring the extra sidebar.

I should probably have waited until 2.0.1, or at least until a patch or two was released, since it crashes now and again, and I've even seen the same behaviour that I saw with Outlook — no email downloaded for a long time, but no error messages to say why, or even to indicate that there was a problem. But updates to Outlook were few and far between, while I'm sure there will be fairly regular updates to Thunderbird, so I'm going to continue with Thunderbird on the assumption that these irritations are a bit of short term pain that will eventually result in long-term gain. At least I'm supporting the open source community! That's good, right?

Wednesday, April 25, 2007

Open Source

Maybe I'm naïve, but I just don't get the big deal with open source software. I think it's great that people are willing to put their time and effort into writing it, documenting it, and supporting it, but there are people out there that believe that all software should be open source, and that commercial closed source software is generally a Bad Thing. While I can certainly see the advantages of open source software, I make my living writing closed source software. It's fairly simple: if Sybase didn't make revenue selling SQL Anywhere, I'd be out of a job.

Thinking about it a little more, I'm quite sure that I am naïve when it comes to open source, because I don't think I understand how it works. The extent of my knowledge about the process is this: there is a code repository somewhere on the web, and anyone can sync up to it and make changes to the code. But are there regular code reviews? Are there people checking every code submission to see if someone is adding bad code or trojans or anything like that? Who checks all the different platforms? Who runs regression tests to make sure that new features aren't breaking old features, or that performance isn't being affected? Who decides which new features go in and which ones don't? Surely there must be a full-time team of developers and managers that oversee all of these things, but how do they get paid? Who can afford to take on a full-time job that pays nothing? Is the open source world entirely populated by rich developers who don't need an income? I doubt it. Is it enough to have advertising on the web site and a "Please donate" button with a link to PayPal?

I just checked the OpenSSL web site, and it says specifically that the project is volunteer-driven. The Apache Software Foundation is a non-profit charitable organization, and their annual reports (complete with financial information) are listed on their website. However, according to the 2006 report, every officer of the company received $0 compensation, and the total revenue of the entire organization was under $150,000. Total compensation, wages, and benefits were $0. Again, are they all rich and don't need incomes? How do you squeeze in being a director or VP of such an organization if you already have a full-time job elsewhere?

I've been a professional software developer for over 15 years, so I probably should know the answers to these questions, and I'm feeling rather stupid that I don't. If you do, please leave a comment and let me know how this works. Maybe I should stick to blogging about my kids or sports.

Tuesday, April 24, 2007

Second round picks

Well, I was 7 for 8 with my first round picks in the NHL playoffs. Let's see how well I do in the second round:

  • Buffalo over the Rangers
  • Ottawa over New Jersey -- have to say I'm not sure about this one. Ottawa won their first round series in 4, so they've been sitting and waiting for a week, while New Jersey had a hard-fought series against Tampa Bay, and might be riding some momentum. Maybe I should just predict that this series will go 6 or 7 and not actually pick a winner.
  • Detroit over San Jose
  • Anaheim over Vancouver

Monday, April 23, 2007

Nicky's job

Part of a conversation Gail and I had with Ryan and Nicholas the other day:

Gail: We're the parents. It's our job to keep you guys safe, to protect you. It's also our job to teach you to be nice, polite, helpful, to help you learn, give you food and clothes, a place to sleep....
Ryan: Drive us to school?
Gail: Yes, that's another one. All of those things are part of our job as parents. Nicholas, what do you think your job is?

(Nicholas then rolled his eyes and gave a big sigh, as though he's given this same answer a hundred times before)

Nicholas: Remember my shoes.

Thursday, April 19, 2007

No spare tire, thanks very much

One year ago today, I started my weight loss program (blogged about it last year). I'm basically following the Weight Watchers program, without actually joining Weight Watchers. So far, it's been a big success. When I started (April 19, 2006), I weighed 175.5 pounds, and by August 9, I was down to 160 even. Since then, I've hovered between 160 and 165 (maxing out at 165.5 twice) &mdash this morning I weighed in (for the third consecutive week) at 163.5.

I'm still following the program, but I've upped my points to 28 per day, and I don't count points on weekends, though I try not to go too crazy. I've been doing that for about six months, and I've been maintaining pretty well.

I was never concerned about my weight until about 10 years ago. We were looking at some pictures of a recent trip to Collingwood with some friends. One of the friends was quite pregnant with her second child, and she joked about how her first child kept running up to her, pointing to her expanding tummy, and saying "baby". While looking at the pictures, we came across one of me in a particularly unflattering pose. Gail jokingly pointed at my tummy and said "baby". Now that I think about it, it would be really unlike Gail to say something like that, so perhaps it was someone else. Might even have been me. In any case, that's when I resolved (it was December at the time) to get into better shape. Shortly after Christmas that year, we bought a treadmill, and I started cutting out snacks and stuff. I went from my high of 188 pounds down to 163 in four months. In the next few months I went up to around 170, and then stayed around there for a few years, though it kept slowly creeping up until I hit 175 again, and then Easter happened last year.

My ultimate goal is to never hit 180 pounds again. Right now, I would consider even getting to 170 as failure. I realize that I am almost for... for... f... well, I'm in my late thirties, and things will likely change, but for now I'm still eating pretty well most of the time, working out two or three times a week, and playing baseball again this summer. I think I look OK, and I feel great, so my short-term goal is not to hit 170 pounds before I turn for... for... f... oh, you know.

Wednesday, April 18, 2007

Doyle vs. Benesch

The Rock have now gone a full season without Colin Doyle. Are they a better team without him? Well, no, but that may not be all his doing; they also lost Brad MacDonald and Brian Biesel, and then traded away Rusty Kruger and Phil Sanderson halfway through the season, and they also had a rookie coach. Benesch, Fines, and Thompson tallied more points in total than Doyle did, but does that mean the Rock really won the trade? Hard to say. Doyle played very well with San Jose, who kind of pulled a Raptors — they were really bad last year (5-11 and a distant 5th in the west), and worse the year before, but this year they're 9-7 and they made the playoffs for the first time in 3 years — and they didn't just squeak into the playoffs like the Rock did.

Ryan Benesch looks like the "real deal", winning Rookie of the Month for February, Rookie of the Week a couple of times, and is a serious contender for Rookie of the Year. He will be a great player in the NLL for years to come. But then again so will Doyle, who already is a great player in the NLL, and has been for years. Josh Sanderson's point total dropped by about 15 this year — he seemed to enjoy passing to Doyle who would just power through the middle of the defense. Blaine Manning doesn't do that as much (Manning is still a very good player, but he's just not the player he was a couple of years ago), and Benesch doesn't either, but man, does that kid have some moves. Aaron Wilson also continues to improve, and no longer just waits around the left side of the net for someone to pass it to him; he can score from anywhere.

So with all of these kids doing well, plus veterans like Veltman and Driscoll (one of the best all-round players on the team, IMHO) around, and the ultimate clutch goalie Bob Watson in net, do the Rock stand a chance against the 14-2 Rochester Knighthawks this weekend? Nope. I really hope I'm wrong, but I think they're gonna get smoked.

Philadelphia is in a rebuilding phase right now — just look at the kids they have on their roster: Athan Ianucci, Geoff Snider (holy crap, is he ever good at faceoffs), Kyle Wailes, Ian Llord, Sean Greenhalgh, and Rob Van Beek — and their goalie Matt Roik is almost 10 years younger than Watson. They might have sucked just as much as Toronto this year (they ended up with the same record of 6-10), but let's see how the Wings are doing, say, two or three years from now, once all those kids have a few years under their belt. Compare that to the aging Rock, who will have to deal with the inevitable retirement (or at least decline) of Veltman, Watson, Ladouceur, and Driscoll. Wilson and Benesch have many great years ahead of them, and I believe the Rock got a first rounder for Phil Sanderson, but that's a lot of people (and talent) to replace.

Friday, April 13, 2007

First Round Picks

I looked at the hockey scores this morning and found that the winners of all four games last night were who I picked to win their respective series. Then I realized that nobody knew this because I hadn't posted my picks! So here I go:

  • Buffalo over the Islanders
  • New Jersey over Tampa Bay
  • The Rangers over Atlanta
  • Ottawa over Pittsburgh -- though I don't think I'd want to play Pittsburgh in next year's playoffs.
  • Dallas Detroit over Calgary
  • Anaheim over Minnesota
  • Vancouver over Dallas
  • Nashville over San Jose

I'll make my second round picks once the first round is done, but right now, I'm picking Buffalo over Detroit in the Cup final.

Thursday, April 12, 2007

Wii!

I have been looking for a Wii for several Wiiks (everyone reading this is thinking "Oh, please don't start with the Wii jokes, they are Wii-lly annoying") months now, and have had no luck. I've called numerous stores numerous times, and they're always sold out, and nobody knows when they're getting any more. The other day, a guy at work, aListair (he always capitalizes the L) emailed me that the EB Games near him had a couple of consoles, and would I like for him to grab me one. Rather than asking where it was and getting off my lazy ass and going there myself, I just said sure and let him do my legwork for me. He went on his way to work, and came by my office yesterday morning with a Wii console. You da man aListair!

I set it up last night (no internet yet, maybe this weekend), and played a few games after the kids went to bed (by the time I got it set up, it was bedtime; it's not like I waited until they were in bed). I bought Wii Play on the way home, which is $59, but comes with a free controller! Well, it turns out that a more accurate description would be that it's a $49 controller that comes with a $10 game. The game itself is pretty good for practicing using the remote, but not much else. Wii Sports is much better — it turns out that I'm a bowling expert. Who knew? I figured out quickly that because of the way I throw it, the ball always spins to the left, so I managed to compensate for that, and did pretty well. I didn't manage to figure out why it goes to the left in the first place, but as long as you can compensate for it, it doesn't much matter. Hey, that's the same as my golf game!

We also rented some games from Blockbuster — Cars and Super Paper Mario. I never managed to figure Cars out, but I thought about it later, and I think you have to turn the remote sideways. I looked at Super Paper Mario as well, but the opening sequence (telling you the story) is, as aListair put it "very very very very very very verbose", so after a while I just went back to Wii Sports.

This morning, I read an article on how the Wii shortage "could last months". Thanks again aListair!

Monday, April 09, 2007

Speling - its important

I'm an English pedant. It annoys me when I read stuff that contains spelling, grammatical, or even punctuation mistakes. Here is an article about proper punctuation, and here is one about grammatical mistakes. The second one contains all kinds of things that annoy me: "would of" instead of "would have", "your" instead of "you're", and "it's instead of its" ("it's" is short for "it is" &mdash it's as simple as that).

A former boss of mine, Ed, used to say "irre-dis-regardless" instead of "regardless". He was a very clever and funny guy, so I am quite sure he was kidding around, and didn't actually believe that was a real word. We had a tool called "FIST", which was short for "FIle STorage", and one of my co-workers joked about the fact that "fist" sounded similar to the Polish word for (I think) potato. Ed, who was of Spanish descent, thought for a second and then told us that the closest you'd get in Spanish is "There was a bug but I fist it". (Say that quote with a strong Speedy Gonzalez accent to get the full effect.)

Now that I think about it, the FIST tool was the source of another joke. FIST had both a client component ("front-end") and a server component ("back-end"). One of our co-workers was in charge of the server component, and one day when he was working from home, someone asked where he was; the answer was that he was at home, doing the back-end FIST thing. Purely unintentional, but we all laughed for hours.

Thursday, April 05, 2007

Mean people suck

Every now and again, you hear stories about people that give you a good feeling about people in general. You can call it faith in the goodness of mankind. My wife calls it a "warm fuzzy". You know, the people who find a bag full of money and find out where it came from and return it untouched, or donate a kidney to someone they barely know. Last Christmas, my wife went through the Tim Horton's drive-thru one morning and when she got to the window, she told the cashier that she wanted to pay for the person behind her (who she didn't know). It only cost her a couple of bucks, but she felt great for days.

And then there are these losers.

There's a guy in the office whose teenage son has cerebal palsy, and is confined to a wheelchair. As a way for his son, who cannot hold a regular job, to make a little bit of money, his father has a snack tray in the kitchen, with chocolate bars and chips and such for a buck each, and a little tin to collect the money. The snack tray has been there for a number of years. In the last week or so, he's had to move the tray to a table outside his office, because things are being stolen from the tray. He's now got a sign in the kitchen where the tray used to be saying "If you want to steal from me, come to my office and pick my pocket, and leave my son alone." I was hoping that it was someone who wanted a snack but didn't have the money at the time, and they figured they'd pay for it the next day — I have done this in the past (though I always leave a little signed IOU note), but apparently this was not an isolated incident, it's happened a number of times.

I put a case of chocolate bars and boxes of chocolate pieces in the kitchen the other day as part of a fundraiser for my kids' school, along with an envelope for the money. I dropped by the kitchen just a couple of hours later, and found that a box has been opened. What kind of person would just help themself? (Note: I also found at the end of the day that there was one dollar more in the envelope than I was expecting based on what was sold. Could be that the guilty party figured that they ate 1/3 of the box, so they left 1/3 of the cost. However, I did not list that as an option on the envelope — a box is $3, either you buy it or you don't.)

My kids' school held a silent auction in February to raise money for the science programs in the school. Local businesses donated items, gift certificates, etc. that were then auctioned off, and all the money raised went to the school. The minimum bid for each item was 1/3 of the item's value, and obviously the highest bid at the end of the night won the item. My wife is the chair of the school council, which ran the event, and she told me about some of the goings-on:

  • Several people scratched out the minimum bid and bid something less. In at least one case, nobody else bid on the item, and the bidder expected to get the item for less than the minimum. When told she'd have to pay the minimum, she refused (though her father was standing right there and he offered to pay the minimum).
  • One person (might have been the same person as in the first point) bid on a bunch of things and won several of them. When told what items she had won, she said that she didn't expect to win that many, and that she didn't want them all.
  • One item wasn't being bid on, so the principal of the school announced over the PA that she was lowering the minimum bid. I might add here that the school is benefitting from the event, but it was being run by the school council, and so the principal had no authority to do this.
  • There were two people (I'll call them A and B) bidding for one item, and they almost came to blows. Each accused the other of "cheating" - A said that B essentially hip-checked her out of the way to get to the bid sheet, and B said that she couldn't get to the bid sheet because A's husband physically blocked her. This did not get solved until several days after the event. Person B left us a very long voicemail message describing her view, and threatened to not attend anymore school fundraisers (effectively punishing the school) unless she got the item. Person A, who had ended up with the item after the auction, decided that it wasn't worth the fight and gave it to B. Strangely, the item was a gift certificate for the place where person A worked.

Mean people suck.

Wednesday, April 04, 2007

Monday, April 02, 2007

Baseball season and the Rock thump the Wings

Baseball season began yesterday! The Jays start their season today against the Tigers, and I'm pretty excited. The Jays had a pretty good season last year, finishing second in the AL East, and big things are expected this year as well. Well, hopefully, anyway. They added Frank Thomas and Matt Stairs to the lineup, increasing the offensive potency of an already-potent lineup. I think that having Vernon Wells sign a multi-year million billion gazillion dollar contract helped to convince them that the Jays were serious. Adding Royce Clayton at short won't make a huge difference, but it certainly won't hurt. I was kind of hoping that J.P. Ricciardi would add a stud arm to the pitching rotation during the off-season, or at least someone to replace Ted Lilly. He didn't, but Josh Towers looked more in spring training like the pretty good Josh Towers from two years ago than the woefully sucky Josh Towers who went something like 2-10 last year, and free agents Victor Zambrano and Tomo Okha look like pretty good signings. Last year, A.J. Burnett occasionally looked unhittable, but sometimes was quite hittable, so if he has more outings in the former category and less in the latter, he'll be fine, and if Gustavo Chacin can get over last year's injuries (though he had a lousy spring), the pitching staff should be no worse than last year, and possibly better.

In lacrosse news, the Rock have been playing downright lousy for most of this year, losing games to both New York and Edmonton, who are a combined 8-18. They are not only in danger of missing the playoffs for the first time in history (they missed the playoffs in their first season as the Ontario Raiders, but haven't since they moved to Toronto in 1999), but are also in danger, at 6-7, of finishing below .500 for the first time in history (they were 8-8 last year). However, when they played Philadelphia last Friday night, you'd never have known any of that. They kept the Wings scoreless in the entire first half (unheard of in lacrosse), and went on to win 15-6. Watson was very good in the first half, and amazing in the second, the defense was solid, and the offense was clicking. Ryan Benesch scored four goals for the third straight game, and is starting to make people forget Colin Doyle, though it's probably too early to say that. Doyle was not only a scoring machine, but he made the players he played with better as well -- look at Josh Sanderson and Blaine Manning. Sanderson has been fine this year, but Manning has been remarkably average, and is on pace to end up with less points than last year, which was down from the previous year. I can't imagine a player as good as he is (was?) has peaked at the age of 26, but he hasn't been injured or anything, so I can't explain it.

The Leafs are close to backing their way into the playoffs and I'm not sure how I feel about this. On one hand, once they're in the playoffs, who knows what could happen (see Edmonton last year), but on the other hand, reality hits — the Leafs are simply not going to win the Cup this year (not that I didn't know that months ago). I remember thinking last year that if the Leafs don't make the playoffs, that'll send a message to management, who might make some serious changes to the team, rebuilding for the future. In that sense, not making the playoffs would be the best thing that could happen. They didn't make the playoffs last year, but management didn't do the necessary dump-and-rebuild, so we're in the same boat this year. If they don't make the playoffs this year, I have no confidence that the necessary changes will be made (i.e. trade all the big names, load up on draft picks and young kids, etc.), so we'll be in the same boat again next year, and the year after that, and the year after that... Given that, may as well squeak into the playoffs this year and hope for the best.