On Dec 3, 2006, at 11:11 PM, David Blevins wrote:
On Dec 3, 2006, at 10:09 PM, Manu George wrote:
Hi David,
I have already done that. I will get the
EntityManagerFactory But for getting the entity manager I need to
write a class OpenEJBManagedRuntime implements ManagedRuntime which
looks up the transaction manager of openejb and gives it to
openjpa. I
got that done too.
OpenJPA already has an implementation for OpenEJB, but now that you
mention it I remember it's using
org.openejb.OpenEJB.getTransactionManager() which is now
org.apache.openejb.OpenEJB. I've just checked back in an
org.openejb.OpenEJB class for compatibility. I'll drop them a note
to update this class to the latest:
http://incubator.apache.org/openjpa/docs/openjpa-0.9.0-incubating/
javadoc/org/apache/openjpa/ee/AutomaticManagedRuntime.html
I was playing with the JPA stuff last night and had to bid the
transaction manager into java:TransactionManager. The tests in
openejb-presistence do this with a special java: naming handler:
https://svn.apache.org/repos/asf/incubator/openejb/trunk/openejb3/
container/openejb-persistence/src/test/java/org/apache/openejb/
persistence/java/javaURLContextFactory.java
It would be nice if we could give the JPA implementation the
transaction manager directly.
-dain