Tuesday, July 21, 2009

Perspective

I just came home from my Tuesday night men's group. It's two hours every week from 8-10PM where we study the Bible, pray for each other, and hold one another accountable. We usually talk a lot about how we can be better husbands and fathers. And tonight was no different. I found myself asking God during our closing prayer to show us new ways to show love to our wives.

Then I biked home, and found that we have zillions of toys in the yard (including a snow sled) and the garage door is still up. I walked in the house and it's nearly 80 degrees. The kitchen was in bad shape from dinner. There were plates on the table, groceries still out, a pile of clean dishes drying in the sink with a stack of dirty ones waiting their turn. There's items scattered about from a trip to the pool, and the trash is full. The TV is on downstairs.

I'm exhausted and I really don't want to lift a finger at this point and I think that this should wait until tomorrow, which would mean that it's Beth's to fix. But then I look back at my day...
  • I rolled out of bed at 7:30
  • I worked from 8:30 until 6:00 doing something I love and am passionate about
  • I arrived home to two worn out, but happy boys
  • I constructed a (purposely) non-functioning slingshot out of a stick and rope at Ian's persistent request
  • I danced with my boys to some new MP3s I bought with an Amazon.com gift certificate from my birthday
  • I ate a nice, simple meal that Beth prepared
  • I started the bath-time/bed-time process with the boys
  • I went to my weekly men's group
Then, I try to imagine Beth's day.
  • Caleb crawled into our bed unbeknownst to me at 5 AM. She woke up and carried him to the potty to avert disaster.
  • She had to get herself showered and ready for the day with no help keeping the boys in line while she did it
  • She and the boys cleaned and picked up most of the house
  • She and the boys went to the grocery store
  • She took the boys to the pool and wore them out so that we could have an easy bed time this evening
  • She fixed dinner
  • She dealt with all discipline issues
  • She finished up the bedtime routine after I left
  • She did not complain once, nor does she ever really, about me leaving in the evening after having been away all day at work
  • And now, when I come home, I find that she's in the basement (with the TV on), finally able to do something for herself.
My day seems nothing like her day, and in fact seems ridiculously simple and pleasant. And so I wordlessly clean the kitchen, ashamed that I even considered abandoning her to it. And when I get it looking reasonable, I tell myself that "reasonable" isn't good enough if there's still work for her to do in the morning so I keep on keepin' on. And by no later than 10:45, it's pretty clean. It really was more effort to screw up my resolve than it was to do the actual work.

I head downstairs to see Beth and say hello for the first time after having gotten home, and discover that she's been folding laundry all this time. And, of course, if you're in our basement for more than 2 seconds, you turn the TV on because folding laundry is a pretty wretched activity otherwise.

So, instead of sitting down, I pick up a laundry basket and head up the stairs with it. On my way up, Beth tries to tell me what an awesome husband she thinks I am. She says - get this - "Why is it that when I come home to a mess I just get really mad, but you don't treat me that way", and then she tries to tell me how I'm a much nicer spouse than she is. Definitely not true. It's really all a matter of perspective.


Ephesians 5:25 - Husbands, love your wives, just as Christ also loved the church and gave Himself up for her

Philippians 2:3 - Do nothing out of selfish ambition or vain conceit, but in humility consider others better than yourselves.

Sunday, July 19, 2009

Groceries

Believe it or not, we shop at ALDI. If you've never been to ALDI, it's quite an experience. The stores are never out front on a busy street. You usually find them tucked off behind some of the more prime real estate. They don't accept credit cards to cut costs; it's cash only, though they do let you make a PIN purchase with your ATM/Debit card. In order to take a cart, you have to put a quarter into a release mechanism. If you return your cart instead of leaving it in the parking lot, you get a quarter back. There are four or five total aisles in the store, but you can walk out with almost all the essentials. You bag your own groceries. And, if you fill your cart as high as you can get it without stuff falling out, you might possibly just barely break the $100 barrier.

You can't get everything there. In fact, if you shop for groceries there you typically have to make another trip to a different store to get some of life's little extras, or things you're unwilling to settle for off brands of like pop or t.p. of reasonable quality. But usually you'll find some name brand stuff. It depends on what they can get deals on, but you can typically get fresh produce and pringles and baking mixes and that sort of thing. And all of it is less than the jacked up prices you pay at Kroger and Giant Eagle, even with their slightly-reduced-gouging-at-the-expense-of-tracking-your-every-purchase loyalty cards. The extra trip you have to make to those stores to fill the rest of your grocery list will fill only 1/2 our cart, but cost much more than the ALDI trip.

They don't advertise so that they can save money, but Unwrapped on the Food Network did a little blurb on them in one of their shows. You really can't go into ALDI with a list and expect to get everything you need, but if you're willing to forfeit a bit of pride and convenience, you save a ton! Your mileage may vary, but I track our family finances very closely and we spend 1/3 less a month on groceries for our family of 4 during months where we make it to ALDI. We save about $2000 a year by shopping here.

In addition to cutting me and the boys hair, being willing to drive older and used cars to bypass having car payments, working at our church's preschool so that the kids get free tuition, and finding us the greatest deal on a cell phone plan of anyone I know - my lovely wife sacrifices to make an extra grocery trip so that we can save. It's stuff we probably wouldn't do if we both worked full time, but it has a visible and significant impact on the way our house runs. I think that a lot of people forget that there are two sides to the family finance equation - income and expense. Income is the harder variable to tweak, but by controlling expenses our income goes much further.

Thursday, July 16, 2009

Vista SP2

Someone known only as Eman posted a link on this site that made my day. I've followed his instructions with a slight tweak to the .cmd file. So, the long and short of it for those who've been following my DVR posts is that I've upgraded my DVR box to Vista x64 SP2 and re-enabled my remote desktop hack. And, for $50*, I've pre-ordered my copy of Windows 7 from Amazon, so when that arrives I'll likely be upgrading my DVR box again.

* Of course, now the early-bird special at Amazon is done and now it's $119.

Wednesday, July 15, 2009

Robocopy

Apparently I've been asleep at the command-line wheel. I was told today about a tool that Vista includes free, and I cannot figure out how I lived without it. Robocopy *. I've been using SyncToy with mixed results. No more.

See this great article for some robust copying goodness.

* yes, I know about Cygwin + Rsync.

Monday, July 13, 2009

Bad cache

We had some code break down today. Here's the story.

One of the great tricks in the object oriented world is late bound variables. When it's expensive to initialize a variable, or you're not sure you're going to always use it, you don't initialize it until first use.

Public Readonly Property Something() As SomeObject
Get
If _someObject Is Nothing Then
_someObject = DoExpensiveInitialization()
End If
Return _someObject
End Get
End Property
Private _someObject As SomeObject

Another great trick is caching data. If you have some data that you're going to use frequently and that data doesn't change, then load it into shared memory and let all instances of your objects use it without being chatty with the database.

Private Shared s_someLookup As Dictionary(Of String, String)
Shared Sub New()
s_someLookup = GetLookup()
End Sub

So today, we had a whole site break down due to a slight oversight and a misapplication of these concepts. Here's a variation of the code:

Public Shared Readonly Property DataLookup() As DataSet
Get
If s_dsLookup Is Nothing Then SetLookup()
Return s_dsLookup
End Get
End Property
Private Shared s_dsLookup As DataSet

Private Shared Sub SetLookup()
Try
s_dsLookup = New DataSet() ' -- OUR LATE BOUND PROPERTY IS NO LONGER NULL!!!
Dim adp As New SqlDataAdapter(CNN_STR, GetConnection()) ' -- EXCEPTION THROWN
adp.Fill(s_dsLookup)

Catch ex As Exception
' s_dsLookup = Nothing ' -- THE SINGLE LINE FIX

' Handle the exception, but we forget that
' we initialized s_dsLookup so now we're dead
' on every call to the DataLookup property
Handle(ex)
End Try
End Sub

So, code that never failed before, failed today. And I had to track it down. And tracking it down was a PAIN because:
  1. The breakage presented itself far away from the actual problem. Rule #1 - fail fast!
  2. The breakage was not reproducible in any other environment, because the failure was a fluke occurrence.
  3. It was a Monday, we were short staffed, overloaded with hot projects that needed to be done yesterday, with a bug that affects the whole company, and I am neither the author of the code nor the primary developer for the broken site. Murphy's law.
  4. The fix involved the inevitable discussion with management about why these sorts of things happen, and why we use these newfangled development techniques.
Doing tricks for performance purposes always has a tradeoff. Usually it's in the area of maintainability. Not that I'm complaining. Finding these sorts of things and fixing them makes me a better developer, and also gives me great fodder for the blog. I just wish that this stuff wouldn't inevitably happen on Mondays. Or late Friday afternoons.

Thursday, July 9, 2009

Corporate Signs

The day after Michael Jackson died, we received a company-wide e-mail informing us that "The King of Pop is dead". I nearly deleted the e-mail right there, but against my better judgment I read on anyway, only to find out that the message was in regards to our company's popcorn machine breaking down.


/* ************************************** */

At my last job, we had large potted trees amidst our cube farm. People were found to have been dumping their 1/2 finished drinks into the pots. A sign was promptly put up speaking for the trees:

I am not a sink!

Upon my next trip to the men's room, I saw that the sinks had gotten in on the action with their own signs:

I am not a plant!

Any funny office signs, memos or office e-mails to share?

Tuesday, July 7, 2009

Trash compactor

Mt. Rumpke, 1075 feet high and growing at 6,200 tons a day.

When I was younger, I remember trash men riding on the back of their trucks and collecting bags from any number of trash cans the neighbors put out. Then, at some point the city mandated these monstrous 90-gallon containers and each household only got one of them. They equipped the trucks with an arm built to lift the containers, and the day after Christmas is the only time you get to throw out more than what fits in one of those.

Growing up in a family of 5, I recall that we nearly always filled that container to the point where the lid wouldn't close and neighbors would kindly take some of the overflow and put them in their own containers. 90 gallons was barely enough for 5 people. I suppose I expected that this was typical, so as an adult with my family of 4 I expected each person to average nearly 20 gallons of trash a week. And certainly when we had diapers that was true. Our warm summer garage was really no place to be. Ew.

But for the past year or two, I've noticed that we don't fill our container even to the half way point each week. Were it not for the smell, it'd take us 3 weeks before we really needed a pickup. We recycle, despite the fact that there's only a single free drop off point close enough to us. That helps quite a bit. But as I drive to work on trash day, I often see many other bins so full the lids won't close. It's pretty sad, I think. It's all designed so well and works like clockwork and we never see the effects. We put our junk out weekly and it just disappears, so we forget about it and do it again next week. No incentives to examine our actions or attitudes. Someone else's problem. Until, at some point, it isn't.

Monday, July 6, 2009

Good friends, good times

We had good friends over yesterday. There's nothing like spending time with people you're comfortable around. People you have a history with. People you can cook with, or play a board game or card game with.

The last get-together we had these friends was with their family, and Ian went on an adventure walking dogs three times his size and wound up only mildly corrupted having stolen a moment on a few big machines he happened upon with his chaperon:


This time, we took a trip to Jeni's, made dinner, and on a whim used Google to find a really tasty and easy onion ring recipe (slightly modified by the addition of some Frank's Red Hot). Even when we don't do much of anything, it's still always a memorable time.

I'm one of those people who finds that social situations are in general more draining and alone time is more replenishing. But, there are those rare relationships where you can just be yourself all the time. Bad days or good, cranky or joyful, tired or wired. An acquaintance of mine from my younger years once wisely told me that good friends are those people who you can be away from for a really long time and when you meet again, it's as if you saw them yesterday and you pick right back up. I see much truth in that.

Wednesday, July 1, 2009

Digg Dugg

That's it. I finally did it. I've deleted Digg from my list of RSS feeds. The 14 year olds can have it. It's been a train wreck since its inception, but with so many posts there was bound to be something interesting for the likes of me. Always some distant hope of finding a gem. But alas, it is not to be. No more digging in cesspool. Digg hath Dugg the hole they must now lie in. Buh-bye.