<div dir="ltr"><div class="gmail_extra">You might need to implement an SPI [1] that would expose the job XML. WildFly will look for SPI&#39;s and use those to validate and get the job XML data.</div><div class="gmail_extra"><br></div><div class="gmail_extra">[1]: <a href="https://github.com/jberet/jsr352/blob/master/jberet-core/src/main/java/org/jberet/spi/JobXmlResolver.java">https://github.com/jberet/jsr352/blob/master/jberet-core/src/main/java/org/jberet/spi/JobXmlResolver.java</a></div><div class="gmail_extra">[2]: <a href="https://github.com/wildfly/wildfly/blob/master/batch/extension-jberet/src/main/java/org/wildfly/extension/batch/jberet/deployment/WildFlyJobXmlResolver.java#L154-L160">https://github.com/wildfly/wildfly/blob/master/batch/extension-jberet/src/main/java/org/wildfly/extension/batch/jberet/deployment/WildFlyJobXmlResolver.java#L154-L160</a></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Aug 18, 2016 at 12:59 AM, Gunnar Morling <span dir="ltr">&lt;<a href="mailto:gunnar@hibernate.org" target="_blank">gunnar@hibernate.org</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi,<br><br>Is there any example which shows how to deploy a JSR 352 batch job via a module added to WildFly rather than through a deployed application? This batch job should then be usable from applications which declare a dependency to that module.<br><br>Trying this, I&#39;m getting an error saying that the batch job&#39;s XML descriptor cannot be found [1]. I.e. the module with the batch job is visible to the deployed application (as the MassIndexer class can be accessed), but then JBeret cannot &quot;see&quot; the job XML descriptor within that module.<div><br></div><div>Is there anything I can configure in the module.xml of the batch job&#39;s module for exposing its contents to JBeret?<br><br>The use case is Hibernate Search where a GSoC student is working on a JSR 352 batch job for re-indexing entities. This job eventually should be part of Hibernate Search&#39;s modules, allowing users to run it if Hibernate Search is enabled for their application.</div><div><br></div><div>Thanks for any pointers,</div><div><br></div><div>--Gunnar<div><br></div><div>[1] Exception: javax.batch.operations.<wbr>JobStartException: JBERET000601: Failed to get job xml file for job mass-index.xml</div><div>    at org.jberet.creation.<wbr>ArchiveXmlLoader.getJobXml(<wbr>ArchiveXmlLoader.java:129)<br>    at org.jberet.creation.<wbr>ArchiveXmlLoader.loadJobXml(<wbr>ArchiveXmlLoader.java:91)<br>    at org.jberet.operations.<wbr>JobOperatorImpl.start(<wbr>JobOperatorImpl.java:102)<br>    at org.hibernate.search.jsr352.<wbr>MassIndexer.start(MassIndexer.<wbr>java:90)<br></div><div>    at org.hibernate.search.jsr352.<wbr>PerformanceIT.<wbr>testNewMassIndexer(<wbr>PerformanceIT.java:167)<br></div><div>    ...</div></div></div>
<br>______________________________<wbr>_________________<br>
wildfly-dev mailing list<br>
<a href="mailto:wildfly-dev@lists.jboss.org">wildfly-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/wildfly-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/<wbr>mailman/listinfo/wildfly-dev</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>James R. Perkins</div><div>JBoss by Red Hat</div></div></div></div></div>
</div></div>