JPA/Hibernate in Java SE 6, Best Practices for data access

I am starting a normal Java SE project and i am planning to use JPA/Hibernate. I was wondering if anyone could enlighten me as to what is considered the best way to interact with Hibernate in this environment (data access layers)?


I'm not sure what's considered the best approach to this, but at my workplace, we have based most of our Hibernate interaction on these articles:

Don't let Hibernate steal your identity and Generic Data Access Objects

They show you how to make your mapped classes in a smart way, and how to implement a generic DAO that can be reused for any persistent class. This has worked out nicely for us.

Need Your Help

Best way to parse a dynamic text list in PHP

php regex text parsing

I have below a list of text, it is from a popular online game called EVE Online and this basically gets mailed to you when you kill a person in-game. I'm building a tool to parse these using PHP to

Rails Engine partial in another engine cannot access routes of original engine

ruby-on-rails ruby-on-rails-3.2 rails-engines

The main application is basically a container for multiple engines. One of the main engines is a "dashboard" application that will provide statistics, reports, etc. from the various other engines. ...

Apache ENV var not being set in mod_rewrite rule

apache mod-rewrite

I have the following rules in my .htaccess:

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.