[JBoss jBPM] - Re: Ad-hoc one of workflow piece
by pjacobsen
Ronald.... thanks for the reply & I gotcha on the terminology.
I had seen the milestone pattern before but I'm not sure if that meets my need? I don't really know when & where in the process definition the user will need to essentially pause the current execution.... perform some arbitrarily complex one-off process... and then return execution to their originally definition afterward. I think the disconnect for me is that my one-off process will not be defined in the original process or the flow.
Examples
For this process definition:
start --> task 1 --> task 2 --> node 3 --> task 4 --> end
We normally expect for the process instance to be just that. But on some occasions users need to be able to define any process that needs to be executed during only one particular instance of the process definition above. For example... while our token in on task 1.... they might say i need the following to execute after node 3 completes but before task 4 starts:
task x --> node y --> task z
making the execution:
start --> task 1 --> task 2 --> node 3 --> (execute sub process above then return) -- > task 4 --> end
or maybe for another instance they need the following to execute after task 1 completes but before task 2 starts:
task m --> task n --> node o --> node p
making the execution
start --> task 1 --> (execute sub process above then return) -- > task 2 --> node 3 --> task 4 --> end
Ultimately my problem is that not only is in not part of the flow... but really it's not a part of the definition either. It's a one-off process definition that needs to be executed at some point in a process instance (essentially pausing it... and then letting it continue after completion).
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4203821#4203821
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4203821
17 years, 3 months
[Beginners Corner] - Should entities bind to JNDI?
by culli
When I deployed an entity with EJB2/xdoclet I could specify a local-jndi-name in @ejb.bean and it would bind to a JNDI name.
How do I do this with EJB 3 annotations? I'm using JBoss 4.2.3GA with no modifications and the first jboss example code from Enterprise JavaBeans 3.0 (Bill Burke/Richard Monson-Haefel). Very basic stuff. I can run the test client just fine.
I'm checking the JNDIView bean for the Cabin bean and it's not there, but I can see the TravelAgent session bean. At some point I need to be able to look up my EJB 3 beans from legacy EJB 2 stuff that won't be converted (at least not within a year or so), so doesn't the EJB 3 entity need to be bound in JNDI?
JNDI View Global:
| +- TopicConnectionFactory (class: org.jboss.naming.LinkRefPair)
| +- jmx (class: org.jnp.interfaces.NamingContext)
| | +- invoker (class: org.jnp.interfaces.NamingContext)
| | | +- RMIAdaptor (proxy: $Proxy47 implements interface org.jboss.jmx.adaptor.rmi.RMIAdaptor,interface org.jboss.jmx.adaptor.rmi.RMIAdaptorExt)
| | +- rmi (class: org.jnp.interfaces.NamingContext)
| | | +- RMIAdaptor[link -> jmx/invoker/RMIAdaptor] (class: javax.naming.LinkRef)
| +- HTTPXAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
| +- ConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
| +- UserTransactionSessionFactory (proxy: $Proxy15 implements interface org.jboss.tm.usertx.interfaces.UserTransactionSessionFactory)
| +- HTTPConnectionFactory (class: org.jboss.mq.SpyConnectionFactory)
| +- XAConnectionFactory (class: org.jboss.mq.SpyXAConnectionFactory)
| +- TransactionSynchronizationRegistry (class: com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionSynchronizationRegistryImple)
| +- UserTransaction (class: org.jboss.tm.usertx.client.ClientUserTransaction)
| +- UILXAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
| +- UIL2XAConnectionFactory[link -> XAConnectionFactory] (class: javax.naming.LinkRef)
| +- persistence.units:jar=titan.jar,unitName=titan (class: org.hibernate.impl.SessionFactoryImpl)
| +- queue (class: org.jnp.interfaces.NamingContext)
| | +- A (class: org.jboss.mq.SpyQueue)
| | +- testQueue (class: org.jboss.mq.SpyQueue)
| | +- ex (class: org.jboss.mq.SpyQueue)
| | +- DLQ (class: org.jboss.mq.SpyQueue)
| | +- D (class: org.jboss.mq.SpyQueue)
| | +- C (class: org.jboss.mq.SpyQueue)
| | +- B (class: org.jboss.mq.SpyQueue)
| +- topic (class: org.jnp.interfaces.NamingContext)
| | +- testDurableTopic (class: org.jboss.mq.SpyTopic)
| | +- testTopic (class: org.jboss.mq.SpyTopic)
| | +- securedTopic (class: org.jboss.mq.SpyTopic)
| +- console (class: org.jnp.interfaces.NamingContext)
| | +- PluginManager (proxy: $Proxy48 implements interface org.jboss.console.manager.PluginManagerMBean)
| +- UIL2ConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
| +- HiLoKeyGeneratorFactory (class: org.jboss.ejb.plugins.keygenerator.hilo.HiLoKeyGeneratorFactory)
| +- TravelAgentBean (class: org.jnp.interfaces.NamingContext)
| +- UILConnectionFactory[link -> ConnectionFactory] (class: javax.naming.LinkRef)
| +- QueueConnectionFactory (class: org.jboss.naming.LinkRefPair)
| +- UUIDKeyGeneratorFactory (class: org.jboss.ejb.plugins.keygenerator.uuid.UUIDKeyGeneratorFactory)
|
Cabin.java
| package com.titan.domain;
|
| import javax.persistence.Entity;
| import javax.persistence.Table;
| import javax.persistence.Column;
| import javax.persistence.Id;
| import org.jboss.annotation.ejb.LocalBinding;
|
| @Entity
| @Table(name="CABIN")
| public class Cabin implements java.io.Serializable
| {
| private int id;
| private String name;
| private int deckLevel;
| private int shipId;
| private int bedCount;
|
| @Id
| @Column(name="ID")
| public int getId()
| {
| ...
persistence.xml
| <persistence>
| <persistence-unit name="titan">
| <jta-data-source>java:/DefaultDS</jta-data-source>
| <properties>
| <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
| </properties>
| </persistence-unit>
| </persistence>
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4203811#4203811
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4203811
17 years, 3 months