[jboss-user] [jBPM] - Re: Unable to start jBPM using a Web service
doboss
do-not-reply at jboss.com
Wed Dec 5 09:16:14 EST 2012
doboss [https://community.jboss.org/people/doboss] created the discussion
"Re: Unable to start jBPM using a Web service"
To view the discussion, visit: https://community.jboss.org/message/780135#780135
--------------------------------------------------------------
Alright, I'm still not quite understanding... Sorry. :)
So are you saying that
a) In all cases, the process runs and you see the println "Process started ..." but you just see the warning and errors in the logs?
b) Only when you run it outside your webservice you see the println "Process started ..." and when you run it in the webservice you don't see "Process started ..."?
I'm not sure exactly which situations you have tested and what the results were, so it's hard for me to guess...
Maybe you can change the code like this:
System.out.println("Seting up data source ...");
JBPMHelper.setupDataSource();
System.out.println("Done with data source setup.");
// load up the knowledge base
KnowledgeBase kbase = readKnowledgeBase(wkfName);
StatefulKnowledgeSession ksession = JBPMHelper.newStatefulKnowledgeSession(kbase);
ksession.getWorkItemManager().registerWorkItemHandler("Semaphore", new WSHumanTaskHandler());
//params
Map<String, Object> params = new HashMap<String, Object>();
params.put("Command", command);
params.put("Parameters", Parameters);
System.out.println("Starting process...");
// start a new process instance
ksession.startProcess(wkfId, params);
System.out.println("Process started.");
Then run the process inside and outside of your webservice and let us know the result. Something like this:
Inside webservice:
*Seting up data source ....*
WARN [bitronix.tm.utils.ManagementRegistrar] (http-localhost-127.0.0.1-8080-1) cannot register object with name bitronix.tm:type=JDBC,UniqueName=jdbc/jbpm-ds: bitronix.tm.internal.BitronixRuntimeException: cannot call method 'registerMBean'
*Done with data source setup.*
*Starting process...*
AVVERTENZA [org.apache.cxf.phase.PhaseInterceptorChain] (http-localhost-127.0.0.1-8080-1) Application { http://webServer.serviceLayer.discoveryreply.eu/ http://webServer.serviceLayer.discoveryreply.eu/}StartWkfWS#{ http://webServer.serviceLayer.discoveryreply.eu/ http://webServer.serviceLayer.discoveryreply.eu/}startWorkflow has thrown exception, unwinding now: org.apache.cxf.interceptor.Fault: loader constraint violation in interface itable initialization: when resolving method "$Proxy189.getXAResource()Ljavax/transaction/xa/XAResource;" the class loader (instance of org/jboss/modules/ModuleClassLoader) of the current class, $Proxy189, and the class loader (instance of <bootloader>) for interface javax/sql/XAConnection have different Class objects for the type javax/transaction/xa/XAResource used in the signature
Outside webservice:
*Seting up data source ....*
WARN [bitronix.tm.utils.ManagementRegistrar] (http-localhost-127.0.0.1-8080-1) cannot register object with name bitronix.tm:type=JDBC,UniqueName=jdbc/jbpm-ds: bitronix.tm.internal.BitronixRuntimeException: cannot call method 'registerMBean'
*Done with data source setup.*
*Starting process...*
AVVERTENZA [org.apache.cxf.phase.PhaseInterceptorChain] (http-localhost-127.0.0.1-8080-1) Application { http://webServer.serviceLayer.discoveryreply.eu/ http://webServer.serviceLayer.discoveryreply.eu/}StartWkfWS#{ http://webServer.serviceLayer.discoveryreply.eu/ http://webServer.serviceLayer.discoveryreply.eu/}startWorkflow has thrown exception, unwinding now: org.apache.cxf.interceptor.Fault: loader constraint violation in interface itable initialization: when resolving method "$Proxy189.getXAResource()Ljavax/transaction/xa/XAResource;" the class loader (instance of org/jboss/modules/ModuleClassLoader) of the current class, $Proxy189, and the class loader (instance of <bootloader>) for interface javax/sql/XAConnection have different Class objects for the type javax/transaction/xa/XAResource used in the signature\
*Process started.*
Also, from the exception, it looks like it's complaining about one resource having a problem with the XA resource... maybe you should post your persistence.xml (with passwords removed)...
Sorry if I'm not helping much, I don't even have JBPM running inside my app yet, let alone with persistence.
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/780135#780135]
Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20121205/983d7c66/attachment.html
More information about the jboss-user
mailing list