The latest installment of the Summer of NHibernate screencast series is now available for download.
I will warn potential viewers in advance that this session is heavily focused on techniques and approaches that tend to contradict most Domain-Driven-Design/Development practices so please don’t waste your time telling me this — I know it already . Leveraging NHibernate to better support DDD principles is coming in the next session, I promise.
Instead, this session focuses on techniques, approaches, concerns, and implementation practices that support effectively leveraging NHibernate in situations where (for all kinds of really good requirements reasons) your database schema design occupies a position of primacy in the hierarchy of your design constraints.
In this session we dig into the use of the MyGeneration OSS code-generation toolset and understand how we can use it to completely slave our Data Transfer Objects and their related .hbm.xml mapping files to the design of our database schema, entirely freeing us from having to manually code and maintain these solution artifacts during our development process.
We also investigate techniques to avoid the inclusion of ‘string-literal’ values in our CriteriaAPI and HQL queries so that we can get complete compile-time type-checking on all of the statements in our NHibernateDataProvider class if/when things change in other layers of our application (e.g., the database schema), making reacting to change and catching errors all the more simpler for us.
There isn’t a whole lot of new NHIbernate-centric content in this screencast as its more about how to use tools and techniques to drive NHibernate in certain kinds of application design situations, but hopefully people will still find it to be of value.
As usual, comments and feedback (and criticism!) are greatly appreciated.
[…] Unhandled Exceptions Blog Archive Summer of NHibernate Session Posted by root 1 hour 4 minutes ago (http://unhandled-exceptions.com) I 39 ve been trying out the microdesk mygeneration template using the adventureworks database the code that gets generated with the same Discuss | Bury | News | Unhandled Exceptions Blog Archive Summer of NHibernate Session […]
I have a problem with MyGeneration templates.I was using this since 2 weeks but suddenly it giving me following error when I am executing.
Executing: DNN Controller C#
ERROR: [Zeus.ErrorHandling.ZeusRuntimeException] – Template Runtime Exception
– Canceled Template execution: DNN Controller C#
Thanks in advance…
I’m having problems with MyGeneration too but a much different issue. When I Execute the template the form opens and there is only the Options tab shows. Neither the Tables or Views tabs show up like they do in the web cast. I get sucessful Test Connections. (Most of the time)
If I go ahead and Generate I get a couple of folders and the project file.
Eventually figured out that the issue was that the database and a couple of database objects (tables) had periods “.” in the names.
Can I use your template with oracle 11g? Actually I have tried and ended up with empty option tabs.
The template itself knows nothing about the type of database to which its connected. The template merely takes the database meta-data reported by MyGeneration and uses it to create outputs (.cs and .xml files) based on that meta-data.
If you’re having troubles using it with ORA11g then I would say that’s more a question for the MyGeneration forum. Sorry I cannot be more helpful~!