Archives

Archives / 2007 / April
  • Great News: Only One O/RM Shipping in Orcas

    I almost can't believe the great news that came from MS today.  That's right, the ADO.NET Entity Framework has been delayed !  I bet most of you think I'm being sarcastic, but I am serious.  I've got at least three reasons why this is good news to me.

    First, this gives Linq to Sql a better opportunity to thrive.  Linq to Sql is the "simpler" OR/M that's looking good enough for the vast majority of cases, while ADO.NET EF is far more complex -- and yet most gurus only wanted to talk about the EF.
     
    Next, since ADO.NET EF is so complicated, it absolutely must have a great designer ship concurrently, which was not the plan.  MS has apparently accepted this feedback since this is at least the publicly given rationale for the delay in shipping the EF.

    Finally, and this one may not pan out, but it is my own hope that ADO.NET EF is being re-aligned somewhat with Linq to Sql.  These two O/RMs are similar enough to share at least some code, and I believe that some of the MS guys have hinted at this too.

    So I'm happy that at first there will be one O/RM -- Linq to Sql.  The gurus may be disappointed, but the vast majority of MS devs will be new to O/RMs anyhow, and Linq to Sql will be good enough.  Very much like my simple WilsonORMapper has been so widely used.

  • Even Small Configuration Changes can cause Bigger Problems

    I've got a small app in production that's been running without a glitch until the other day.  It turned out to be a case where the server didn't have enough disk space and nothing more.  That should have been the end of it, but I also decided to add myself to the error emails.  The next day someone reported not getting their regular email, and I couldn't figure it out.

    Why would something that had been working perfectly and not been changed just fail randomly?  I looked everywhere in the code and could find no reason, and nothing was logged about this.  That said, there was an exception that was logged, but it was about my email, not the other.  My email address was on another domain, and that wasn't allowed, but I just shrugged it off.  Then it happened again today and all the sudden I realized what should have been very obvious.

    That small configuration change I had made to send myself error emails was the actual problem!  My code first sent error emails before sending routine emails, all of which was one try/catch  So when I added myself to the error emails, I introduced an exception that skipped the others.  This was now easy to fix -- just make each email send be in its own try/catch, instead of one.

    And the lesson learned:  any change, even a tiny configuration change, can introduce problems.  Even bigger lesson:  when problem occurs after small change, then your change is likely cause.  Those should really have been obvious in retrospect, but I managed to convince myself otherwise.