You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on May 28, 2018. It is now read-only.
The web app contains a ResourceConfig which registers:
a org.glassfish.hk2.utilities.binding.AbstractBinder;
a javax.ws.rs.core.Feature which, in turn, registers another org.glassfish.hk2.utilities.binding.AbstractBinder.
Since I'm heavily relying on HK2-specific annotations, I tried to add jersey-hk2 as a dependency of the web app but the following came out:
the binder at 1 is configured (i.e. its configure method is invoked during startup);
the binder at 2 is not configured (i.e. its configure method is not invoked during startup).
If I replace org.glassfish.hk2.utilities.binding.AbstractBinder with org.glassfish.jersey.internal.injectin 2, also that binder is properly configured.
I guess (and hope) that depending on jersey-hk2 should be sufficient to consistently register HK2 binders either directly on a ResourceConfig and indirectly through Features.
Description
Given the major breaking change around Jersey DI, I have spent some time today in the attempt to migrate a simple web app based on Jersey 2.25.1 to Jersey 2.26.
The web app contains a
ResourceConfigwhich registers:org.glassfish.hk2.utilities.binding.AbstractBinder;javax.ws.rs.core.Featurewhich, in turn, registers anotherorg.glassfish.hk2.utilities.binding.AbstractBinder.Since I'm heavily relying on HK2-specific annotations, I tried to add
jersey-hk2as a dependency of the web app but the following came out:configuremethod is invoked during startup);configuremethod is not invoked during startup).If I replace
org.glassfish.hk2.utilities.binding.AbstractBinderwithorg.glassfish.jersey.internal.injectin 2, also that binder is properly configured.I guess (and hope) that depending on
jersey-hk2should be sufficient to consistently register HK2 binders either directly on aResourceConfigand indirectly throughFeatures.Test