[jboss-user] [JBoss jBPM] - Re: jms notbound exception when accessing jbpm context from

gchanteb do-not-reply at jboss.com
Wed Apr 1 04:13:45 EDT 2009


Could you explain it plz ? I have the same problem and I really don't understand why......

I have this process:

<process-definition xmlns="urn:jbpm.org:jpdl-3.2" name="process9">
  | 
  | 	<start-state name="start-state">
  | 		<transition to="state1" name="to state1"/>
  | 	</start-state>
  | 
  | 	<state name="state1">
  | 		<transition to="state2" name="to state2"/>
  | 	</state>
  | 	
  | 	<state name="state2">
  | 		<transition to="endstate" name="to endstate"/>
  | 	</state>
  | 	
  | 	<end-state name="endstate"/>
  | 
  | </process-definition>

When I start my JBoss, I try to launch my process with an EJB client:

  | 	public static void main(String[] args) 
  | 	{	
  | 		String nameProcess = "process9";
  | 		
  | 		// Start a new process and go to state 1.
  | 		long processId = ManagementJBPMDelegate.launchProcess(nameProcess); 
  | 		
  | 		// State 1 to state 2.
  | 		ManagementJBPMDelegate.signalProcess(processId); 
  | 	}

It works.... But, If i do:

  | 	public static void main(String[] args) 
  | 	{	
  | 		String nameProcess = "process9";
  | 		
  | 		// Start a new process and go to state 1.
  | 		long processId = ManagementJBPMDelegate.launchProcess(nameProcess); 
  | 		
  | 		// State 1 to state 2.
  | 		ManagementJBPMDelegate.signalProcess(processId); 
  | 
  | 		// State 2 to endstate.
  | 		ManagementJBPMDelegate.signalProcess(processId); 
  | 	}

It doesn't work, i have this exception:

anonymous wrote : Exception in thread "main" javax.ejb.EJBException: org.jbpm.JbpmException: could not retrieve message connection factory
  | 	at org.jboss.ejb3.tx.Ejb3TxPolicy.handleExceptionInOurTx(Ejb3TxPolicy.java:77)
  | 	at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:83)
  | ...
  | Caused by: org.jbpm.JbpmException: could not retrieve message connection factory
  | 	at org.jbpm.msg.jms.JmsMessageServiceFactory.getConnectionFactory(JmsMessageServiceFactory.java:80)
  | 	at org.jbpm.msg.jms.JmsMessageServiceFactory.openService(JmsMessageServiceFactory.java:140)
  | ...
  | Caused by: javax.naming.NameNotFoundException: jms not bound
  | 	at org.jnp.server.NamingServer.getBinding(NamingServer.java:771)
  | 	at org.jnp.server.NamingServer.getBinding(NamingServer.java:779)

but ... If I start my JSF-console and try to start a process9, from start state to end state, it works!

Then, if i redo my main program which calls EJBs, it works .... :-/... Why ? Do you have any idea?

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4222527#4222527

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4222527



More information about the jboss-user mailing list