Thanks a lot [~martinkouba] I looked in to qualifiers with some help from colleagues and found that adding a qualifier seems to fix this
I added the below class to the JAR
{code} package org.jboss.tools.lib;
import java.lang.annotation.Retention; import java.lang.annotation.Target; import static java.lang.annotation.ElementType.FIELD; import static java.lang.annotation.ElementType.METHOD; import static java.lang.annotation.ElementType.PARAMETER; import static java.lang.annotation.ElementType.TYPE; import static java.lang.annotation.RetentionPolicy.RUNTIME;
import javax.inject.Qualifier; @Qualifier @Retention(RUNTIME) @Target({TYPE, METHOD, FIELD, PARAMETER}) public @interface Sync {} {code}
Adding this to the method that produces
{code} public @Sync HttpServletRequest produceHttpServletRequest() { {code}
And then where it's injected
{code} @Inject @Sync HttpServletRequest request; {code}
Deploys fine. Do you see any issues with this?
|