- Spring 框架
本周,EclipseLink 团队宣布发布 EclipseLink 1.0。我已经在 S2AP 上使用 EclipseLink 一段时间了;实际上,在开发我们的 JPA 加载时织入支持时,我就使用了 EclipseLink。
我们内部的使用尚未升级到 1.0 版本——我们的 beta9 版本在发布前刚刚打上标签——但我希望展示这种组合在 OSGi 环境中如何有效地工作。
Petclinic 中的 EclipseLink
在 S2AP Petclinic 示例的1.2.0 版本中,我们发布了 Clinic 后端的 EclipseLink 实现。该后端是之前唯一选项 JDBC 后端的直接替代品。
构建 Petclinic EclipseLink
要构建 Petclinic 的 EclipseLink 版本,只需在 Petclinic 根目录中打开终端窗口并运行
cd org.springframework.petclinic.eclipselink
ant collect-provided jar
<p>
This will create the Petclinic EclipseLink PAR file in <span style="font-family:courier">org.springframework.petclinic.eclipselink/target/artifacts/org.springframework.petclinic.eclipselink.par</span> and will put all the required bundles in <span style="font-family:courier">org.springframework.petclinic.eclipselink/target/par-provided/bundles/</span>.
</p>
<h2 id="running-petclinic-eclipselink">
Running Petclinic EclipseLink
</h2>
<p>
To run the Petclinic EclipseLink application, copy all the provided…