about Jpa (Java Persistence API)
a good starting point
- Introduction to jpa – http://www.javabeat.net/javabeat/ejb3/articles….
- sun tutorial covering jpa – http://java.sun.com/javaee/5/docs…..
- Introduction to jpa – http://edocs.bea.com/kodo/docs41/full…
the good thing about using JPA is that we can work with different vendors like Hibernate or TopLink underneath, without focusing on specific implementation. In another words we have next layer of abstraction of accessing data.
Main benefits of using JPA are:
- thinking in terms of objects
- quick implementation of data model
- no need to care about DB tables implementation
- for simple mappings you have everything ready to work
- no need to implement mappers to and from object to your db
Disadvantages are:
- SQL queries are not that optimized (like everything that is for general use). So if you need something fast think about using something different.
- frameworks (like Hibernate) are not that intelligent as you could expect.
- when your model gets complex, you need to write queries anyway to retrieve objects
Of course there are some possibilities to overcome problems I’ve mention above.
Good enough to start, check related topics.