[JBoss jBPM] - Deploy multiple sub-processes / Dynamic fork
by mavrides
Hi all,
I have been reading on this subject for quite a while now and I am still unclear on how I should approach this.
I want to have a main process definition which deploys n instances of another process definition. This number is dynamic. After deploying the new process instances I want my coordinator to wait for them to finish before it finishes. My questions are:
- Is there a way to keep track of the deployed process instances without using JMS?
- How will I keep my state-node in a wait state until the sub-processes finish, without using anything like Object.wait() since they may take up to several days to finish? i.e. I'd like this to be done asynchronously.
This issue could be treated as a sort of Dynamic Fork which has been discussed before but I haven't found a complete solution to it. In this case, how would I implement a Join node that waits for this dynamic number of sub-processes/children to finish?
Any suggestions are appreciated.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4041340#4041340
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4041340
17 years, 8 months
[JBoss jBPM] - Re: Process files not uploaded
by gogoasa
I my case, I used the standard SQL creation table script which comes with the jBpm distribution. I also changed the hibernate dialect to Oracle9Dialect.
The problems manifests itself as follows. Suppose you have a musicians-jndi.properties file that you included in your process archive, at the root level. In an action, trying to call an external EJB service, you would first try to load the jndi properties as follows:
InputStream resourceAsStream = this.getClass().getClassLoader().getResourceAsStream("musicians-jndi.properties");
The exception is :
| 12:03:41,702 ERROR [OnErrorAction] caught exception
| java.lang.RuntimeException: org.jbpm.JbpmException: couldn't get value for file 'musicians-jndi.properties'
| at fr.bnf.entrychain.jbpm.actions.CallServiceDelegate.execute(CallServiceDelegate.java:65)
| at fr.bnf.entrychain.jbpm.actions.AbstractEntryChainAction.execute(AbstractEntryChainAction.java:14)
| at org.jbpm.graph.def.Action.execute(Action.java:122)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:185)
| at org.jbpm.graph.def.Action$$EnhancerByCGLIB$$aa93b1d8.execute(<generated>)
| at org.jbpm.graph.def.Node.execute(Node.java:338)
| at org.jbpm.graph.def.Node.enter(Node.java:318)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:185)
| at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$b129b87c.enter(<generated>)
| at org.jbpm.graph.def.Transition.take(Transition.java:151)
| at org.jbpm.graph.def.Node.leave(Node.java:393)
| at org.jbpm.graph.node.StartState.leave(StartState.java:70)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:185)
| at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$b129b87c.leave(<generated>)
| at org.jbpm.graph.exe.Token.signal(Token.java:194)
| at org.jbpm.graph.exe.Token.signal(Token.java:139)
| at org.jbpm.graph.exe.ProcessInstance.signal(ProcessInstance.java:270)
| at org.jbpm.command.StartProcessInstanceCommand.execute(StartProcessInstanceCommand.java:32)
| at org.jbpm.ejb.impl.CommandServiceBean.execute(CommandServiceBean.java:90)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at org.jboss.invocation.Invocation.performCall(Invocation.java:359)
| at org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:237)
| at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:158)
|
| at org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.java:169
| )
| at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:63)
| at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:121)
| at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:350)
| at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:181)
| at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:168)
| at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:205)
| at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:136)
| at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:648)
| at org.jboss.ejb.Container.invoke(Container.java:954)
| at org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invoke(BaseLocalProxyFactory.java:430)
| at org.jboss.ejb.plugins.local.StatelessSessionProxy.invoke(StatelessSessionProxy.java:103)
| at $Proxy68.execute(Unknown Source)
| at org.jbpm.ejb.impl.CommandListenerBean.onMessage(CommandListenerBean.java:71)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at org.jboss.invocation.Invocation.performCall(Invocation.java:359)
| at org.jboss.ejb.MessageDrivenContainer$ContainerInterceptor.invoke(MessageDrivenContainer.java:495)
| at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:158)
|
| at org.jboss.ejb.plugins.MessageDrivenInstanceInterceptor.invoke(MessageDrivenInstanceInterceptor.java:116)
| at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:63)
| at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:121)
| at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:350)
| at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:181)
| at org.jboss.ejb.plugins.RunAsSecurityInterceptor.invoke(RunAsSecurityInterceptor.java:109)
| at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:205)
| at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:136)
| at org.jboss.ejb.MessageDrivenContainer.internalInvoke(MessageDrivenContainer.java:402)
| at org.jboss.ejb.Container.invoke(Container.java:954)
| at org.jboss.ejb.plugins.jms.JMSContainerInvoker.invoke(JMSContainerInvoker.java:987)
| at org.jboss.ejb.plugins.jms.JMSContainerInvoker$MessageListenerImpl.onMessage(JMSContainerInvoker.java:1287)
| at org.jboss.jms.asf.StdServerSession.onMessage(StdServerSession.java:266)
| at org.jboss.mq.SpyMessageConsumer.sessionConsumerProcessMessage(SpyMessageConsumer.java:905)
| at org.jboss.mq.SpyMessageConsumer.addMessage(SpyMessageConsumer.java:170)
| at org.jboss.mq.SpySession.run(SpySession.java:323)
| at org.jboss.jms.asf.StdServerSession.run(StdServerSession.java:194)
| at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:743)
| at java.lang.Thread.run(Thread.java:595)
| Caused by: org.jbpm.JbpmException: couldn't get value for file 'musicians-jndi.properties'
| at org.jbpm.file.def.FileDefinition.getBytes(FileDefinition.java:196)
| at org.jbpm.instantiation.ProcessClassLoader.getResourceAsStream(ProcessClassLoader.java:43)
| at fr.bnf.entrychain.jbpm.actions.CallServiceDelegate.execute(CallServiceDelegate.java:29)
| ... 77 more
| Caused by: java.lang.NullPointerException
| at org.jbpm.file.def.FileDefinition.getBytesFromDb(FileDefinition.java:213)
| at org.jbpm.file.def.FileDefinition.getBytes(FileDefinition.java:193)
| ... 79 more
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4041329#4041329
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4041329
17 years, 8 months
[JBoss Seam] - Seam + JSF + EJB3 + GWT example application
by RobJellinghaus
http://unrealities.com/gwtjsf/20070427
It is still very unpolished, but the basic pieces are all there and reasonably well assembled. It may now be of interest to anyone working with a similar technology stack.
Included is:
- Seam 1.2.0 + JSF 1.2
- GWT 1.4 preview build (actually, a slightly earlier SVN build)
- My patches to the Ajax4JSF G4JSF integration project, to allow JSF integration with GWT 1.4
- Seam integration to allow GWT components to invoke service interfaces on Seam components
- A Java 1.4 DTO bean generator to work around GWT's Java 5 incompatibility
There is more to do:
- I will be adding a rich-text editing and tree-view browsing interface to the demo.
- Once GWT 1.4 final version ships, I will be landing my G4JSF changes in the Ajax4JSF Subversion tree.
- Once I land the G4JSF changes, I will be submitting this to the Seam distribution as an official example. Hopefully they will take it :-)
All comments very welcome.
Cheers!
Rob
rjellinghaus at gmail dot com
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4041324#4041324
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4041324
17 years, 8 months
[Messaging, JMS & JBossMQ] - Multiple MDBs listening to One P2P Queue - JBoss 4.0.3
by drvodka
Hi,
I have two machines running JBoss AS 4.0.3. Machine1 has a JMS queue deployed. There's one MDB each deployed on both the boxes listening to the queue on Machine1. The max size of each MDB is 1. So I have two similar MDBs (one each on two boxes) listening to the same queue.
When multiple messages are posted into the queue, the MDBs start processing them in a serial order alternatively. Ideally I would like both the MDBs to pick-up messages and start processing simultaneously.
The queue configuration is:
< mbean code="org.jboss.mq.server.jmx.Queue" name="jboss.mq.destination:service=Queue,name=RequestQueue"> < attribute name="ReceiversImpl">org.jboss.mq.server.ReceiversImplLinkedList < /attribute><depends optional-attribute-name="DestinationManager">jboss.mq:service=DestinationManager < /depends> < /mbean>
Can anybody point what's wrong...?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4041321#4041321
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4041321
17 years, 8 months