Archive for March, 2008

A small step

Wednesday, March 19th, 2008

Whew, I made it.  I had a little time this afternoon so I have written out a little documentation and published some new code on the svn repositories.  I’m afraid that’s all that I am going to be doing for several weeks because I am going to China tommorow on vacation and not touching a computer.

Work in Progress

Tuesday, March 18th, 2008

I have been very surprised that some people have already been finding my site.  I’m sorry that I don’t have a more finished project to show you, but there are only so many hours in the day.  NHibernate.Remote is a project that I have been working on for the company MemoryExpress .  I am a programmer that is working on a new set of internal applications and they have been generous enough to agree to allow me to open source this project in the hopes that it will benefit the community and perhaps other more talented people will join in the effort.

Several days ago I promised a quick how-to and I am still going to do that.  However at the moment I am doing some finishing work on making the WCF channel a bit more robust and creating a custom web/app.config section.  Also I am working on unit tests.  I will post the quick how-to as soon as the custom config section is finished as that would affect the documentation in a large way.

Oh, and I am going to China for two weeks on March 20 so I’m hoping to have something before then.  Fingers crossed.

NHibernate.Remote code preview

Wednesday, March 12th, 2008

It gives me great pleasure to announce that NHibernate.Remote is at the stage where a community preview is possible.  It is still very raw software and not intended for any production environments, however it may give you a few ideas.

NHibernate.Remote is a WCF client for the popular ORM mapper NHibernate . For a long time when a user of NHibernate wanted to cross domain boundaries there was a lot of work involved in getting the NHibernate data over whatever means of communication was chosen.  A specific set of CRUD methods had to be set up for each persistent type, data types had to be serialized and don’t even think about using the awesome lazy loaders remotely.  Well with the advent of WCF I started thinking that there had to be a better way to exchange NHibernate data in an all .net world.  I realize what I am doing breaks all the rules of SOA but I’m only working with .net clients so I can justify it, right?  The major hurdle involved getting open generics to pass over WCF.  Anyone that has tried this out-of-the-box knows that the serializer throws a nasty error, but there is another way.  I created a generic messaging system library that would allow me to pass generic messages back and forth over WCF.  To that I added a method router that handled generic types to allow generic methods to reach their counterparts on the server.  Thus armed with a communications method that supported generics, I was able to get a lot of the ISession functionality to transmit over the wire to a remote client including LazyLoaded entities.  Not only are the lazy loaded entities transmitted, but they are also reattatched to the remote session so that their functionality is preserved.  Now then,  I have to say right here, don’t get your hopes too high because this technology is still in its infancy.  Right now saving only supports objects that have Guid’s as their primary keys, criteria queries are not working, and the testing has been very minimal.  However generic HQL queries are definitely work as well as a “Linq esq” DynamicQuery language I have been working on.

So how do you get ahold of this technology?  At this point you will have to use Subversion, as I have no intention of releasing a binary until the technology becomes more mature.  However if you are versed in subversion you can grab the source here.

I welcome any and all comments about my code and if you happen to want to help out with the project then by all means contact me.

If you want to take a look a the GenericMessaging system then you can grab the source for that here.

Keep in mind that this is preview code only and is still under heavy development. I hope to have more documentation available as the project matures in the coming months.

 Comming Soon:  A brief how-to get started