Tck update#104
Conversation
5e807a2 to
c80664e
Compare
| <dependency> | ||
| <groupId>com.sun.xml.bind</groupId> | ||
| <artifactId>jaxb-impl</artifactId> | ||
| <version>4.0.5</version> |
There was a problem hiding this comment.
jaxb-core and jaxb-impl are in the same version - should be in a single property?
| <groupId>org.eclipse</groupId> | ||
| <groupId>org.assertj</groupId> | ||
| <artifactId>assertj-core</artifactId> | ||
| <version>3.23.1</version> |
There was a problem hiding this comment.
let's verify the dependency versions in this pom - dependabot does not see it, but the newer versions may be used e.g.
There was a problem hiding this comment.
Updated all dependencies defined in this module.
| To run all tests: | ||
|
|
||
| ## Run the tests | ||
| mvnw verify |
There was a problem hiding this comment.
from this place it would be ../../mvnw verify?
There was a problem hiding this comment.
I run it from the root dir with -f... so I figured the dev would figure it out :-)
But applied your change anyway.
| TODO | ||
| To run a specific test: | ||
|
|
||
| mvnw verify -Dtck.test=<fullly.qualified.TestClass[:method]> |
|
|
||
| <dependencies> | ||
|
|
||
| <!-- Test cases from the tck. These need to be deployed by hand as |
There was a problem hiding this comment.
the current approach makes it fine with the licenses?
There was a problem hiding this comment.
The license in the TCK jar is Apache 2. Backed up by https://projects.eclipse.org/projects/technology.osgi.
| * made that all producers within the same bundle implement the same | ||
| * interface version (or both of them). | ||
| */ | ||
| @SuppressWarnings("deprecation") |
There was a problem hiding this comment.
We are going to release version 2.0.0 with the deprecation from the early beginning? when it's needed by the spec and tck then it something that will be always with us?
There was a problem hiding this comment.
I tried to explain this in the JIRA, and now added a @deprecated tag with additional explanation. In a nutshell, The EndpointListener interface itself is deprecated in the spec (i.e. should not be used by new code and will likely be removed in future spec releases), and this bridge only exists for that, so is transitively also deprecated. Users should upgrade their libraries/code to the new interface, not rely on this for the old one to work in the future. It's basically a stop-gap measure for TCK compatibility.
|
|
||
| // bitmask of supported listener types | ||
| private static final int | ||
| EL = 1, // EndpointListener |
There was a problem hiding this comment.
let's name those variables ENDPOINT_LISTENER_ID and ENDPOING_EVENT_LISTENER_ID and remove comments
| private static final String | ||
| OC_PREFIX = "(" + Constants.OBJECTCLASS + "=", | ||
| OWN_LISTENER_PROP = EventListenerBridge.class.getName(), | ||
| EL_NAME = EndpointListener.class.getName(), |
| EEL = 2; // EndpointEventListener | ||
|
|
||
| private static final String | ||
| OC_PREFIX = "(" + Constants.OBJECTCLASS + "=", |
There was a problem hiding this comment.
let's use full name OBJECT_CLASS_FILTER_PREFIX
| ${repo;org.glassfish.hk2.osgi-resource-locator;3.0.0}",\ | ||
| org.apache.aries.rsa.discovery.tcp.address=localhost:7668,\ | ||
| org.apache.aries.rsa.discovery.tcp.peers=localhost:7669,\ | ||
| org.apache.aries.rsa.bridge=true,\ |
There was a problem hiding this comment.
if we need to set a property for tck tests then does it mean that normally we are not compatible until you set this property? it should be written is some docs/readme to make users aware
TBH I would recommend changing the default to true and on demand allow users to turn off the bridge (and still have it documented)
There was a problem hiding this comment.
I explained this at length in the JIRA - bottom line is that this is here basically just for the TCK and is extremely unlikely to ever be needed in real systems. The configuration option is left for those cases. Running it by default on all other systems that don't need it is just unnecessary runtime complexity and performance degradation (all endpoint events pass through the bridge, which also becomes a SPOF). I think it's better to leave it off (even though I spent quite some time figuring out how to do this thing with the hooks and all :-) ).
Update TCK tests and add them back into the build.
Includes the EventListenerBridge that adds backwards compatibility necessary for the tests (though rarely needed in practice).