[ 
https://issues.apache.org/jira/browse/ARIES-1672?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15839385#comment-15839385
 ] 

Christian Schneider commented on ARIES-1672:
--------------------------------------------

I don't think embedding the jpa spec packages makes sense. In OSGi there is the 
general idea that the bundle that offers the service provides the spec. As the 
jpa related service PersistenceProvider is offered by the actual persistence 
provider I think it is a better solution that this provider bundle also embeds 
the spec.

There is a good reason for this. The jpa container is open to be used with spec 
version 2.0 or 2.1. If we provide one of these API packages in the bundle then 
we create duplicates of the api package as the provider might also embed it. If 
then at runtime both specs are available chances are high that a user bundle 
binds to the wrong package.

In any case I will adapt the Provide-Capability.


> JPA API contract is required
> ----------------------------
>
>                 Key: ARIES-1672
>                 URL: https://issues.apache.org/jira/browse/ARIES-1672
>             Project: Aries
>          Issue Type: Bug
>            Reporter: Timothy Ward
>            Assignee: Christian Schneider
>
> The OSGi JPA service spec requires the presence of an OSGi contract for the 
> JPA API. This will probably require Aries JPA to package up its own version 
> of the JPA API. Note that this will only be necessary to function as the 
> official RI, and we can still support using other public API bundles.
> Provide-Capability: osgi.contract;osgi.contract=JavaJPA;
> version:List<Version>="2.1,2,1";uses:="javax.persistence,javax.persistence.criteria,javax.persistence.metamodel,javax.persistence.spi"
> We could optionally choose not to support versions 2 or 1.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to