You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@aries.apache.org by cs...@apache.org on 2017/04/18 12:55:27 UTC
[35/50] aries-jpa git commit: [jpa] Update to use OSGi API snapshots
for the JPA Service
[jpa] Update to use OSGi API snapshots for the JPA Service
Fixes ARIES-1698
git-svn-id: https://svn.apache.org/repos/asf/aries/trunk/jpa@1785281 13f79535-47bb-0310-9956-ffa450edef68
Project: http://git-wip-us.apache.org/repos/asf/aries-jpa/repo
Commit: http://git-wip-us.apache.org/repos/asf/aries-jpa/commit/8b366ae1
Tree: http://git-wip-us.apache.org/repos/asf/aries-jpa/tree/8b366ae1
Diff: http://git-wip-us.apache.org/repos/asf/aries-jpa/diff/8b366ae1
Branch: refs/heads/master
Commit: 8b366ae1b058461bdb5501ea6cf77e0a660febfc
Parents: 0a9a175
Author: timothyjward <ti...@13f79535-47bb-0310-9956-ffa450edef68>
Authored: Fri Mar 3 12:44:20 2017 +0000
Committer: timothyjward <ti...@13f79535-47bb-0310-9956-ffa450edef68>
Committed: Fri Mar 3 12:44:20 2017 +0000
----------------------------------------------------------------------
jpa-container/osgi.bnd | 2 +-
jpa-container/pom.xml | 65 +++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 66 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/aries-jpa/blob/8b366ae1/jpa-container/osgi.bnd
----------------------------------------------------------------------
diff --git a/jpa-container/osgi.bnd b/jpa-container/osgi.bnd
index 8026e5c..0616b1e 100644
--- a/jpa-container/osgi.bnd
+++ b/jpa-container/osgi.bnd
@@ -1,5 +1,5 @@
Export-Package: \
- org.osgi.service.jpa
+ org.osgi.service.jpa;provide:=true
Import-Package: \
javax.persistence;version="[1.1,3)", \
javax.persistence.spi;version="[1.1,3)", \
http://git-wip-us.apache.org/repos/asf/aries-jpa/blob/8b366ae1/jpa-container/pom.xml
----------------------------------------------------------------------
diff --git a/jpa-container/pom.xml b/jpa-container/pom.xml
index a6f4de1..85b0e6b 100644
--- a/jpa-container/pom.xml
+++ b/jpa-container/pom.xml
@@ -30,9 +30,25 @@
<description>Implements the OSGi JPA Container from the enterprise spec. Provider a EntityManagerFactory and EntityManagerFactoryBuilder service</description>
<packaging>bundle</packaging>
+ <repositories>
+ <repository>
+ <id>OSGi Public APIs</id>
+ <snapshots>
+ <enabled>true</enabled>
+ </snapshots>
+ <url>https://oss.sonatype.org/content/repositories/osgi/</url>
+ </repository>
+ </repositories>
+
<dependencies>
<dependency>
<groupId>org.osgi</groupId>
+ <artifactId>org.osgi.service.jpa</artifactId>
+ <version>1.1.0-SNAPSHOT</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.osgi</groupId>
<artifactId>org.osgi.core</artifactId>
<scope>provided</scope>
</dependency>
@@ -47,4 +63,53 @@
<scope>provided</scope>
</dependency>
</dependencies>
+
+ <build>
+ <!-- This configuration makes sure that we backport
+ the OSGi provided APIs to Java 1.6 class compatibility.
+ Becuase of the way the maven-bundle-plugin works we must
+ extract the JAR before we translate and slurp in the API -->
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <version>3.0.0</version>
+ <executions>
+ <execution>
+ <id>extract-osgi-api</id>
+ <phase>process-classes</phase>
+ <goals>
+ <goal>unpack</goal>
+ </goals>
+ <configuration>
+ <artifactItems>
+ <artifactItem>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.service.jpa</artifactId>
+ <outputDirectory>${project.build.outputDirectory}</outputDirectory>
+ <includes>org/osgi/service/jpa/**</includes>
+ </artifactItem>
+ </artifactItems>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>net.orfjackal.retrolambda</groupId>
+ <artifactId>retrolambda-maven-plugin</artifactId>
+ <version>2.5.1</version>
+ <executions>
+ <execution>
+ <id>backport-osgi-api</id>
+ <goals>
+ <goal>process-main</goal>
+ </goals>
+ <configuration>
+ <target>1.6</target>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
</project>
\ No newline at end of file