WASdev / standards.jsr352.jbatch

Home of 'jbatch', a compatible implementation of the Jakarta Batch specification (and the former Reference Implementation for the JSR 352, Batch Applications for the Java Platform specification).
Other
21 stars 18 forks source link

Glassfish 5 Weld (CDI) level breaks batch app deployment. #53

Closed scottkurz closed 7 years ago

scottkurz commented 7 years ago

With a recent Glassfish 5 build, post CDI integration, e.g. this, the batch CDI extension is broken upon app deploy.

Symptom like:


remote failure: Error occurred during deployment: Exception while loading the app : CDI deployment failure:WELD-001408: Unsatisfied dependencies for type String with qualifiers @BatchProperty
  at injection point [BackedAnnotatedField] @Inject @BatchProperty com.ibm.ws.jbatch.sample.sleepybatchlet.SleepyBatchlet.sleepTimeSecondsProperty
  at com.ibm.ws.jbatch.sample.sleepybatchlet.SleepyBatchlet.sleepTimeSecondsProperty(SleepyBatchlet.java:0)

WELD-001475: The following beans match by type, but none have matching qualifiers:
  - Producer Method [String] with qualifiers [@JaxRsParamQualifier @Any] declared as [[UnbackedAnnotatedMethod] @Produces @JaxRsParamQualifier public org.glassfish.jersey.ext.cdi1x.internal.CdiComponentProvider$JaxRsParamProducer.getParameterValue(InjectionPoint, BeanManager)]
. Please see server.log for more details.
Command deploy failed.
---

The issue seems to be the need to uplevel the dependency on this package to: javax.enterprise.event;version="[2.0,3)"

scottkurz commented 7 years ago

Since we're not making use of newer CDI APIs, for now it's probably might be fine to keep things common and have a new 1.0.x version that can be used in both Glassfish 4 and 5.

We'll branch if/when there is truly a need.

So the import can simply use: javax.enterprise.event;version="[1.0,3)"

scottkurz commented 7 years ago

Fixed in 1.0.2 release.