jsr352: JBERET000601: Failed to get job xml file for job
This is a followed issue of #80. I used arquillian to test an installed module containing a batch job. After the succeed deployment of the WAR, I got the below error:
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 20.696 sec <<< FAILURE! - in org.hibernate.search.jsr352.PerformanceIT
testDiffrentMassIndexer(org.hibernate.search.jsr352.PerformanceIT) Time elapsed: 7.002 sec <<< ERROR!
javax.batch.operations.JobStartException: JBERET000601: Failed to get job xml file for job mass-index.xml
at org.jberet.creation.ArchiveXmlLoader.getJobXml(ArchiveXmlLoader.java:129)
at org.jberet.creation.ArchiveXmlLoader.loadJobXml(ArchiveXmlLoader.java:91)
at org.jberet.operations.JobOperatorImpl.start(JobOperatorImpl.java:102)
at org.hibernate.search.jsr352.MassIndexer.start(MassIndexer.java:90)
at org.hibernate.search.jsr352.PerformanceIT.testNewMassIndexer(PerformanceIT.java:163)
at org.hibernate.search.jsr352.PerformanceIT.testDiffrentMassIndexer(PerformanceIT.java:117)
My job XML is not found by the batch runtime. Here’re some points that I’ve checked:
-
The job XML
mass-index.xmlhas been included in the module’s jar file. I checked by viewing the Contents of a JAR File. It is located at:META-INF/batch-jobs/mass-index.xml -
The SPI of
JobXmlResolverhas been implemented usingorg.jberet.tools.MetaInfBatchJobsJobXmlResolver, it has been included in the module, located at:META-INF/services/org.jberet.spi.JobXmlResolver -
The arquillian deployment works with jboss deploement structure file, where the dependency on the module include a dependency on its META-INF directory, as suggested in the mailing-list.
<jboss-deployment-structure xmlns="urn:jboss:deployment-structure:1.1"> <deployment> <dependencies> <module name="org.hibernate.search.jsr352" services="export" export="true" slot="${project.version}" meta-inf="import"/> </dependencies> </deployment> </jboss-deployment-structure>
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 16 (7 by maintainers)
Are you running the test with Arq embedded? How did you install your module to the WildFly? Can you try Arq remote config, or package the test as a standard war and deploy to WildFly, just to eliminate one variable?