Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix OSGi headers for CDI & MP Jersey modules to be compatible with EE8 #5122

Merged
merged 2 commits into from
Aug 26, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions ext/bean-validation/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
<Export-Package>org.glassfish.jersey.server.validation.*;version=${project.version}</Export-Package>
<Import-Package>
${javax.annotation.osgi.version},
${cdi.osgi.version},
javax.validation.*;resolution:=optional;version="${range;[==,3);${javax.validation.api.version}}",
*
</Import-Package>
Expand Down
14 changes: 14 additions & 0 deletions ext/cdi/jersey-cdi-rs-inject/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,20 @@
<show>package</show>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<inherited>true</inherited>
<extensions>true</extensions>
<configuration>
<instructions>
<Import-Package>
${cdi.osgi.version},
*
</Import-Package>
</instructions>
</configuration>
</plugin>
</plugins>
</build>

Expand Down
4 changes: 4 additions & 0 deletions ext/cdi/jersey-cdi1x-servlet/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,10 @@
<configuration>
<instructions>
<Export-Package>org.glassfish.jersey.ext.cdi1x.servlet.internal</Export-Package>
<Import-Package>
${cdi.osgi.version},
*
</Import-Package>
</instructions>
</configuration>
</plugin>
Expand Down
6 changes: 5 additions & 1 deletion ext/cdi/jersey-cdi1x-transaction/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,11 @@
<configuration>
<instructions>
<Export-Package>org.glassfish.jersey.ext.cdi1x.transaction.internal</Export-Package>
<Import-Package>${javax.annotation.osgi.version},*</Import-Package>
<Import-Package>
${javax.annotation.osgi.version},
${cdi.osgi.version},
*
</Import-Package>
</instructions>
</configuration>
</plugin>
Expand Down
6 changes: 5 additions & 1 deletion ext/cdi/jersey-cdi1x-validation/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,11 @@
<configuration>
<instructions>
<Export-Package>org.glassfish.jersey.ext.cdi1x.validation.internal;version=${project.version}</Export-Package>
<Import-Package>${javax.annotation.osgi.version},*</Import-Package>
<Import-Package>
${javax.annotation.osgi.version},
${cdi.osgi.version},
*
</Import-Package>
</instructions>
</configuration>
</plugin>
Expand Down
1 change: 1 addition & 0 deletions ext/cdi/jersey-cdi1x/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@
<Import-Package>
${javax.annotation.osgi.version},
${hk2.osgi.version},
${cdi.osgi.version},
*
</Import-Package>
</instructions>
Expand Down
2 changes: 2 additions & 0 deletions ext/microprofile/mp-rest-client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,8 @@
org.glassfish.jersey.restclient.*;version=${project.version}
</Export-Package>
<Import-Package>
${cdi.osgi.version},
org.eclipse.microprofile.rest.client.*;version=[1,3),
jansupol marked this conversation as resolved.
Show resolved Hide resolved
*
</Import-Package>
</instructions>
Expand Down
3 changes: 2 additions & 1 deletion incubator/cdi-inject-weld/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,8 @@
</Export-Package>
<Import-Package>
sun.misc.*;resolution:=optional,
${jakarta.annotation.osgi.version},
${cdi.osgi.version},
${javax.annotation.osgi.version},
*
</Import-Package>
</instructions>
Expand Down
1 change: 1 addition & 0 deletions inject/cdi2-se/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@
</Export-Package>
<Import-Package>
sun.misc.*;resolution:=optional,
${cdi.osgi.version},
${javax.annotation.osgi.version},
*
</Import-Package>
Expand Down
1 change: 1 addition & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2173,6 +2173,7 @@
<!-- do not need CQs -->
<cdi.api.version>1.2</cdi.api.version>
<cdi2.api.version>2.0.2</cdi2.api.version>
<cdi.osgi.version>javax.enterprise.*;version="[1,3)"</cdi.osgi.version>
<ejb.version>3.2.6</ejb.version>
<gf.impl.version>5.1.0</gf.impl.version>
<grizzly.client.version>1.16</grizzly.client.version>
Expand Down
30 changes: 30 additions & 0 deletions tests/integration/cdi-integration/gf-cdi-inject/arquillian.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0"?>
<!--

Copyright (c) 2022 Oracle and/or its affiliates. All rights reserved.

This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
http://www.eclipse.org/legal/epl-2.0.

This Source Code may also be made available under the following Secondary
Licenses when the conditions for such availability set forth in the
Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
version 2 with the GNU Classpath Exception, which is available at
https://www.gnu.org/software/classpath/license.html.

SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0

-->
<arquillian xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://jboss.org/schema/arquillian"
xsi:schemaLocation="http://jboss.org/schema/arquillian
http://jboss.org/schema/arquillian/arquillian_1_0.xsd">

<container qualifier="glassfish" default="true">
<configuration>
<property name="debug">true</property>
</configuration>
</container>

</arquillian>
Loading