Hibernate's future development path has been more than half a year, in the Java world, Hibernate is a topic that is the most concerned. Join EJB3.0 EG from Gavin King, responsible for developing EJB3.0's persistent layer specification; to Gavin King informally exits JDO EG, and full of personal emotion attack JDO2.0 specification; to "Hibernate In Action" issuance; Hibernate3 alpha publishes; finally to the release of the recent JBoss 3.0 PR (entity bean using Hibernate3). It can be said that each step in this causes the industry's side. Hibernate In less than 3 years, from a unspeakable open source software to today's mainstream O / R mapping framework, GAVIN KING has become a big person in the industry from an open source software, how many legendary color. After all, it is simply from technical achievements. Hibernate is not the most achieved Java open source framework software. It is not a perfect software for the current technology; GAVIN KING is not a superior master from a personal technology level. In the current Java persistence layer frame, the most popular O / R mapping products are Hibernate, JDO, and Toplink, respectively. Since Gavin King joins JBOS last year, Hibernate has embarked on a road that is compatible with EJB EntityBean. However, more side is that GAVIN KING acts as a very important role in EJB3.0 EG, as long as the EJB3.0's EntityBean and Hibernate3, the truth will be white, although the API interface is different, but EntityBean design concept It comes from hibernate. Although EJB3.0's EntityBean is from Hibernate to a considerable extent, it is a different relationship between Hibernate and EJB3.0 EntityBean, which is a question in many people. During this year, JBoss's Ben Wang visited China, I used to ask Ben to ask Hibernate's future development. He replied that Hibernate will still have independent software products in the future, or both Outside EJB Container; at the same time Hibernate will also do For JBoss EntityBean Implementation, you can use the inside ejb container. However, how both INSIDE, OUTSIDE, and finally lack a sense of understanding. October 8 JBoss released EJB3.0 PR uncovered the answer. Looking at the source code from the SourceForge CVS server, we can find that Gavin King has a simple package to Hibernate3, converting the EJB 3.0 EntityBean API to internal Hibernate3's own API, enabling EJB3.0 EntityBean. EJB3.0 does not promise to disengage from the container, if you want to enjoy EJB3.0, you must run in a container provided by an EJB Vendor, such as the container you provide with JBoss, then you call the EntityBean API, these call requests The call request converted to the Hibernate API. This means that Hibernate actually provides two sets of APIs: a set is Hibernate native API; another set is compatible with EJB3.0 EntityBean API.
For developers who need distributed call support, they need to choose a set of APIs after they choose; for developers who do not need EJB containers, they choose the previous set of APIs. This is the established development strategy of Hibernate. The JDO2.0 standard passed by this summer is not inferior to Hibernate's current version. Some functions are even better than Hibernate, such as Lazy Loading for class properties, and Hibernate is 3 only support The current hibernate only supports lazy loading of the class. In fact, in last year, many users have continuously proposed the needs of Lazy Loading for class properties, but Gavin King has never thought that this demand has the need to add. Then, for example, Gavin King described as "abominable" JDOQL, it is actually a mixture of class SQL query language and object condition query. Functional, it is better to be strong, but far more than Hibernate's own conditions. I don't know what exactly, Gavin King seems to have been a disgusted with JDO. In May of this year, he made a critical critique of JDO in Hibernate's Blog, which enumerated the shortcomings of JDO to explain why The EJB3 persistent layer specification did not take JDO to take into account. However, in fact, his criticism is full of misunderstanding and prejudice to JDO, such as Gavin King hates JDOQL, there is no special reason, just because JDOQL is not a pure query language, but a mixture, how much is GAVIN KING The style is regrettable. After being refuted by Solarmetric's Abe White, "I don't have time to do this unnecessary argument. In fact, everyone thinks his own technology is the best ... I am wrong, JDO The gang is also wrong, everyone will make mistakes ... ". (So people who haven't finished!) The introduction of JDO2 norms in fact constitutes a serious threat to Hibernate, and even Hibernate Ideas, EJB3.0 EntityBean. JDO1.0 specification has caused JDO unable to face Hibernate and Toplink competition, however, the functionally complete JDO2 has a lot of JDO Vendor business support, and the JDO specification can avoid product lock in a Vendor's advantage It has been pulled straight from the competition. However, the division of two major commercial mainstream standards of JDO2 and EJB3 is most people, and even don't want to see manufacturers. So the final EJB3 Lead Linda Demichiel and JDO2 LEAD Craig Russell jointly published a public letter, announcing a plan for merging EJB3 and JDO2 persistent layers, and new persistence specifications will be based on JSR-220 (EJB3.0). Basis, fusion of partial features of JDO2. The new persistence layer specification will enter J2EE 1.5, existence independently of EJB, can be used in an Inside J2EE container or out of J2EE container, independent operation. This new persistent layer framework can be said to be a political product. EJB VENDORS is against JDO for its own interests, making JDOs have a part of J2EE, but the standard split is also more unwoven, and final JDO has become a victim of political struggle.
From the surface, JDO and EJB3.0 EntityBean will be replaced by the new persistence layer framework. It seems that JDO does not suffer, but in fact the JDO2 standard has matured, and some JDO leader's products have been accomplished, while EJB3. 0 EntityBean is still in Early Draft, waiting for the product to be born is also a year after a year; it is also worthy of intriguing, the new persistence framework will be based on the current EJB3.0 EntityBean, combined with JDO2 specification, and will be in EJB3.0 Under the control of EG, add some JDO2 EG members. It can therefore be seen that the new persistence layer framework is undoubtedly developed by EJB3.0 EG. In the long run, the political struggle of EJB3 and JDO2 is good for both parties. The consequences of long-term splits are unfavorable to the development of both sides. However, from the short term, JDO2 is indeed in this political struggle. The most direct reflection is that there are some JDO users who have been shaken and confused by JDO, and many JDO enthusiasts are blunting JDOs. However, for JDO, things may not be so pessimistic. Because the final release of the new persistence layer is the fastest in 2005, this is an optimistic estimate, more extensive use is 2006. And if the new persistence layer is still as serious as EJB3 EntityBean, it will not be doubtful to use many currently running systems and legacy systems. These are the market survival space of JDO2. With this time buffer, JDO Vendor will be able to transition into a supplier of J2EE1.5 persistent layer frameworks, facing a broader corporate customer group. Toplink is an old-name O / R mapping software. Since the acquisition of Oracle, it has added good support to the Oracle database, and supports Oracle As EntityBean. Oracle provides Toplink graphic design environments, which can make the Toplink domain model that can be used alone in Toplink alone or in EJB CMP. Therefore, it seems that Toplink has also taken a way with Hibernate's same strategy. Toplink's question is that Toplink is neither sourced and selling prices than Hibernate's open source and free advantages. Original commercial software Toplink should have enough advantages in technical support and commercial propaganda strategies, ORACLE is a company that is based on a database as a core product, and all products are served for database sales performance. In the Oracle product line, it is in a subordinate toplink. Because of the innate deficiency, it can only look at the increasingness of Hibernate, so Toplink is more confirmed by the Oracle database and bounds the user population of Oracle databases. J2EE1.5's new persistent layer specification will become the mainstream API of future persistent layers frames, whether it is Hibernate, JDO, or Toplink will eventually be compatible with this mainstream commercial API. Among the current three persistent layers APIs, Hibernate is undoubtedly the most promising. This is because: 1, the new persistence layer specification will be based on EJB3.0 EntityBean specification, which means that it will still be based on Hibernate's design concept. To achieve a product, you can have a relatively large influence on the EJB3.0 specification. 3. According to the interior leakage, the project manager of the WebLogic9 product line of BEA has implemented the persistence layer framework for EJB3.0 in Hibernate2.