You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openjpa.apache.org by Milinda Pathirage <mi...@gmail.com> on 2009/10/29 10:30:33 UTC

OSGi Aware Persistence Provider implementation

We are currently using OpenJPA 1.1.0 in equinox OSGi container by making it
a fragment of the bundle which use it to fix the issue of loading
persistence.xml. Now we want to use OpenJPA in two different OSGi bundles
and fragment hack will not work in this situation. Current 1.3.x OpenJPA
implementation also doesn't support OSGi aware resource loading. We can fix
this by following the method use by Eclipselink. In this method what we have
to do is implement a OSGi aware Persistence Provider by extending the
current Persistence Provider implementation and introduce bundle activator
to register persistence provider service at bundle activation. This will not
break the existing functionality of OpenJPA in J2SE environment and improve
the support for OSGi containers.

Are there any plans to add OSGi support, if there any I would like to help.
I'll provide a patch ASAP for this.

Thanks
Milinda

-- 
Milinda Pathirage
Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
WSO2 Inc.; http://wso2.com
E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
Web: http://mpathirage.com
Blog: http://blog.mpathirage.com

Re: OSGi Aware Persistence Provider implementation

Posted by Donald Woods <dw...@apache.org>.
Yes, I've been trying to work on this in my spare time, but it's really 
waiting for the OSGi EEG to publish an early access release of their 
upcoming specs (including RFC 143 for JPA support) before we can really 
work on this in a true open source manner....

OpenJPA trunk (2.0.0-SNAPSHOT) and the openjpa-osgi module would be the 
right place to target any patches for OSGi support, which we may 
backport to the 1.3.x branch later depending on the required changes.


-Donald


Milinda Pathirage wrote:
> Thanks Kevin for your answers. I'm using OpenJPA in Apache ODE which runs in
> a OSGi environment(WSO2 Carbon platform). I tried OpenJPA 2.0, but there
> were some issues with ODE's JPA queries. I'll try to port current
> implementation to work with OpenJPA 2.0. I also think that it's better if we
> can add OSGi support for OpenJPA 2.0 because I saw there are fixes in
> Geranimo JPA spec jar for OSGi related issues. I'll create a patch for OSGi
> related class loading issues and attach it to a JIRA.
> 
> Thanks in advance,
> Milinda
> 
> 
> On Thu, Oct 29, 2009 at 10:51 PM, Kevin Sutter <kw...@gmail.com> wrote:
> 
>> Hi Milinda,
>> Yes, there is some interest in allowing OpenJPA usage in an OSGi container
>> environment.  It's just not a "full time job" for any of us at the
>> moment...
>>
>> Porting the JDK 6 changes back to the 1.3.x release might cause some
>> concern
>> for those users of the 1.3.x branch.  Many of the changes would now require
>> the use of JDK 6 and we didn't want to force this onto the JPA 1.0 usage
>> community.  Thus, we limited the change to trunk for our JPA 2.0
>> development
>> [1].
>>
>> Is there any reason why your experimentation and changes couldn't be
>> targeted for the JPA 2.0 implementation?  I think you will find our current
>> M3 driver is quite solid, especially as it pertains to existing JPA 1.0
>> functionality.  Thus, any current JPA 1.0 applications should run unchanged
>> with a JPA 2.0 driver.
>>
>> Thanks,
>> Kevin
>>
>> [1]
>>
>> http://n2.nabble.com/DISCUSS-Drop-build-support-for-Java-5-td2539470i20.html#a3554445
>>
>>
>> On Thu, Oct 29, 2009 at 4:49 AM, Milinda Pathirage <
>> milinda.pathirage@gmail.com> wrote:
>>
>>> Hi all,
>>> I have another question. Is there any plan for fixing OpenJPA 1.3.x
>>> compilation failures in JDK 1.6
>>>
>>> Thanks
>>> Milinda
>>>
>>> On Thu, Oct 29, 2009 at 3:00 PM, Milinda Pathirage <
>>> milinda.pathirage@gmail.com> wrote:
>>>
>>>> We are currently using OpenJPA 1.1.0 in equinox OSGi container by
>> making
>>> it
>>>> a fragment of the bundle which use it to fix the issue of loading
>>>> persistence.xml. Now we want to use OpenJPA in two different OSGi
>> bundles
>>>> and fragment hack will not work in this situation. Current 1.3.x
>> OpenJPA
>>>> implementation also doesn't support OSGi aware resource loading. We can
>>> fix
>>>> this by following the method use by Eclipselink. In this method what we
>>> have
>>>> to do is implement a OSGi aware Persistence Provider by extending the
>>>> current Persistence Provider implementation and introduce bundle
>>> activator
>>>> to register persistence provider service at bundle activation. This
>> will
>>> not
>>>> break the existing functionality of OpenJPA in J2SE environment and
>>> improve
>>>> the support for OSGi containers.
>>>>
>>>> Are there any plans to add OSGi support, if there any I would like to
>>> help.
>>>> I'll provide a patch ASAP for this.
>>>>
>>>> Thanks
>>>> Milinda
>>>>
>>>> --
>>>> Milinda Pathirage
>>>> Senior Software Engineer & Product Manager WSO2 BPS;
>> http://wso2.org/bps
>>>> WSO2 Inc.; http://wso2.com
>>>> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
>>>> Web: http://mpathirage.com
>>>> Blog: http://blog.mpathirage.com
>>>>
>>>
>>>
>>> --
>>> Milinda Pathirage
>>> Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
>>> WSO2 <http://wso2.org/bps%0AWSO2> Inc.; http://wso2.com
>>> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
>>> Web: http://mpathirage.com
>>> Blog: http://blog.mpathirage.com
>>>
> 
> 
> 

Re: OSGi Aware Persistence Provider implementation

Posted by Milinda Pathirage <mi...@gmail.com>.
Hi all,
I created JIRA[1] with the patch.

Thanks
Milinda
[1] https://issues.apache.org/jira/browse/OPENJPA-1403

On Fri, Oct 30, 2009 at 8:20 AM, Milinda Pathirage <
milinda.pathirage@gmail.com> wrote:

> Hi Donald,
>
> Thanks for the tips.
>
> Milinda
>
>
> On Fri, Oct 30, 2009 at 2:19 AM, Donald Woods <dw...@apache.org> wrote:
>
>> There is also the Aries project over in the Apache Incubator, which is
>> proposing to develop several of the upcoming OSGi JavaEE RFCs, along with
>> the Blueprint application environment.  I'm hoping that some of the RFC 143
>> work is already done by that project and just waiting on the early access
>> OSGi specs to be released before they can bring it into their svn repo and
>> share it with us....
>>
>> http://incubator.apache.org/projects/aries.html
>>
>>
>> -Donald
>>
>>
>>
>> Milinda Pathirage wrote:
>>
>>> Thanks Kevin for your answers. I'm using OpenJPA in Apache ODE which runs
>>> in
>>> a OSGi environment(WSO2 Carbon platform). I tried OpenJPA 2.0, but there
>>> were some issues with ODE's JPA queries. I'll try to port current
>>> implementation to work with OpenJPA 2.0. I also think that it's better if
>>> we
>>> can add OSGi support for OpenJPA 2.0 because I saw there are fixes in
>>> Geranimo JPA spec jar for OSGi related issues. I'll create a patch for
>>> OSGi
>>> related class loading issues and attach it to a JIRA.
>>>
>>> Thanks in advance,
>>> Milinda
>>>
>>>
>>> On Thu, Oct 29, 2009 at 10:51 PM, Kevin Sutter <kw...@gmail.com>
>>> wrote:
>>>
>>>  Hi Milinda,
>>>> Yes, there is some interest in allowing OpenJPA usage in an OSGi
>>>> container
>>>> environment.  It's just not a "full time job" for any of us at the
>>>> moment...
>>>>
>>>> Porting the JDK 6 changes back to the 1.3.x release might cause some
>>>> concern
>>>> for those users of the 1.3.x branch.  Many of the changes would now
>>>> require
>>>> the use of JDK 6 and we didn't want to force this onto the JPA 1.0 usage
>>>> community.  Thus, we limited the change to trunk for our JPA 2.0
>>>> development
>>>> [1].
>>>>
>>>> Is there any reason why your experimentation and changes couldn't be
>>>> targeted for the JPA 2.0 implementation?  I think you will find our
>>>> current
>>>> M3 driver is quite solid, especially as it pertains to existing JPA 1.0
>>>> functionality.  Thus, any current JPA 1.0 applications should run
>>>> unchanged
>>>> with a JPA 2.0 driver.
>>>>
>>>> Thanks,
>>>> Kevin
>>>>
>>>> [1]
>>>>
>>>>
>>>> http://n2.nabble.com/DISCUSS-Drop-build-support-for-Java-5-td2539470i20.html#a3554445
>>>>
>>>>
>>>> On Thu, Oct 29, 2009 at 4:49 AM, Milinda Pathirage <
>>>> milinda.pathirage@gmail.com> wrote:
>>>>
>>>>  Hi all,
>>>>> I have another question. Is there any plan for fixing OpenJPA 1.3.x
>>>>> compilation failures in JDK 1.6
>>>>>
>>>>> Thanks
>>>>> Milinda
>>>>>
>>>>> On Thu, Oct 29, 2009 at 3:00 PM, Milinda Pathirage <
>>>>> milinda.pathirage@gmail.com> wrote:
>>>>>
>>>>>  We are currently using OpenJPA 1.1.0 in equinox OSGi container by
>>>>>>
>>>>> making
>>>>
>>>>> it
>>>>>
>>>>>> a fragment of the bundle which use it to fix the issue of loading
>>>>>> persistence.xml. Now we want to use OpenJPA in two different OSGi
>>>>>>
>>>>> bundles
>>>>
>>>>> and fragment hack will not work in this situation. Current 1.3.x
>>>>>>
>>>>> OpenJPA
>>>>
>>>>> implementation also doesn't support OSGi aware resource loading. We can
>>>>>>
>>>>> fix
>>>>>
>>>>>> this by following the method use by Eclipselink. In this method what
>>>>>> we
>>>>>>
>>>>> have
>>>>>
>>>>>> to do is implement a OSGi aware Persistence Provider by extending the
>>>>>> current Persistence Provider implementation and introduce bundle
>>>>>>
>>>>> activator
>>>>>
>>>>>> to register persistence provider service at bundle activation. This
>>>>>>
>>>>> will
>>>>
>>>>> not
>>>>>
>>>>>> break the existing functionality of OpenJPA in J2SE environment and
>>>>>>
>>>>> improve
>>>>>
>>>>>> the support for OSGi containers.
>>>>>>
>>>>>> Are there any plans to add OSGi support, if there any I would like to
>>>>>>
>>>>> help.
>>>>>
>>>>>> I'll provide a patch ASAP for this.
>>>>>>
>>>>>> Thanks
>>>>>> Milinda
>>>>>>
>>>>>> --
>>>>>> Milinda Pathirage
>>>>>> Senior Software Engineer & Product Manager WSO2 BPS;
>>>>>>
>>>>> http://wso2.org/bps
>>>>
>>>>> WSO2 Inc.; http://wso2.com
>>>>>> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
>>>>>> Web: http://mpathirage.com
>>>>>> Blog: http://blog.mpathirage.com
>>>>>>
>>>>>>
>>>>>
>>>>> --
>>>>> Milinda Pathirage
>>>>> Senior Software Engineer & Product Manager WSO2 BPS;
>>>>> http://wso2.org/bps
>>>>> WSO2 <http://wso2.org/bps%0AWSO2> Inc.; http://wso2.com
>>>>> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
>>>>> Web: http://mpathirage.com
>>>>> Blog: http://blog.mpathirage.com
>>>>>
>>>>>
>>>
>>>
>>>
>
>
> --
> Milinda Pathirage
> Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
> WSO2 Inc.; http://wso2.com
> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
> Web: http://mpathirage.com
> Blog: http://blog.mpathirage.com
>



-- 
Milinda Pathirage
Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
WSO2 Inc.; http://wso2.com
E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
Web: http://mpathirage.com
Blog: http://blog.mpathirage.com

Re: OSGi Aware Persistence Provider implementation

Posted by Milinda Pathirage <mi...@gmail.com>.
Hi Donald,

Thanks for the tips.

Milinda

On Fri, Oct 30, 2009 at 2:19 AM, Donald Woods <dw...@apache.org> wrote:

> There is also the Aries project over in the Apache Incubator, which is
> proposing to develop several of the upcoming OSGi JavaEE RFCs, along with
> the Blueprint application environment.  I'm hoping that some of the RFC 143
> work is already done by that project and just waiting on the early access
> OSGi specs to be released before they can bring it into their svn repo and
> share it with us....
>
> http://incubator.apache.org/projects/aries.html
>
>
> -Donald
>
>
>
> Milinda Pathirage wrote:
>
>> Thanks Kevin for your answers. I'm using OpenJPA in Apache ODE which runs
>> in
>> a OSGi environment(WSO2 Carbon platform). I tried OpenJPA 2.0, but there
>> were some issues with ODE's JPA queries. I'll try to port current
>> implementation to work with OpenJPA 2.0. I also think that it's better if
>> we
>> can add OSGi support for OpenJPA 2.0 because I saw there are fixes in
>> Geranimo JPA spec jar for OSGi related issues. I'll create a patch for
>> OSGi
>> related class loading issues and attach it to a JIRA.
>>
>> Thanks in advance,
>> Milinda
>>
>>
>> On Thu, Oct 29, 2009 at 10:51 PM, Kevin Sutter <kw...@gmail.com>
>> wrote:
>>
>>  Hi Milinda,
>>> Yes, there is some interest in allowing OpenJPA usage in an OSGi
>>> container
>>> environment.  It's just not a "full time job" for any of us at the
>>> moment...
>>>
>>> Porting the JDK 6 changes back to the 1.3.x release might cause some
>>> concern
>>> for those users of the 1.3.x branch.  Many of the changes would now
>>> require
>>> the use of JDK 6 and we didn't want to force this onto the JPA 1.0 usage
>>> community.  Thus, we limited the change to trunk for our JPA 2.0
>>> development
>>> [1].
>>>
>>> Is there any reason why your experimentation and changes couldn't be
>>> targeted for the JPA 2.0 implementation?  I think you will find our
>>> current
>>> M3 driver is quite solid, especially as it pertains to existing JPA 1.0
>>> functionality.  Thus, any current JPA 1.0 applications should run
>>> unchanged
>>> with a JPA 2.0 driver.
>>>
>>> Thanks,
>>> Kevin
>>>
>>> [1]
>>>
>>>
>>> http://n2.nabble.com/DISCUSS-Drop-build-support-for-Java-5-td2539470i20.html#a3554445
>>>
>>>
>>> On Thu, Oct 29, 2009 at 4:49 AM, Milinda Pathirage <
>>> milinda.pathirage@gmail.com> wrote:
>>>
>>>  Hi all,
>>>> I have another question. Is there any plan for fixing OpenJPA 1.3.x
>>>> compilation failures in JDK 1.6
>>>>
>>>> Thanks
>>>> Milinda
>>>>
>>>> On Thu, Oct 29, 2009 at 3:00 PM, Milinda Pathirage <
>>>> milinda.pathirage@gmail.com> wrote:
>>>>
>>>>  We are currently using OpenJPA 1.1.0 in equinox OSGi container by
>>>>>
>>>> making
>>>
>>>> it
>>>>
>>>>> a fragment of the bundle which use it to fix the issue of loading
>>>>> persistence.xml. Now we want to use OpenJPA in two different OSGi
>>>>>
>>>> bundles
>>>
>>>> and fragment hack will not work in this situation. Current 1.3.x
>>>>>
>>>> OpenJPA
>>>
>>>> implementation also doesn't support OSGi aware resource loading. We can
>>>>>
>>>> fix
>>>>
>>>>> this by following the method use by Eclipselink. In this method what we
>>>>>
>>>> have
>>>>
>>>>> to do is implement a OSGi aware Persistence Provider by extending the
>>>>> current Persistence Provider implementation and introduce bundle
>>>>>
>>>> activator
>>>>
>>>>> to register persistence provider service at bundle activation. This
>>>>>
>>>> will
>>>
>>>> not
>>>>
>>>>> break the existing functionality of OpenJPA in J2SE environment and
>>>>>
>>>> improve
>>>>
>>>>> the support for OSGi containers.
>>>>>
>>>>> Are there any plans to add OSGi support, if there any I would like to
>>>>>
>>>> help.
>>>>
>>>>> I'll provide a patch ASAP for this.
>>>>>
>>>>> Thanks
>>>>> Milinda
>>>>>
>>>>> --
>>>>> Milinda Pathirage
>>>>> Senior Software Engineer & Product Manager WSO2 BPS;
>>>>>
>>>> http://wso2.org/bps
>>>
>>>> WSO2 Inc.; http://wso2.com
>>>>> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
>>>>> Web: http://mpathirage.com
>>>>> Blog: http://blog.mpathirage.com
>>>>>
>>>>>
>>>>
>>>> --
>>>> Milinda Pathirage
>>>> Senior Software Engineer & Product Manager WSO2 BPS;
>>>> http://wso2.org/bps
>>>> WSO2 <http://wso2.org/bps%0AWSO2> Inc.; http://wso2.com
>>>> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
>>>> Web: http://mpathirage.com
>>>> Blog: http://blog.mpathirage.com
>>>>
>>>>
>>
>>
>>


-- 
Milinda Pathirage
Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
WSO2 Inc.; http://wso2.com
E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
Web: http://mpathirage.com
Blog: http://blog.mpathirage.com

Re: OSGi Aware Persistence Provider implementation

Posted by Donald Woods <dw...@apache.org>.
There is also the Aries project over in the Apache Incubator, which is 
proposing to develop several of the upcoming OSGi JavaEE RFCs, along 
with the Blueprint application environment.  I'm hoping that some of the 
RFC 143 work is already done by that project and just waiting on the 
early access OSGi specs to be released before they can bring it into 
their svn repo and share it with us....

http://incubator.apache.org/projects/aries.html


-Donald


Milinda Pathirage wrote:
> Thanks Kevin for your answers. I'm using OpenJPA in Apache ODE which runs in
> a OSGi environment(WSO2 Carbon platform). I tried OpenJPA 2.0, but there
> were some issues with ODE's JPA queries. I'll try to port current
> implementation to work with OpenJPA 2.0. I also think that it's better if we
> can add OSGi support for OpenJPA 2.0 because I saw there are fixes in
> Geranimo JPA spec jar for OSGi related issues. I'll create a patch for OSGi
> related class loading issues and attach it to a JIRA.
> 
> Thanks in advance,
> Milinda
> 
> 
> On Thu, Oct 29, 2009 at 10:51 PM, Kevin Sutter <kw...@gmail.com> wrote:
> 
>> Hi Milinda,
>> Yes, there is some interest in allowing OpenJPA usage in an OSGi container
>> environment.  It's just not a "full time job" for any of us at the
>> moment...
>>
>> Porting the JDK 6 changes back to the 1.3.x release might cause some
>> concern
>> for those users of the 1.3.x branch.  Many of the changes would now require
>> the use of JDK 6 and we didn't want to force this onto the JPA 1.0 usage
>> community.  Thus, we limited the change to trunk for our JPA 2.0
>> development
>> [1].
>>
>> Is there any reason why your experimentation and changes couldn't be
>> targeted for the JPA 2.0 implementation?  I think you will find our current
>> M3 driver is quite solid, especially as it pertains to existing JPA 1.0
>> functionality.  Thus, any current JPA 1.0 applications should run unchanged
>> with a JPA 2.0 driver.
>>
>> Thanks,
>> Kevin
>>
>> [1]
>>
>> http://n2.nabble.com/DISCUSS-Drop-build-support-for-Java-5-td2539470i20.html#a3554445
>>
>>
>> On Thu, Oct 29, 2009 at 4:49 AM, Milinda Pathirage <
>> milinda.pathirage@gmail.com> wrote:
>>
>>> Hi all,
>>> I have another question. Is there any plan for fixing OpenJPA 1.3.x
>>> compilation failures in JDK 1.6
>>>
>>> Thanks
>>> Milinda
>>>
>>> On Thu, Oct 29, 2009 at 3:00 PM, Milinda Pathirage <
>>> milinda.pathirage@gmail.com> wrote:
>>>
>>>> We are currently using OpenJPA 1.1.0 in equinox OSGi container by
>> making
>>> it
>>>> a fragment of the bundle which use it to fix the issue of loading
>>>> persistence.xml. Now we want to use OpenJPA in two different OSGi
>> bundles
>>>> and fragment hack will not work in this situation. Current 1.3.x
>> OpenJPA
>>>> implementation also doesn't support OSGi aware resource loading. We can
>>> fix
>>>> this by following the method use by Eclipselink. In this method what we
>>> have
>>>> to do is implement a OSGi aware Persistence Provider by extending the
>>>> current Persistence Provider implementation and introduce bundle
>>> activator
>>>> to register persistence provider service at bundle activation. This
>> will
>>> not
>>>> break the existing functionality of OpenJPA in J2SE environment and
>>> improve
>>>> the support for OSGi containers.
>>>>
>>>> Are there any plans to add OSGi support, if there any I would like to
>>> help.
>>>> I'll provide a patch ASAP for this.
>>>>
>>>> Thanks
>>>> Milinda
>>>>
>>>> --
>>>> Milinda Pathirage
>>>> Senior Software Engineer & Product Manager WSO2 BPS;
>> http://wso2.org/bps
>>>> WSO2 Inc.; http://wso2.com
>>>> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
>>>> Web: http://mpathirage.com
>>>> Blog: http://blog.mpathirage.com
>>>>
>>>
>>>
>>> --
>>> Milinda Pathirage
>>> Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
>>> WSO2 <http://wso2.org/bps%0AWSO2> Inc.; http://wso2.com
>>> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
>>> Web: http://mpathirage.com
>>> Blog: http://blog.mpathirage.com
>>>
> 
> 
> 

Re: OSGi Aware Persistence Provider implementation

Posted by Milinda Pathirage <mi...@gmail.com>.
Thanks Kevin for your answers. I'm using OpenJPA in Apache ODE which runs in
a OSGi environment(WSO2 Carbon platform). I tried OpenJPA 2.0, but there
were some issues with ODE's JPA queries. I'll try to port current
implementation to work with OpenJPA 2.0. I also think that it's better if we
can add OSGi support for OpenJPA 2.0 because I saw there are fixes in
Geranimo JPA spec jar for OSGi related issues. I'll create a patch for OSGi
related class loading issues and attach it to a JIRA.

Thanks in advance,
Milinda


On Thu, Oct 29, 2009 at 10:51 PM, Kevin Sutter <kw...@gmail.com> wrote:

> Hi Milinda,
> Yes, there is some interest in allowing OpenJPA usage in an OSGi container
> environment.  It's just not a "full time job" for any of us at the
> moment...
>
> Porting the JDK 6 changes back to the 1.3.x release might cause some
> concern
> for those users of the 1.3.x branch.  Many of the changes would now require
> the use of JDK 6 and we didn't want to force this onto the JPA 1.0 usage
> community.  Thus, we limited the change to trunk for our JPA 2.0
> development
> [1].
>
> Is there any reason why your experimentation and changes couldn't be
> targeted for the JPA 2.0 implementation?  I think you will find our current
> M3 driver is quite solid, especially as it pertains to existing JPA 1.0
> functionality.  Thus, any current JPA 1.0 applications should run unchanged
> with a JPA 2.0 driver.
>
> Thanks,
> Kevin
>
> [1]
>
> http://n2.nabble.com/DISCUSS-Drop-build-support-for-Java-5-td2539470i20.html#a3554445
>
>
> On Thu, Oct 29, 2009 at 4:49 AM, Milinda Pathirage <
> milinda.pathirage@gmail.com> wrote:
>
> > Hi all,
> > I have another question. Is there any plan for fixing OpenJPA 1.3.x
> > compilation failures in JDK 1.6
> >
> > Thanks
> > Milinda
> >
> > On Thu, Oct 29, 2009 at 3:00 PM, Milinda Pathirage <
> > milinda.pathirage@gmail.com> wrote:
> >
> > > We are currently using OpenJPA 1.1.0 in equinox OSGi container by
> making
> > it
> > > a fragment of the bundle which use it to fix the issue of loading
> > > persistence.xml. Now we want to use OpenJPA in two different OSGi
> bundles
> > > and fragment hack will not work in this situation. Current 1.3.x
> OpenJPA
> > > implementation also doesn't support OSGi aware resource loading. We can
> > fix
> > > this by following the method use by Eclipselink. In this method what we
> > have
> > > to do is implement a OSGi aware Persistence Provider by extending the
> > > current Persistence Provider implementation and introduce bundle
> > activator
> > > to register persistence provider service at bundle activation. This
> will
> > not
> > > break the existing functionality of OpenJPA in J2SE environment and
> > improve
> > > the support for OSGi containers.
> > >
> > > Are there any plans to add OSGi support, if there any I would like to
> > help.
> > > I'll provide a patch ASAP for this.
> > >
> > > Thanks
> > > Milinda
> > >
> > > --
> > > Milinda Pathirage
> > > Senior Software Engineer & Product Manager WSO2 BPS;
> http://wso2.org/bps
> > > WSO2 Inc.; http://wso2.com
> > > E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
> > > Web: http://mpathirage.com
> > > Blog: http://blog.mpathirage.com
> > >
> >
> >
> >
> > --
> > Milinda Pathirage
> > Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
> > WSO2 <http://wso2.org/bps%0AWSO2> Inc.; http://wso2.com
> > E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
> > Web: http://mpathirage.com
> > Blog: http://blog.mpathirage.com
> >
>



-- 
Milinda Pathirage
Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
WSO2 Inc.; http://wso2.com
E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
Web: http://mpathirage.com
Blog: http://blog.mpathirage.com

Re: OSGi Aware Persistence Provider implementation

Posted by Kevin Sutter <kw...@gmail.com>.
Hi Milinda,
Yes, there is some interest in allowing OpenJPA usage in an OSGi container
environment.  It's just not a "full time job" for any of us at the moment...

Porting the JDK 6 changes back to the 1.3.x release might cause some concern
for those users of the 1.3.x branch.  Many of the changes would now require
the use of JDK 6 and we didn't want to force this onto the JPA 1.0 usage
community.  Thus, we limited the change to trunk for our JPA 2.0 development
[1].

Is there any reason why your experimentation and changes couldn't be
targeted for the JPA 2.0 implementation?  I think you will find our current
M3 driver is quite solid, especially as it pertains to existing JPA 1.0
functionality.  Thus, any current JPA 1.0 applications should run unchanged
with a JPA 2.0 driver.

Thanks,
Kevin

[1]
http://n2.nabble.com/DISCUSS-Drop-build-support-for-Java-5-td2539470i20.html#a3554445


On Thu, Oct 29, 2009 at 4:49 AM, Milinda Pathirage <
milinda.pathirage@gmail.com> wrote:

> Hi all,
> I have another question. Is there any plan for fixing OpenJPA 1.3.x
> compilation failures in JDK 1.6
>
> Thanks
> Milinda
>
> On Thu, Oct 29, 2009 at 3:00 PM, Milinda Pathirage <
> milinda.pathirage@gmail.com> wrote:
>
> > We are currently using OpenJPA 1.1.0 in equinox OSGi container by making
> it
> > a fragment of the bundle which use it to fix the issue of loading
> > persistence.xml. Now we want to use OpenJPA in two different OSGi bundles
> > and fragment hack will not work in this situation. Current 1.3.x OpenJPA
> > implementation also doesn't support OSGi aware resource loading. We can
> fix
> > this by following the method use by Eclipselink. In this method what we
> have
> > to do is implement a OSGi aware Persistence Provider by extending the
> > current Persistence Provider implementation and introduce bundle
> activator
> > to register persistence provider service at bundle activation. This will
> not
> > break the existing functionality of OpenJPA in J2SE environment and
> improve
> > the support for OSGi containers.
> >
> > Are there any plans to add OSGi support, if there any I would like to
> help.
> > I'll provide a patch ASAP for this.
> >
> > Thanks
> > Milinda
> >
> > --
> > Milinda Pathirage
> > Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
> > WSO2 Inc.; http://wso2.com
> > E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
> > Web: http://mpathirage.com
> > Blog: http://blog.mpathirage.com
> >
>
>
>
> --
> Milinda Pathirage
> Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
> WSO2 <http://wso2.org/bps%0AWSO2> Inc.; http://wso2.com
> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
> Web: http://mpathirage.com
> Blog: http://blog.mpathirage.com
>

Re: OSGi Aware Persistence Provider implementation

Posted by Milinda Pathirage <mi...@gmail.com>.
Hi all,
I have another question. Is there any plan for fixing OpenJPA 1.3.x
compilation failures in JDK 1.6

Thanks
Milinda

On Thu, Oct 29, 2009 at 3:00 PM, Milinda Pathirage <
milinda.pathirage@gmail.com> wrote:

> We are currently using OpenJPA 1.1.0 in equinox OSGi container by making it
> a fragment of the bundle which use it to fix the issue of loading
> persistence.xml. Now we want to use OpenJPA in two different OSGi bundles
> and fragment hack will not work in this situation. Current 1.3.x OpenJPA
> implementation also doesn't support OSGi aware resource loading. We can fix
> this by following the method use by Eclipselink. In this method what we have
> to do is implement a OSGi aware Persistence Provider by extending the
> current Persistence Provider implementation and introduce bundle activator
> to register persistence provider service at bundle activation. This will not
> break the existing functionality of OpenJPA in J2SE environment and improve
> the support for OSGi containers.
>
> Are there any plans to add OSGi support, if there any I would like to help.
> I'll provide a patch ASAP for this.
>
> Thanks
> Milinda
>
> --
> Milinda Pathirage
> Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
> WSO2 Inc.; http://wso2.com
> E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
> Web: http://mpathirage.com
> Blog: http://blog.mpathirage.com
>



-- 
Milinda Pathirage
Senior Software Engineer & Product Manager WSO2 BPS; http://wso2.org/bps
WSO2 Inc.; http://wso2.com
E-mail: milinda@wso2.com, milinda.pathirage@gmail.com
Web: http://mpathirage.com
Blog: http://blog.mpathirage.com