Tuesday, March 3, 2009

Continuing remote pairing & SQL testing

This week has had a lot of network issues. We've temporarily gone voice-only to reduce our bandwidth. We're screen-sharing and voice chatting and hoping for the best. Yesterday was awful, today not so much.

We also ran out of free trial for TeamView and LogMeIn (both excellent) and are resorting to WebEx for screen sharing. WebEx works pretty darned well, except that the scroll wheel on any mouse I own sends me immediately to the bottom of the file. Yikes. We also continue to have trouble with colors. I see very low-contrast foreground/background combinations (white on light blue, yellow on white, blue on black etc) but the remote partner sees different, more reasonable colors. These two problems together are a constant dripping faucet.

OTOH, the partner is great and we were able to make some progress between stepping on ORM landmines.

We test-drove our changes through the API/Business layer, but needed to get our gateway working. We use the strategy of creating a transaction in setup and rolling back in teardown. We've been moving along pretty well, until we hit a problem with NHibernate many-to-many relationships. Given classes X and Y with a many-to-many relationship, I can add objectX to objectY and then query objectY back from objectX easily enough, but objectY doesn't know that it has an objectX. We ended up taking research breaks. In NHibernate, one of the classes "owns" the relationship, and the other simply does not. This was not fun. In trying to remove all X for a given Y, it is recommended that we query all the Ys that contain an X and delete it from each. That sounds about half-mad when you have an RDBMS. Luckily, it does the right thing in SQL when we do this, but it's a little mad. It's more hoops to jump through.

A take-away lesson is that the ORM is "something that might break" or at least "something that might be broken." If we hadn't gone to the lengths to test the ORM, then we would have been left with non-working SQL under a well-tested layer of business objects.

Second computer is a pairing smell. I struggle against its siren song. It distracts me and I have to catch up. Maybe it's ADD or something, but I can't keep my hands/mind/eyes off of it. This afternoon, no more second computer. I'll take notes on paper.