I'm new to Hibernate (using Hibernate3). I took a first shot at developing an application in J2SE using Hibernate and had some mixed results. Figuring that it was more due to my lack of understanding of Hibernate, I threw it out and started over using the examples from the Hibernate CaveatEmptor as a starting point. I now have all but that last part finalized.
In particular, I've tried wrapping my DAO method calls (for example, findAll(), makePersistent(), makeTransient(), etc.) in a transaction, but I'm not sure the best way to start and commit the transaction. In my controller code, I don't think I want to have as an example:
I'm looking for suggestions on frameworks for use in a non-managed (no application server) environment for handling transactions. For example, I've tried to use the Command design pattern (GoF) but havent' quite found a way to get that to work.
And as an aside, when I tried to run my application without the beginTransaction calls, I get the following exception:
How can I configure Hibernate not to require transactions?
Thanks. [ October 18, 2005: Message edited by: David Irwin ]