|JPA setup present and future [message #644283]
||Fri, 10 December 2010 11:37
| Tin N/A
Registered: December 2010
I'd appreciate a few quick pointers/answers to the following questions to help me (and hopefully others) decide on the direction to take with setting up JPA with Virgo:
1. as I understand, Gemini JPA is where JPA is going in the future for OSGi. What approximate timeframe are we looking at for Gemini JPA to be usable in production work with Virgo? Can it be tried now and what to expect? If yes, any setup hints for Gemini JPA M2 + Virgo 2.1.0 are welcome!
2. Presently, EclipseLink provides Equinox OSGi integration via two fragments that enable weaving. How do those fragments cooperate with Spring's context weaving that is used for JTA support (both AspectJ-based and proxies) - any possibility for a potential problem there?
3. Is the time dedicated now to studying and making EclipseLink OSGi integration work wasted from the perspective of future direction that Gemini JPA is taking, or are they similar?
|Re: JPA setup present and future [message #645230 is a reply to message #644351]
||Thu, 16 December 2010 06:42
| Tin N/A
Registered: December 2010
thanks for the reply.
|Dmitry Sklyut wrote on Fri, 10 December 2010|
I am planning to set-up a group of integration tests for virgo-jpa support. Hopeful to start on that work in 2 weeks. If you have any use-cases/requirements you would like to see addressed - please let us know.
I have not tried it - but it should be possible to deploy without jumping through too many hoops. Potential deployment point is in user region.
to either add required bundles to baseBundles or to initialArtifacts properties. Tricky point here is that org.eclipse.gemini.jpa.weaving bundle is a framework extension fragment. Not sure how it will work with current implementation of nested frameworks (i.e. virgo 2.1.x). If you try it - please let us know and submit bugzilla issues.
That sounds very similar to how eclipselink is supposed to be setup in OSGi. I know Virgo scans the extensions in the "lib/" directory when starting (I did some editing on the MANIFEST.MF of the EclipseLink Equionx extension and messed it up so Virgo refused to start), so I'll start with that.
I don't think time will be wasted! If you run into issues, raise bugzilla issues and be loud - this will allow both virgo and gemini developers know how the products are being used and address your issues.
OK, then since EclipseLink currently seems to be similar to Gemini JPA support, I'll start with that and come back to this thread with any questions (or interesting findings) I might run into.
[Updated on: Thu, 16 December 2010 06:43]
Report message to a moderator
|Re: JPA setup present and future [message #675697 is a reply to message #644283]
||Wed, 01 June 2011 08:36
| Frieder Heugel
Registered: October 2010
Location: Basel, CH
the following post is on behalf of a colleague of mine who cannot register himself (register is deactivated for whatever reason).
the past few days I've been trying to get a small example of Gemini JPA using an Oracle database to work.
Here is what I've done so far:
1. Wrapped the oracle drivers into a bundle and put them inside my /repository/usr folder
2. Copied most of the DBAccess code for Derby and reused it for the Oracle driver (or else I would get DataSourceFactory not found exceptions)
3. Copied all of the required jars into the /repository/usr folder namely:
After that I deploy my sample client and entity into Virgo which generates either an "Persistence Unit not found for..." exception, which is mainly because the Gemini JPA bundles are not parsing my persistence.xml, or I get errors because the Gemini JPA weaving bundle is not resolved correctly. I can work around these errors by creating a plan which loads the weaving bundle before the jpa bundle and dropping it into the pickup directory. After I do that the entity gets created in my Oracle database and an EntityManager can be created.
I also tried to add the weaving bundle to the osgi framework as a hook the way it is done for AspectJ but without any luck.
If needed I can attach the projects as well as the driver I am using to connect to the database but for now I just want to know what the correct way would be for me to start the Gemini JPA bundle at Virgo startup.
Thanks in advance,
Powered by FUDForum
. Page generated in 0.02073 seconds