1. Codebase HQ →

    These guys are brilliant!

    I was looking to move my “for fun” code repositories to Git and found them. Not only do they do git but Subversion, Mercurial, ticket tracking, wiki and some project management. For ~$9 dollars a month it’s great deal and a great tool.

    The support is awesome. I requested a feature, they implemented it and sent me a follow up email to let me know it was done. I was still just a trial user at the time. I am so impressed.

  2. Writing a new MVC application: What to use for persistence?

    So I’m writing a new personal “for fun” application and I really can’t decide on what to use for the persistence layer. I on the one hand I love NHibernate (I can’t get enough of Oren Eini’s blog on the matter http://ayende.com/Blog/), personally I don’t mind the Entity Framework from MS, you have to give a little love but it does work. I’ve also been reading with much interest about CouchDB which I really want to take for a spin and would really fit with the nature of the application I’m writing.

    There are a couple of libraries that might help grease the wheels between CouchDB and .net, Företagsplatsen has a nice library called Divan which offers a pretty good .net wrapper around the CouchDB API. SineSignal has created a library called Ottoman which is in the way early stages (pre-alpha) but looks really promising.

    As a side note Ayende has created his own document database called DivanDB (not to be confused with the Divan CouchDB wrapper mentioned above) which would be a .net / LINQ-ified database comparable to CouchDB. I’m not sure where he’s going with it so I don’t think I would use it for this project

    As a result I am going to hold off on this decision until much later. For now I will write persistence using the Repository model and implement a HashTable to store my development data, I see it as a great opportunity to really separate the model / persistence concerns.

    I can see one impact that this indecision will have and that is the developing the Model. Should I choose to go with NHibernate then I need to make all properties virtual. The Entity Framework required specific classes for related entities. CouchDB seems like it would work best with a superclass that implements a guid ID (Primary Key equivalent) and string Revision number. To handle this I will create a common superclass that may have nothing declared for right now and make my properties virtual anyway. Should I choose to implement Entity Framework I will have to go back and redefine the related entities.

    Which persistence layer do you prefer?

  3. C# 3.0 inline class instantiation and MS Enterprise Library Validation issue

    This throws an error:

    var entity = new Entity() { Name = name, TokenValue = tokenValue };
    ValidationResults r = Validation.Validate(entity);

    This works:

    var entity = new Entity();
    entity.Name = name;
    entity.TokenValue = tokenValue;
    ValidationResults r = Validation.Validate(entity);

    My understanding of C# 3.0 is that the two above statements are doing the exact same thing, but I guess they are not. I wonder where the issues lies. Any ideas?

  4. Bucketwise: a Rails example from a 37 Signals developer

    Jamis Buck just released v1.0 of his Bucketwise personal finance application. I have been getting into the Rails framework for the past 6 months or so (I just finished my first rails app last week - more on than later). I was excited that he opened it up and released it on Github, mostly because I wanted to see how a 37 Signals guy would put a fairly straightforward app together using their Ruby on Rails framework. I have only had chance to skim the the source code but so far it looks very tidy.