[jira] [Commented] (ARIES-1672) JPA API contract is required

2017-01-25 Thread Christian Schneider (JIRA)

[ 
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="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)


[jira] [Updated] (ARIES-1672) JPA API contract is required

2017-01-25 Thread Timothy Ward (JIRA)

 [ 
https://issues.apache.org/jira/browse/ARIES-1672?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Timothy Ward updated ARIES-1672:

Assignee: Christian Schneider

> 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="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)


[jira] [Commented] (ARIES-1671) Adding a standard JPA extender capability

2017-01-25 Thread Timothy Ward (JIRA)

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

Timothy Ward commented on ARIES-1671:
-

Also, the extender capability must be taken into account when deciding which 
bundle(s) to extend.

"The JPA extender must only process a persistence bundle's persistence units if 
the following is true:
• The bundle's wiring has a required wire for at least one osgi.extender 
capability with the name osgi.jpa and the first of these required wires is 
wired to the JPA extender.
• The bundle's wiring has no required wire for an osgi.extender capability with 
the name osgi.jpa.

Otherwise, the JPA Service extender must not process the persistence bundle"

> Adding a standard JPA extender capability
> -
>
> Key: ARIES-1671
> URL: https://issues.apache.org/jira/browse/ARIES-1671
> Project: Aries
>  Issue Type: Bug
>  Components: JPA
>Affects Versions: jpa-2.6.0
>Reporter: Timothy Ward
>
> OSGi JPA Service 1.1 compatibility
> The JPA Service extender is required to advertise the following:
> Provide-Capability: osgi.extender;
> osgi.extender="osgi.jpa";
> version:Version="1.1";
> uses:="org.osgi.service.jpa,javax.persistence"



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


[jira] [Updated] (ARIES-1671) Adding a standard JPA extender capability

2017-01-25 Thread Timothy Ward (JIRA)

 [ 
https://issues.apache.org/jira/browse/ARIES-1671?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Timothy Ward updated ARIES-1671:

Assignee: Christian Schneider

> Adding a standard JPA extender capability
> -
>
> Key: ARIES-1671
> URL: https://issues.apache.org/jira/browse/ARIES-1671
> Project: Aries
>  Issue Type: Bug
>  Components: JPA
>Affects Versions: jpa-2.6.0
>Reporter: Timothy Ward
>Assignee: Christian Schneider
>
> OSGi JPA Service 1.1 compatibility
> The JPA Service extender is required to advertise the following:
> Provide-Capability: osgi.extender;
> osgi.extender="osgi.jpa";
> version:Version="1.1";
> uses:="org.osgi.service.jpa,javax.persistence"



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


[jira] [Created] (ARIES-1672) JPA API contract is required

2017-01-25 Thread Timothy Ward (JIRA)
Timothy Ward created ARIES-1672:
---

 Summary: 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


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="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)


[jira] [Created] (ARIES-1671) Adding a standard JPA extender capability

2017-01-25 Thread Timothy Ward (JIRA)
Timothy Ward created ARIES-1671:
---

 Summary: Adding a standard JPA extender capability
 Key: ARIES-1671
 URL: https://issues.apache.org/jira/browse/ARIES-1671
 Project: Aries
  Issue Type: Bug
  Components: JPA
Affects Versions: jpa-2.6.0
Reporter: Timothy Ward


OSGi JPA Service 1.1 compatibility

The JPA Service extender is required to advertise the following:

Provide-Capability: osgi.extender;
osgi.extender="osgi.jpa";
version:Version="1.1";
uses:="org.osgi.service.jpa,javax.persistence"



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


[jira] [Created] (ARIES-1670) Aries JPA should register EntityManagerFactory services after use of the EntityManagerFactory Builder

2017-01-25 Thread Timothy Ward (JIRA)
Timothy Ward created ARIES-1670:
---

 Summary: Aries JPA should register EntityManagerFactory services 
after use of the EntityManagerFactory Builder
 Key: ARIES-1670
 URL: https://issues.apache.org/jira/browse/ARIES-1670
 Project: Aries
  Issue Type: Bug
  Components: JPA
Affects Versions: jpa-2.6.0
Reporter: Timothy Ward
Assignee: Christian Schneider


Support for version 1.1 of the OSGi JPA Service. Ensuring that the EMF becomes 
visible as a service with the relevant service properties, and that it is 
re-registered after rebinding configuration.

"In the case of an incomplete Persistence Unit no Entity Manager Factory can be 
initially registered, however once configured using an Entity Manager Factory 
Builder service the JPA Service must register the created Entity Manager 
Factory as a service. The registered service must include any sup- plied 
configuration properties that match the recommended OSGi service property types 
as service properties. The javax.persistence.jdbc.password property must be 
omitted from these service properties.

If the Entity Manager Factory Builder service is later used to change the 
configuration being used by the Entity Manager Factory Service then the 
registered Entity Manager Factory service must be unregistered and the new 
object registered."



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