About Me

My photo
"Enoughtheory.com" had its humble beginning in the year 2011 by ( Founder of Enoughtheory.com ) Mr Ravi Kant Soni , an Enterprise Java and Spring Framework Specialist, with a bachelor degree (B.E) in Information Science and Engineering from Reva Institute of Technology at Bangalore. He has been into the software development discipline for many years now. Ravi has worn many hats throughout his tenure, ranging from software development, designing multi-tenant applications, integration of new technology into an existing system, to his current love of writing a Spring Framework book. Currently, he is a lead engineer at HCL Technology. Ravi has focused on Web and Enterprise development using Spring Framework for most of his career and has been extensively involved in application design and implementation. He has developed applications for Core-Bank, HR and Payroll System, and e-Commerce systems using Spring Framework. Ravi Kant Soni is author of book "Learning Spring Application development" http://learningspringapplicationdevelopment.com

Tuesday 8 November 2011

Java Persistence


  • The Java Persistence Architecture API (JPA) is a Java specification, not a productit ; & cannot perform persistence or anything else by itself.
  • JPA is just a set of interfaces, and requires an implementation. 
  • For accessing, persisting, and managing data between Java objects / classes and a relational database.
  • JPA was defined as part of the EJB 3.0 specification , for Object to Relational Mapping (ORM) in the Java Industry.
  • JPA allows POJO (Plain Old Java Objects) to be easily persisted without requiring the classes to implement any interfaces or methods.
  •  JPA also defines a runtime EntityManager API for processing queries and transaction on the objects against the database.
  • JPA defines an object-level query language, JPQL, to allow querying of the objects from the database.
  • This API has borrowed many of the concepts and standards from leading persistence frameworks like Toplink (from Oracle) and Hibernate (from JBoss).
  • One of the great benefits of JPA is that it is an independent API and can nicely integrate with J2EE as well as J2SE applications.
  • POJO – Plain Old Java Object is a term used to refer Java objects that do not extend or implement some specialized classes. 

    Therefore, all normal Java objects are POJO’s only. The following classes are not POJO classes.
    
     class MyServlet extends HttpServlet {}
     class MyRemote implements SessionBean {}

No comments:

Post a Comment