Problems using camunda-bpm-mail connectors

Hi Thorben,

ok, so with a little help from the Wildfly IRC I got a working module. I’m pretty sure it get’s properly loaded, since it first complained about one of the dependencies which is now resolved.

<module xmlns="urn:jboss:module:1.0" name="org.camunda.bpm.extension.camunda-bpm-mail-core">
  <resources>
    <resource-root path="camunda-bpm-mail-core-1.0.0.jar" />
  </resources>

  <dependencies>
    <module name="javax.mail.api" />
    <module name="org.slf4j" />
    
    <module name="org.camunda.connect.camunda-connect-core" />
  </dependencies>
</module>

Furthermore I added the the dependency in camunda-engine-plugin-connect

<module xmlns="urn:jboss:module:1.0" name="org.camunda.bpm.camunda-engine-plugin-connect">
  <resources>
    <resource-root path="camunda-engine-plugin-connect-7.5.0.jar" />
  </resources>

  <dependencies>

    <module name="javax.api" />

    <module name="org.camunda.bpm.camunda-engine" />

    <module name="org.camunda.connect.camunda-connect-core" />
    <module name="org.camunda.connect.camunda-connect-http-client" services="import" />
    <module name="org.camunda.connect.camunda-connect-soap-http-client" services="import" />
    <module name="org.camunda.bpm.extension.camunda-bpm-mail-core" services="import" />
  </dependencies>
</module>

Now the wildfly servers tries to load it, but something is still missing:

20:23:37,643 INFO [org.camunda.bpm.connect] (ServerService Thread Pool – 60) CNCT-01004 Discovered provider for connector id ‘http-connector’ and class ‘org.camunda.connect.httpclient.impl.HttpConnectorImpl’: ‘org.camunda.connect.httpclient.impl.HttpConnectorProviderImpl’
20:23:37,655 INFO [org.camunda.bpm.connect] (ServerService Thread Pool – 60) CNCT-01004 Discovered provider for connector id ‘soap-http-connector’ and class ‘org.camunda.connect.httpclient.soap.impl.SoapHttpConnectorImpl’: ‘org.camunda.connect.httpclient.soap.impl.SoapHttpConnectorProviderImpl’
20:23:37,663 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool – 60) MSC000001: Failed to start service org.camunda.bpm.platform.process-engine.default: org.jboss.msc.service.StartException in service org.camunda.bpm.platform.process-engine.default: java.lang.NoClassDefFoundError: org/camunda/bpm/engine/ProcessEngineException
at org.camunda.bpm.container.impl.jboss.service.MscManagedProcessEngineController$1.run(MscManagedProcessEngineController.java:97)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
at org.jboss.threads.JBossThread.run(JBossThread.java:320)
Caused by: java.lang.NoClassDefFoundError: org/camunda/bpm/engine/ProcessEngineException
at org.camunda.bpm.extension.mail.send.SendMailProvider.createConnectorInstance(SendMailProvider.java:27)
at org.camunda.connect.Connectors.registerProvider(Connectors.java:183)
at org.camunda.connect.Connectors.registerConnectors(Connectors.java:173)
at org.camunda.connect.Connectors.initializeConnectors(Connectors.java:160)
at org.camunda.connect.Connectors.loadConnectors(Connectors.java:95)
at org.camunda.connect.plugin.impl.ConnectProcessEnginePlugin.preInit(ConnectProcessEnginePlugin.java:31)
at org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl.invokePreInit(ProcessEngineConfigurationImpl.java:674)
at org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl.init(ProcessEngineConfigurationImpl.java:621)
at org.camunda.bpm.engine.impl.cfg.JtaProcessEngineConfiguration.init(JtaProcessEngineConfiguration.java:58)
at org.camunda.bpm.container.impl.jboss.config.ManagedJtaProcessEngineConfiguration.init(ManagedJtaProcessEngineConfiguration.java:40)
at org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl.buildProcessEngine(ProcessEngineConfigurationImpl.java:612)
at org.camunda.bpm.container.impl.jboss.service.MscManagedProcessEngineController.startProcessEngine(MscManagedProcessEngineController.java:177)
at org.camunda.bpm.container.impl.jboss.service.MscManagedProcessEngineController$2.run(MscManagedProcessEngineController.java:131)
at org.camunda.bpm.container.impl.jboss.service.MscManagedProcessEngineController$2.run(MscManagedProcessEngineController.java:129)
at org.camunda.bpm.container.impl.jboss.util.Tccl.runWithTccl(Tccl.java:53)
at org.camunda.bpm.container.impl.jboss.util.Tccl.runUnderClassloader(Tccl.java:45)
at org.camunda.bpm.container.impl.jboss.service.MscManagedProcessEngineController.startInternal(MscManagedProcessEngineController.java:129)
at org.camunda.bpm.container.impl.jboss.service.MscManagedProcessEngineController$1.run(MscManagedProcessEngineController.java:90)
… 6 more
Caused by: java.lang.ClassNotFoundException: org.camunda.bpm.engine.ProcessEngineException from [Module “org.camunda.bpm.extension.camunda-bpm-mail-core:main” from local module loader @1e5ccce (finder: local module finder @42bbf4 (roots: D:\Dev\camunda-bpm-wildfly10-7.5.0\server\wildfly-10.0.0.Final\modules,D:\Dev\camunda-bpm-wildfly10-7.5.0\server\wildfly-10.0.0.Final\modules\system\layers\base))]
at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:198)
at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:363)
at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:351)
at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:93)
… 24 more

Looking at the stacktrace it doesn’t look like it’s a Wildfly specific error.