Friday, May 04, 2007

NHibernate 1.20 is released!

NHibernate was released May 3, 2007 and they have a migration guide for those of you who do not follow changes in the svn. This release supports stored procedures, and as you can see in the screen shot above, I am working on adding SQL stored procedure generation to my ActiveRecord Generator. I have templates for INSERT, UPDATE and DELETE now, and I will write a SELECT by primary key today. It's too bad I can't just write an attribute to append to the NHibernate mapping file that ActiveRecord creates. I don't know if I will have to write my own ActiveRecord attributes, but the Castle Project seems very friendly to patches. This is very important because I would not really want to release a program that requires a patched library.

I have found several bloggers who have created NHibernate + Stored Procedure samples, but none that have ActiveRecord samples (since we do not have the attributes yet). If you have been working on something, now is your chance to share. (grin) Just post a patch on the Active Record JIRA.

Speaking of the generator, I have converted it from a hand-coded series of write statements to a table object and a field list passed in to the NVelocity template library (available from the Castle Project in their subversion repository). I feel like I am re-inventing the wheel here ... how many NHibernate / ActiveRecord code generators are there anyway? I am still re-factoring it and building templates. As soon as I have broken the project into a code generating library, a windows UI and a command line UI, I will probably release the source as LGPL. The code generator was written for .Net 2.0, SQL Server 2000 or SQL Server 2005, with helpers for my own coding conventions. I will have to write some tests before I start accepting too many patches, but we can worry about that as I re-factor for testability.

On a personal note, I went to see "300" on iMax, thanks to Blingo and Fandango for the free tickets!

Labels: ,


Anonymous Anonymous said...

When Activerecord class generator is released ?

I'm very interested to test it.


July 02, 2007 2:11 PM  

Post a Comment

Subscribe to Post Comments [Atom]

<< Home