I would like to add that all examples which I have found are using JPA 1 and spring xml.
A blueprint example with a JPA 2 provider would be great.
I don't think Fuse ESB support JPA 2 out of box.
But you can do some work to try to install JPA API and implementation bundle yourself.
Please let us know what you find.
OK, i have installed the following bundles and features without an error:
osgi:install -s wrap:mvn:net.sf.jt400/jt400/6.6
osgi:install -s wrap:mvn:commons-dbcp/commons-dbcp/1.4
osgi:install -s mvn:org.apache.servicemix.specs/org.apache.servicemix.specs.java-persistence-api-2.0/1.8.0
osgi:install -s mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.openjpa/2.0.0_2
After deploying my bundle which is very similiar to:
Unfortunately I get the following log statements and my bundle doesnt work:
10:52:12,039 | WARN | use-01-13/deploy | container | 305 - org.apache.aries.jpa.container - 0.3.0 | There are no providers available.
if I install an other openjpa version the jpa provider seems to be identified by aries-jpa.
osgi:install -s mvn:org.apache.openjpa/openjpa/2.1.1
But it doesnt work, I get the following error:
Caused by: javax.naming.NotContextException: aries:services/javax.transaction.TransactionManager
my persistence xml settings:
Edited by: akunze on Feb 14, 2012 1:35 PM