You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2021/04/01 13:03:20 UTC
[tomcat] branch 9.0.x updated: Remove Bnd annotation dependency
from Java EE API JARs
This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch 9.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/9.0.x by this push:
new 356e1a4 Remove Bnd annotation dependency from Java EE API JARs
356e1a4 is described below
commit 356e1a48eb34ccc9fea9dee4ae16325940b85b59
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Thu Apr 1 13:53:02 2021 +0100
Remove Bnd annotation dependency from Java EE API JARs
---
java/javax/el/ExpressionFactory.java | 3 ---
java/javax/websocket/ContainerProvider.java | 3 ---
java/javax/websocket/server/ServerEndpointConfig.java | 3 ---
res/bnd/el-api.jar.tmp.bnd | 9 +++++++++
res/bnd/websocket-api.jar.tmp.bnd | 12 ++++++++++++
webapps/docs/changelog.xml | 14 ++++++++++++++
6 files changed, 35 insertions(+), 9 deletions(-)
diff --git a/java/javax/el/ExpressionFactory.java b/java/javax/el/ExpressionFactory.java
index 2d2edba..d98dbfd 100644
--- a/java/javax/el/ExpressionFactory.java
+++ b/java/javax/el/ExpressionFactory.java
@@ -36,13 +36,10 @@ import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReadWriteLock;
import java.util.concurrent.locks.ReentrantReadWriteLock;
-import aQute.bnd.annotation.spi.ServiceConsumer;
-
/**
*
* @since 2.1
*/
-@ServiceConsumer(value=ExpressionFactory.class)
public abstract class ExpressionFactory {
private static final boolean IS_SECURITY_ENABLED =
diff --git a/java/javax/websocket/ContainerProvider.java b/java/javax/websocket/ContainerProvider.java
index f800b34..f95c9ad 100644
--- a/java/javax/websocket/ContainerProvider.java
+++ b/java/javax/websocket/ContainerProvider.java
@@ -19,13 +19,10 @@ package javax.websocket;
import java.util.Iterator;
import java.util.ServiceLoader;
-import aQute.bnd.annotation.spi.ServiceConsumer;
-
/**
* Use the {@link ServiceLoader} mechanism to provide instances of the WebSocket
* client container.
*/
-@ServiceConsumer(value=ContainerProvider.class)
public abstract class ContainerProvider {
private static final String DEFAULT_PROVIDER_CLASS_NAME =
diff --git a/java/javax/websocket/server/ServerEndpointConfig.java b/java/javax/websocket/server/ServerEndpointConfig.java
index 11204c8..fa56ce4 100644
--- a/java/javax/websocket/server/ServerEndpointConfig.java
+++ b/java/javax/websocket/server/ServerEndpointConfig.java
@@ -29,8 +29,6 @@ import javax.websocket.EndpointConfig;
import javax.websocket.Extension;
import javax.websocket.HandshakeResponse;
-import aQute.bnd.annotation.spi.ServiceConsumer;
-
/**
* Provides configuration information for WebSocket endpoints published to a
* server. Applications may provide their own implementation or use
@@ -141,7 +139,6 @@ public interface ServerEndpointConfig extends EndpointConfig {
}
- @ServiceConsumer(value=Configurator.class)
public class Configurator {
private static volatile Configurator defaultImpl = null;
diff --git a/res/bnd/el-api.jar.tmp.bnd b/res/bnd/el-api.jar.tmp.bnd
index c1c7500..0a0cb1a 100644
--- a/res/bnd/el-api.jar.tmp.bnd
+++ b/res/bnd/el-api.jar.tmp.bnd
@@ -25,6 +25,15 @@ Provide-Capability: \
version:List<Version>="3.0,2.2,2.1";\
uses:='${packages;NAMED;javax.el.*}'
+Require-Capability: \
+ osgi.extender;\
+ filter:="(&(osgi.extender=osgi.serviceloader.processor)(version>=1.0.0)(!(version>=2.0.0)))",\
+ osgi.serviceloader;\
+ filter:="(osgi.serviceloader=javax.el.ExpressionFactory)";\
+ osgi.serviceloader="javax.el.ExpressionFactory",\
+ osgi.ee;\
+ filter:="(&(osgi.ee=JavaSE)(version=1.8))"
+
-namesection: javax/el*/;\
Specification-Title='Expression Language';\
Specification-Version=3.0;\
diff --git a/res/bnd/websocket-api.jar.tmp.bnd b/res/bnd/websocket-api.jar.tmp.bnd
index 2001349..af74d5c 100644
--- a/res/bnd/websocket-api.jar.tmp.bnd
+++ b/res/bnd/websocket-api.jar.tmp.bnd
@@ -26,6 +26,18 @@ Provide-Capability: \
version:List<Version>="1.1,1";\
uses:='${packages;NAMED;javax.websocket.*}'
+Require-Capability: \
+ osgi.extender;\
+ filter:="(&(osgi.extender=osgi.serviceloader.processor)(version>=1.0.0)(!(version>=2.0.0)))",\
+ osgi.serviceloader;\
+ filter:="(osgi.serviceloader=javax.websocket.ContainerProvider)";\
+ osgi.serviceloader="javax.websocket.ContainerProvider",\
+ osgi.serviceloader;\
+ filter:="(osgi.serviceloader=javax.websocket.server.ServerEndpointConfig$Configurator)";\
+ osgi.serviceloader="javax.websocket.server.ServerEndpointConfig$Configurator",\
+ osgi.ee;\
+ filter:="(&(osgi.ee=JavaSE)(version=1.8))"
+
-namesection: javax/websocket*/;\
Specification-Title=WebSocket;\
Specification-Version=1.1;\
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index e460e3b..98899d4 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -103,7 +103,21 @@
They eventually become mixed with the numbered issues (i.e., numbered
issues do not "pop up" wrt. others).
-->
+<<<<<<< HEAD
<section name="Tomcat 9.0.46 (markt)" rtext="in development">
+=======
+<section name="Tomcat 10.0.6 (markt)" rtext="in development">
+ <subsection name="Other">
+ <changelog>
+ <fix>
+ Create OSGi <code>Require-Capability</code> sections in manifests for
+ Jakarta API JARs manually rather than via the
+ <code>aQute.bnd.annotation.spi.ServiceConsumer</code> annotation as this
+ triggers TCK failures for downstream consumers of the API JARs. (markt)
+ </fix>
+ </changelog>
+ </subsection>
+>>>>>>> 5651dfad39... Remove Bnd annotation dependency from Jakarta API JARs
</section>
<section name="Tomcat 9.0.45 (markt)" rtext="release in progress">
<subsection name="Catalina">
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org