JBoss JBPM SVN: r6690 - jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms.
by do-not-reply@jboss.org
Author: bradsdavis
Date: 2010-09-28 08:16:40 -0400 (Tue, 28 Sep 2010)
New Revision: 6690
Added:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsUtil.java
Modified:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
Log:
Added JmsUtil for cleaning up connections, sessions, and message producers.
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java 2010-09-28 12:02:37 UTC (rev 6689)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java 2010-09-28 12:16:40 UTC (rev 6690)
@@ -83,22 +83,8 @@
throw new JbpmException("could not send jms message", e);
}
finally {
- if(messageProducer!=null) {
- try {
- messageProducer.close();
- }
- catch (JMSException e) {
- log.warn("could not close message producer", e);
- }
- }
- if(session!=null) {
- try {
- session.close();
- }
- catch (JMSException e) {
- log.warn("could not close jms session", e);
- }
- }
+ JmsUtil.closeSilently(messageProducer);
+ JmsUtil.closeSilently(session);
}
}
@@ -134,14 +120,6 @@
}
public void close() {
- try {
- if(connection!=null)
- {
- connection.close();
- }
- }
- catch (JMSException e) {
- log.warn("could not close jms connection", e);
- }
+ JmsUtil.closeSilently(connection);
}
}
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsUtil.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsUtil.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsUtil.java 2010-09-28 12:16:40 UTC (rev 6690)
@@ -0,0 +1,51 @@
+package org.jbpm.jms;
+
+import javax.jms.Connection;
+import javax.jms.JMSException;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+public class JmsUtil {
+
+ private static final Log log = LogFactory.getLog(JmsUtil.class);
+ private JmsUtil(){
+ //seal
+ }
+
+ public static void closeSilently(MessageProducer producer)
+ {
+ if(producer!=null) {
+ try {
+ producer.close();
+ } catch (JMSException e) {
+ log.warn("issue closing message producer.",e);
+ }
+ }
+ }
+
+ public static void closeSilently(Session session)
+ {
+ if(session!=null) {
+ try {
+ session.close();
+ } catch(JMSException e) {
+ log.warn("issue closing session.",e);
+ }
+ }
+ }
+
+ public static void closeSilently(Connection connection)
+ {
+ if(connection!=null) {
+ try {
+ connection.close();
+ } catch (JMSException e) {
+ log.warn("issue closing connection.",e);
+ }
+ }
+
+ }
+}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsUtil.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
13 years, 7 months
JBoss JBPM SVN: r6689 - jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms.
by do-not-reply@jboss.org
Author: bradsdavis
Date: 2010-09-28 08:02:37 -0400 (Tue, 28 Sep 2010)
New Revision: 6689
Modified:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
Log:
Cleaned up the connector by putting the close in the finally block.
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java 2010-09-28 11:52:37 UTC (rev 6688)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java 2010-09-28 12:02:37 UTC (rev 6689)
@@ -70,30 +70,36 @@
}
void sendWithoutSaving(Job job) {
+ MessageProducer messageProducer = null;
+ Session session = null;
try {
- Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
- MessageProducer messageProducer = session.createProducer(factory.getDestination());
+ session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+ messageProducer = session.createProducer(factory.getDestination());
Message message = session.createMessage();
populateMessage(message, job);
messageProducer.send(message);
-
- try {
- messageProducer.close();
- }
- catch (JMSException e) {
- log.warn("could not close message producer", e);
- }
-
- try {
- session.close();
- }
- catch (JMSException e) {
- log.warn("could not close jms session", e);
- }
}
catch (JMSException e) {
throw new JbpmException("could not send jms message", e);
}
+ finally {
+ if(messageProducer!=null) {
+ try {
+ messageProducer.close();
+ }
+ catch (JMSException e) {
+ log.warn("could not close message producer", e);
+ }
+ }
+ if(session!=null) {
+ try {
+ session.close();
+ }
+ catch (JMSException e) {
+ log.warn("could not close jms session", e);
+ }
+ }
+ }
}
protected void populateMessage(Message message, Job job) throws JMSException {
13 years, 7 months
JBoss JBPM SVN: r6688 - jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms.
by do-not-reply@jboss.org
Author: bradsdavis
Date: 2010-09-28 07:52:37 -0400 (Tue, 28 Sep 2010)
New Revision: 6688
Modified:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
Log:
Moved the message producer and session creation to be per-thread.
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java 2010-09-28 09:17:11 UTC (rev 6687)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java 2010-09-28 11:52:37 UTC (rev 6688)
@@ -21,6 +21,9 @@
*/
package org.jbpm.jms;
+import java.text.DateFormat;
+import java.text.SimpleDateFormat;
+
import javax.jms.Connection;
import javax.jms.JMSException;
import javax.jms.Message;
@@ -29,7 +32,6 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
-
import org.jbpm.JbpmContext;
import org.jbpm.JbpmException;
import org.jbpm.db.JobSession;
@@ -42,6 +44,7 @@
public class JmsConnectorService implements MessageService, SchedulerService {
+ private static final DateFormat sdf = new SimpleDateFormat("yyyy.MM.dd G 'at' HH:mm:ss z");
private static final long serialVersionUID = 1L;
private static final Log log = LogFactory.getLog(JmsConnectorService.class);
@@ -49,28 +52,18 @@
private final JobSession jobSession;
private final Connection connection;
- private final Session session;
- private final MessageProducer messageProducer;
-
+
+ private final JmsConnectorServiceFactory factory;
+
public JmsConnectorService(JmsConnectorServiceFactory factory) throws JMSException {
JbpmContext jbpmContext = factory.getJbpmConfiguration().getCurrentJbpmContext();
if (jbpmContext == null) throw new JbpmException("no active jbpm context");
jobSession = jbpmContext.getJobSession();
-
- this.connection = factory.getConnectionFactory().createConnection();
- /*
- * if the connection supports xa, the session will be transacted, else the session will auto
- * acknowledge; in either case no explicit transaction control must be performed - see ejb
- * 2.1 - 17.3.5
- */
- session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
- messageProducer = session.createProducer(factory.getDestination());
+
+ this.factory = factory;
+ this.connection = factory.getConnectionFactory().createConnection();
}
- public Session getSession() {
- return session;
- }
-
public void send(Job job) {
jobSession.saveJob(job);
sendWithoutSaving(job);
@@ -78,9 +71,25 @@
void sendWithoutSaving(Job job) {
try {
+ Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+ MessageProducer messageProducer = session.createProducer(factory.getDestination());
Message message = session.createMessage();
populateMessage(message, job);
messageProducer.send(message);
+
+ try {
+ messageProducer.close();
+ }
+ catch (JMSException e) {
+ log.warn("could not close message producer", e);
+ }
+
+ try {
+ session.close();
+ }
+ catch (JMSException e) {
+ log.warn("could not close jms session", e);
+ }
}
catch (JMSException e) {
throw new JbpmException("could not send jms message", e);
@@ -92,7 +101,13 @@
if (job instanceof Timer) {
Timer timer = (Timer) job;
+
+ if(log.isDebugEnabled()) {
+ log.debug("Creating timer for job: "+job.getId()+" to execute at: "+(timer.getDueDate() == null ? "no set date" : sdf.format(timer.getDueDate())));
+ }
message.setLongProperty("JMS_JBOSS_SCHEDULED_DELIVERY", timer.getDueDate().getTime());
+ //higher priority for timers.
+ message.setJMSPriority(9);
}
}
@@ -113,24 +128,13 @@
}
public void close() {
- try {
- messageProducer.close();
+ try {
+ if(connection!=null)
+ {
+ connection.close();
+ }
}
catch (JMSException e) {
- log.warn("could not close message producer", e);
- }
-
- try {
- session.close();
- }
- catch (JMSException e) {
- log.warn("could not close jms session", e);
- }
-
- try {
- connection.close();
- }
- catch (JMSException e) {
log.warn("could not close jms connection", e);
}
}
13 years, 7 months
JBoss JBPM SVN: r6687 - in jbpm3/branches/jbpm-3.2-soa: enterprise/src/main/java/org/jbpm/ejb/impl and 4 other directories.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2010-09-28 05:17:11 -0400 (Tue, 28 Sep 2010)
New Revision: 6687
Added:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/CommandListenerBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/CommandServiceBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/JobListenerBean.java
Removed:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java
Modified:
jbpm3/branches/jbpm-3.2-soa/distribution/src/main/resources/destination/jbpm-jbm-service.xml
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.cfg.xml
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/ejb-jar.xml
jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
Log:
JBPM-2945 acquire a jms connection each time one is needed instead of reusing a cached connection;
employ separate queues for timers and other jobs to prevent timers from falling behind
Modified: jbpm3/branches/jbpm-3.2-soa/distribution/src/main/resources/destination/jbpm-jbm-service.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/distribution/src/main/resources/destination/jbpm-jbm-service.xml 2010-09-27 21:40:46 UTC (rev 6686)
+++ jbpm3/branches/jbpm-3.2-soa/distribution/src/main/resources/destination/jbpm-jbm-service.xml 2010-09-28 09:17:11 UTC (rev 6687)
@@ -1,10 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
- This file defines the default Queues and Topics that jBPM ships with.
- The default Queues and Topics are used by the Command Listener Bean
- and the producer-consumer pair formed by the JMS Message Service and
- the Job Listener Bean.
+ This file defines the default queues that jBPM ships with.
+ The default queues are used by the Command Listener Bean
+ and the producer-consumer pair formed by the JMS Connector Service and
+ the Job/Timer Listener Bean.
You can add other destinations to this file, or you can create other
*-service.xml files to contain your application's destinations.
@@ -23,6 +23,14 @@
</mbean>
<mbean code="org.jboss.jms.server.destination.QueueService"
+ name="jboss.messaging.destination:service=Queue,name=JbpmTimerQueue"
+ xmbean-dd="xmdesc/Queue-xmbean.xml">
+ <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+ <depends>jboss.messaging:service=PostOffice</depends>
+ <attribute name="RedeliveryDelay">1000</attribute>
+ </mbean>
+
+ <mbean code="org.jboss.jms.server.destination.QueueService"
name="jboss.messaging.destination:service=Queue,name=JbpmCommandQueue"
xmbean-dd="xmdesc/Queue-xmbean.xml">
<depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java 2010-09-27 21:40:46 UTC (rev 6686)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java 2010-09-28 09:17:11 UTC (rev 6687)
@@ -93,9 +93,7 @@
private MessageDrivenContext messageDrivenContext;
private LocalCommandService commandService;
-
private ConnectionFactory jmsConnectionFactory;
- private Connection jmsConnection;
private static final Log log = LogFactory.getLog(CommandListenerBean.class);
@@ -104,18 +102,13 @@
// extract command from message
Command command = extractCommand(message);
if (command == null) return;
+
+ // execute command via local command executor bean
+ Object result;
try {
- // execute command via local command executor bean
- Object result = commandService.execute(command);
- // send a response back if a "reply to" destination is set
- Destination replyTo = message.getJMSReplyTo();
- if (replyTo != null && (result instanceof Serializable || result == null)) {
- sendResult((Serializable) result, replyTo, message.getJMSMessageID());
- }
+ result = commandService.execute(command);
}
catch (RuntimeException e) {
- // MDBs are not supposed to throw exceptions
- messageDrivenContext.setRollbackOnly();
// if this is a locking exception, keep it quiet
if (DbPersistenceService.isLockingException(e)) {
StaleObjectLogConfigurer.getStaleObjectExceptionsLog().error("failed to execute "
@@ -124,7 +117,18 @@
else {
log.error("failed to execute " + command, e);
}
+ // MDBs are not supposed to throw exceptions
+ messageDrivenContext.setRollbackOnly();
+ return;
}
+
+ // send the result back if a "reply-to" destination is set
+ Destination replyTo;
+ if (jmsConnectionFactory != null
+ && (replyTo = message.getJMSReplyTo()) != null
+ && (result instanceof Serializable || result == null)) {
+ sendResult((Serializable) result, replyTo, message.getJMSMessageID());
+ }
}
catch (JMSException e) {
messageDrivenContext.setRollbackOnly();
@@ -152,44 +156,28 @@
private void sendResult(Serializable result, Destination destination, String correlationId)
throws JMSException {
if (log.isDebugEnabled()) log.debug("sending " + result + " to " + destination);
- Session jmsSession = createSession();
+ Connection jmsConnection = jmsConnectionFactory.createConnection();
try {
+ /*
+ * if the connection supports xa, the session will be transacted, else the session will
+ * auto acknowledge; in either case no explicit transaction control must be performed -
+ * see ejb 2.1 - 17.3.5
+ */
+ Session jmsSession = jmsConnection.createSession(false, Session.AUTO_ACKNOWLEDGE);
Message resultMessage = jmsSession.createObjectMessage(result);
resultMessage.setJMSCorrelationID(correlationId);
jmsSession.createProducer(destination).send(resultMessage);
}
finally {
- jmsSession.close();
+ jmsConnection.close();
}
}
- private Session createSession() throws JMSException {
- if (jmsConnection == null) {
- // create jms connection
- jmsConnection = jmsConnectionFactory.createConnection();
- }
- /*
- * if the connection supports xa, the session will be transacted, else the session will auto
- * acknowledge; in either case no explicit transaction control must be performed - see ejb
- * 2.1 - 17.3.5
- */
- return jmsConnection.createSession(false, Session.AUTO_ACKNOWLEDGE);
- }
-
public void setMessageDrivenContext(MessageDrivenContext messageDrivenContext) {
this.messageDrivenContext = messageDrivenContext;
}
public void ejbRemove() {
- if (jmsConnection != null) {
- try {
- jmsConnection.close();
- }
- catch (JMSException e) {
- log.debug("failed to close jms connection", e);
- }
- jmsConnection = null;
- }
jmsConnectionFactory = null;
commandService = null;
messageDrivenContext = null;
@@ -198,18 +186,23 @@
public void ejbCreate() {
try {
Context jndiContext = new InitialContext();
- jmsConnectionFactory = (ConnectionFactory) jndiContext.lookup("java:comp/env/jms/JbpmConnectionFactory");
-
+ // create command service
LocalCommandServiceHome commandServiceHome = (LocalCommandServiceHome) jndiContext.lookup("java:comp/env/ejb/LocalCommandServiceBean");
commandService = commandServiceHome.create();
-
+ // look for optional connection factory
+ try {
+ jmsConnectionFactory = (ConnectionFactory) jndiContext.lookup("java:comp/env/jms/JbpmConnectionFactory");
+ }
+ catch (NamingException e) {
+ log.warn("error retrieving connection factory, results will not be sent back", e);
+ }
jndiContext.close();
}
catch (NamingException e) {
throw new JbpmException("error retrieving command service home", e);
}
catch (CreateException e) {
- throw new JbpmException("error creating command service", e);
+ throw new JbpmException("failed to create command service", e);
}
}
}
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.cfg.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.cfg.xml 2010-09-27 21:40:46 UTC (rev 6686)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.cfg.xml 2010-09-28 09:17:11 UTC (rev 6687)
@@ -1,22 +1,26 @@
<jbpm-configuration>
- <bean name="jbpm.jms.connector.service" class="org.jbpm.jms.JmsConnectorServiceFactory"
- singleton="true">
- <field name="jbpmConfiguration">
- <ref bean="jbpm.configuration" />
- </field>
- </bean>
-
<jbpm-context>
<service name="persistence" factory="org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory" />
<service name="message">
<factory>
- <ref bean="jbpm.jms.connector.service" />
+ <bean class="org.jbpm.jms.JmsConnectorServiceFactory" singleton="true">
+ <field name="jbpmConfiguration">
+ <ref bean="jbpm.configuration" />
+ </field>
+ </bean>
</factory>
</service>
<service name="scheduler">
<factory>
- <ref bean="jbpm.jms.connector.service" />
+ <bean class="org.jbpm.jms.JmsConnectorServiceFactory" singleton="true">
+ <field name="jbpmConfiguration">
+ <ref bean="jbpm.configuration" />
+ </field>
+ <field name="destinationJndiName">
+ <string value="java:comp/env/jms/TimerQueue" />
+ </field>
+ </bean>
</factory>
</service>
<service name="tx" factory="org.jbpm.tx.TxServiceFactory" />
Copied: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/CommandListenerBean.java (from rev 6686, jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java)
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/CommandListenerBean.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/CommandListenerBean.java 2010-09-28 09:17:11 UTC (rev 6687)
@@ -0,0 +1,182 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.ejb;
+
+import java.io.Serializable;
+
+import javax.annotation.Resource;
+import javax.ejb.ActivationConfigProperty;
+import javax.ejb.EJB;
+import javax.ejb.MessageDriven;
+import javax.ejb.MessageDrivenContext;
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.Destination;
+import javax.jms.JMSException;
+import javax.jms.Message;
+import javax.jms.MessageListener;
+import javax.jms.ObjectMessage;
+import javax.jms.Session;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.jbpm.command.Command;
+import org.jbpm.persistence.db.DbPersistenceService;
+import org.jbpm.persistence.db.StaleObjectLogConfigurer;
+
+/**
+ * This message-driven bean listens for {@link ObjectMessage object messages} containing a
+ * command instance. The received commands are executed by the {@link CommandServiceBean command
+ * service} bean, using the local interface.
+ *
+ * The body of the message must be a Java object that implements the {@link Command} interface.
+ * The message properties, if any, are ignored.
+ *
+ * <h3>Environment</h3>
+ *
+ * <p>
+ * The environment entries and resources available for customization are summarized in the table
+ * below.
+ * </p>
+ *
+ * <table border="1">
+ * <tr>
+ * <th>Name</th>
+ * <th>Type</th>
+ * <th>Description</th>
+ * </tr>
+ * <tr>
+ * <td><code>ejb/LocalCommandService</code></td>
+ * <td>EJB Reference</td>
+ * <td>Link to the local {@linkplain CommandServiceBean session bean} that executes commands on
+ * a separate jBPM context.</td>
+ * </tr>
+ * <tr>
+ * <td><code>jms/JbpmConnectionFactory</code></td>
+ * <td>Resource Manager Reference</td>
+ * <td>Logical name of the factory that provides JMS connections for producing result messages.
+ * Required for command messages that indicate a reply destination.</td>
+ * </tr>
+ * </table>
+ *
+ * @author Alejandro Guizar
+ */
+@MessageDriven(activationConfig = {
+ @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue")
+})
+public class CommandListenerBean implements MessageListener {
+
+ private static final long serialVersionUID = 1L;
+
+ @Resource
+ private MessageDrivenContext messageDrivenContext;
+ @EJB(name = "ejb/LocalCommandService")
+ private LocalCommandService commandService;
+ @Resource(name = "jms/JbpmConnectionFactory", shareable = true)
+ private ConnectionFactory jmsConnectionFactory;
+
+ private static final Log log = LogFactory.getLog(CommandListenerBean.class);
+
+ public void onMessage(Message message) {
+ try {
+ // extract command from message
+ Command command = extractCommand(message);
+ if (command == null) return;
+
+ // execute command via local command executor bean
+ Object result;
+ try {
+ result = commandService.execute(command);
+ }
+ catch (RuntimeException e) {
+ // if this is a locking exception, keep it quiet
+ if (DbPersistenceService.isLockingException(e)) {
+ StaleObjectLogConfigurer.getStaleObjectExceptionsLog().error("failed to execute "
+ + command, e);
+ }
+ else {
+ log.error("failed to execute " + command, e);
+ }
+ // MDBs are not supposed to throw exceptions
+ messageDrivenContext.setRollbackOnly();
+ return;
+ }
+
+ // send a response back if a "reply to" destination is set
+ Destination replyTo;
+ if (jmsConnectionFactory != null
+ && (replyTo = message.getJMSReplyTo()) != null
+ && (result instanceof Serializable || result == null)) {
+ sendResult((Serializable) result, replyTo, message.getJMSMessageID());
+ }
+ }
+ catch (JMSException e) {
+ messageDrivenContext.setRollbackOnly();
+ log.error("failed to process message " + message, e);
+ }
+ }
+
+ /**
+ * Retrieves a {@link Command} instance from the given message, which is assumed to be an
+ * {@link ObjectMessage}.
+ * <p>
+ * Subclasses may override this method to materialize the command in some other way.
+ * </p>
+ */
+ protected Command extractCommand(Message message) throws JMSException {
+ if (message instanceof ObjectMessage) {
+ ObjectMessage objectMessage = (ObjectMessage) message;
+ Serializable object = objectMessage.getObject();
+ if (object instanceof Command) {
+ return (Command) object;
+ }
+ else {
+ log.warn("not a command: " + object);
+ }
+ }
+ else {
+ log.warn("not an object message: " + message);
+ }
+ return null;
+ }
+
+ private void sendResult(Serializable result, Destination destination, String correlationId)
+ throws JMSException {
+ if (log.isDebugEnabled()) log.debug("sending " + result + " to " + destination);
+ Connection jmsConnection = jmsConnectionFactory.createConnection();
+ try {
+ /*
+ * if the connection supports xa, the session will be transacted, else the session will
+ * auto acknowledge; in either case no explicit transaction control must be performed -
+ * see ejb 2.1 - 17.3.5
+ */
+ Session jmsSession = jmsConnection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+ Message resultMessage = jmsSession.createObjectMessage(result);
+ resultMessage.setJMSCorrelationID(correlationId);
+ jmsSession.createProducer(destination).send(resultMessage);
+ }
+ finally {
+ jmsConnection.close();
+ }
+ }
+}
Copied: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/CommandServiceBean.java (from rev 6683, jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java)
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/CommandServiceBean.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/CommandServiceBean.java 2010-09-28 09:17:11 UTC (rev 6687)
@@ -0,0 +1,146 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.ejb;
+
+import javax.annotation.PostConstruct;
+import javax.annotation.Resource;
+import javax.annotation.Resources;
+import javax.ejb.SessionContext;
+import javax.ejb.Stateless;
+import javax.jms.ConnectionFactory;
+import javax.jms.Queue;
+import javax.sql.DataSource;
+
+import org.jbpm.JbpmConfiguration;
+import org.jbpm.JbpmContext;
+import org.jbpm.JbpmException;
+import org.jbpm.command.Command;
+import org.jbpm.jms.JmsConnectorServiceFactory;
+import org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory;
+
+/**
+ * Stateless session bean that executes {@linkplain Command commands} by calling their
+ * {@link Command#execute(JbpmContext) execute} method on a separate {@link JbpmContext jBPM
+ * context}.
+ *
+ * <h3>Environment</h3>
+ *
+ * <p>
+ * The environment entries and resources available for customization are summarized in the table
+ * below.
+ * </p>
+ *
+ * <table border="1">
+ * <tr>
+ * <th>Name</th>
+ * <th>Type</th>
+ * <th>Description</th>
+ * </tr>
+ * <tr>
+ * <td><code>JbpmCfgResource</code></td>
+ * <td>Environment Entry</td>
+ * <td>The classpath resource from which to read the {@linkplain JbpmConfiguration jBPM
+ * configuration}. Optional, defaults to <code>
+ * jbpm.cfg.xml</code>.</td>
+ * </tr>
+ * <tr>
+ * <td><code>jdbc/JbpmDataSource</code></td>
+ * <td>Resource Manager Reference</td>
+ * <td>Logical name of the data source that provides JDBC connections to the
+ * {@linkplain JtaDbPersistenceServiceFactory persistence service}. Must match the
+ * <code>hibernate.connection.datasource</code> property in the Hibernate configuration file.</td>
+ * </tr>
+ * <tr>
+ * <td><code>jms/JbpmConnectionFactory</code></td>
+ * <td>Resource Manager Reference</td>
+ * <td>Logical name of the factory that provides JMS connections to the
+ * {@linkplain JmsConnectorServiceFactory JMS connector service}. Required for processes that
+ * contain asynchronous continuations.</td>
+ * </tr>
+ * <tr>
+ * <td><code>jms/JobQueue</code></td>
+ * <td>Message Destination Reference</td>
+ * <td>The message service sends job messages to the queue referenced here. Must be
+ * the same queue from which the {@linkplain JobListenerBean job listener bean} receives
+ * messages.</td>
+ * </tr>
+ * <tr>
+ * <td><code>jms/TimerQueue</code></td>
+ * <td>Message Destination Reference</td>
+ * <td>The scheduler service sends timer messages to the queue referenced here. Must be the
+ * same queue from which the {@linkplain TimerListenerBean timer listener bean} receives
+ * messages.</td>
+ * </tr>
+ * </table>
+ *
+ * @author Alejandro Guizar
+ */
+@Stateless
+@Resources(value = {
+ @Resource(name = "jdbc/JbpmDataSource", type = DataSource.class, shareable = true),
+ @Resource(name = "jms/JbpmConnectionFactory", type = ConnectionFactory.class, shareable = true),
+ @Resource(name = "jms/JobQueue", type = Queue.class),
+ @Resource(name = "jms/TimerQueue", type = Queue.class)
+})
+public class CommandServiceBean implements LocalCommandService {
+
+ private static final long serialVersionUID = 1L;
+
+ @Resource
+ private SessionContext sessionContext;
+ @Resource(name = "JbpmCfgResource")
+ private String jbpmCfgResource;
+
+ private JbpmConfiguration jbpmConfiguration;
+
+ /**
+ * Creates the {@link JbpmConfiguration} to be used by this command service. In case the
+ * environment key <code>JbpmCfgResource</code> is specified, that value is interpreted as the
+ * name of the configuration resource to load from the classpath. If that key is absent, the
+ * default configuration file will be used (jbpm.cfg.xml).
+ */
+ @PostConstruct
+ void createConfiguration() {
+ jbpmConfiguration = JbpmConfiguration.getInstance(jbpmCfgResource);
+ }
+
+ public Object execute(Command command) {
+ JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
+ try {
+ Object result = command.execute(jbpmContext);
+ // check whether command requested a rollback
+ if (jbpmContext.getServices().getTxService().isRollbackOnly()) {
+ sessionContext.setRollbackOnly();
+ }
+ return result;
+ }
+ catch (RuntimeException e) {
+ throw e;
+ }
+ catch (Exception e) {
+ throw new JbpmException("failed to execute " + command, e);
+ }
+ finally {
+ jbpmContext.close();
+ }
+ }
+}
Copied: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/JobListenerBean.java (from rev 6684, jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java)
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/JobListenerBean.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/JobListenerBean.java 2010-09-28 09:17:11 UTC (rev 6687)
@@ -0,0 +1,43 @@
+package org.jbpm.ejb;
+
+import javax.jms.JMSException;
+import javax.jms.Message;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.jbpm.command.Command;
+import org.jbpm.jms.ExecuteJobCommand;
+
+/**
+ * Message-driven bean that listens for {@link Message messages} containing a reference to a
+ * pending {@linkplain org.jbpm.job.Job job} for asynchronous continuations.
+ * <p>
+ * The message must have a <code>long</code> property called <code>jobId</code> which identifies
+ * a job in the database. The message body, if any, is ignored.
+ * </p>
+ * <h3>Environment</h3>
+ * <p>
+ * This bean inherits its environment entries and resources available for customization from
+ * {@link CommandListenerBean}.
+ * </p>
+ *
+ * @author Alejandro Guizar
+ */
+public class JobListenerBean extends CommandListenerBean {
+
+ private static final long serialVersionUID = 1L;
+ private static final Log log = LogFactory.getLog(JobListenerBean.class);
+
+ protected Command extractCommand(Message message) throws JMSException {
+ // checking for jobId property
+ if (message.propertyExists("jobId")) {
+ long jobId = message.getLongProperty("jobId");
+ return new ExecuteJobCommand(jobId);
+ }
+ else {
+ log.warn("property jobId not found");
+ }
+ return null;
+ }
+}
Deleted: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java 2010-09-27 21:40:46 UTC (rev 6686)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java 2010-09-28 09:17:11 UTC (rev 6687)
@@ -1,214 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jbpm.ejb.impl;
-
-import java.io.Serializable;
-
-import javax.annotation.PostConstruct;
-import javax.annotation.PreDestroy;
-import javax.annotation.Resource;
-import javax.ejb.ActivationConfigProperty;
-import javax.ejb.EJB;
-import javax.ejb.MessageDriven;
-import javax.ejb.MessageDrivenContext;
-import javax.jms.Connection;
-import javax.jms.ConnectionFactory;
-import javax.jms.Destination;
-import javax.jms.JMSException;
-import javax.jms.Message;
-import javax.jms.MessageListener;
-import javax.jms.ObjectMessage;
-import javax.jms.Session;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
-import org.jbpm.JbpmException;
-import org.jbpm.command.Command;
-import org.jbpm.ejb.LocalCommandService;
-import org.jbpm.persistence.db.DbPersistenceService;
-import org.jbpm.persistence.db.StaleObjectLogConfigurer;
-
-/**
- * This message-driven bean listens for {@link ObjectMessage object messages} containing a
- * command instance. The received commands are executed by the {@link CommandServiceBean command
- * service} bean, using the local interface.
- *
- * The body of the message must be a Java object that implements the {@link Command} interface.
- * The message properties, if any, are ignored.
- *
- * <h3>Environment</h3>
- *
- * <p>
- * The environment entries and resources available for customization are summarized in the table
- * below.
- * </p>
- *
- * <table border="1">
- * <tr>
- * <th>Name</th>
- * <th>Type</th>
- * <th>Description</th>
- * </tr>
- * <tr>
- * <td><code>ejb/LocalCommandService</code></td>
- * <td>EJB Reference</td>
- * <td>Link to the local {@linkplain CommandServiceBean session bean} that executes commands on
- * a separate jBPM context.</td>
- * </tr>
- * <tr>
- * <td><code>jms/JbpmConnectionFactory</code></td>
- * <td>Resource Manager Reference</td>
- * <td>Logical name of the factory that provides JMS connections for producing result messages.
- * Required for command messages that indicate a reply destination.</td>
- * </tr>
- * </table>
- *
- * @author Alejandro Guizar
- */
-@MessageDriven(activationConfig = {
- @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue")
-})
-public class CommandListenerBean implements MessageListener {
-
- private static final long serialVersionUID = 1L;
-
- @Resource
- private MessageDrivenContext messageDrivenContext;
- @EJB(name = "ejb/LocalCommandService")
- private LocalCommandService commandService;
- @Resource(name = "jms/JbpmConnectionFactory")
- private ConnectionFactory jmsConnectionFactory;
-
- private Connection jmsConnection;
-
- private static final Log log = LogFactory.getLog(CommandListenerBean.class);
-
- @PostConstruct
- void createConnection() {
- try {
- jmsConnection = jmsConnectionFactory.createConnection();
- }
- catch (JMSException e) {
- throw new JbpmException("failed to create jms connection", e);
- }
- }
-
- @PreDestroy
- void closeConnection() {
- if (jmsConnection != null) {
- try {
- jmsConnection.close();
- }
- catch (JMSException e) {
- log.debug("failed to close jms connection", e);
- }
- }
- }
-
- public void onMessage(Message message) {
- try {
- // extract command from message
- Command command = extractCommand(message);
- if (command == null) return;
-
- // execute command via local command executor bean
- Object result;
- try {
- result = commandService.execute(command);
- }
- catch (RuntimeException e) {
- // MDBs are not supposed to throw exceptions
- messageDrivenContext.setRollbackOnly();
- // if this is a locking exception, keep it quiet
- if (DbPersistenceService.isLockingException(e)) {
- StaleObjectLogConfigurer.getStaleObjectExceptionsLog().error("failed to execute "
- + command, e);
- }
- else {
- log.error("failed to execute " + command, e);
- }
- // the exception becomes the result
- result = e;
- }
- // send a response back if a "reply to" destination is set
- Destination replyTo = message.getJMSReplyTo();
- if (replyTo != null && (result instanceof Serializable || result == null)) {
- sendResult((Serializable) result, replyTo, message.getJMSMessageID());
- }
- }
- catch (JMSException e) {
- messageDrivenContext.setRollbackOnly();
- log.error("failed to process message " + message, e);
- }
- }
-
- /**
- * Retrieves a {@link Command} instance from the given message, which is assumed to be an
- * {@link ObjectMessage}.
- * <p>
- * Subclasses may override this method to materialize the command in some other way.
- * </p>
- */
- protected Command extractCommand(Message message) throws JMSException {
- if (message instanceof ObjectMessage) {
- ObjectMessage objectMessage = (ObjectMessage) message;
- Serializable object = objectMessage.getObject();
- if (object instanceof Command) {
- return (Command) object;
- }
- else {
- log.warn("not a command: " + object);
- }
- }
- else {
- log.warn("not an object message: " + message);
- }
- return null;
- }
-
- private void sendResult(Serializable result, Destination destination, String correlationId)
- throws JMSException {
- if (log.isDebugEnabled()) log.debug("sending " + result + " to " + destination);
- Session jmsSession = createSession();
- try {
- Message resultMessage = jmsSession.createObjectMessage(result);
- resultMessage.setJMSCorrelationID(correlationId);
- jmsSession.createProducer(destination).send(resultMessage);
- }
- finally {
- jmsSession.close();
- }
- }
-
- private Session createSession() throws JMSException {
- if (jmsConnection == null) {
- jmsConnection = jmsConnectionFactory.createConnection();
- }
- /*
- * if the connection supports xa, the session will be transacted, else the session will auto
- * acknowledge; in either case no explicit transaction control must be performed - see ejb
- * 2.1 - 17.3.5
- */
- return jmsConnection.createSession(false, Session.AUTO_ACKNOWLEDGE);
- }
-}
Deleted: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java 2010-09-27 21:40:46 UTC (rev 6686)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java 2010-09-28 09:17:11 UTC (rev 6687)
@@ -1,140 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jbpm.ejb.impl;
-
-import javax.annotation.PostConstruct;
-import javax.annotation.Resource;
-import javax.annotation.Resources;
-import javax.ejb.SessionContext;
-import javax.ejb.Stateless;
-import javax.jms.ConnectionFactory;
-import javax.jms.Queue;
-import javax.sql.DataSource;
-
-import org.jbpm.JbpmConfiguration;
-import org.jbpm.JbpmContext;
-import org.jbpm.JbpmException;
-import org.jbpm.command.Command;
-import org.jbpm.ejb.LocalCommandService;
-import org.jbpm.jms.JmsConnectorServiceFactory;
-import org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory;
-
-/**
- * Stateless session bean that executes {@linkplain Command commands} by calling their
- * {@link Command#execute(JbpmContext) execute} method on a separate {@link JbpmContext jBPM
- * context}.
- *
- * <h3>Environment</h3>
- *
- * <p>
- * The environment entries and resources available for customization are summarized in the table
- * below.
- * </p>
- *
- * <table border="1">
- * <tr>
- * <th>Name</th>
- * <th>Type</th>
- * <th>Description</th>
- * </tr>
- * <tr>
- * <td><code>JbpmCfgResource</code></td>
- * <td>Environment Entry</td>
- * <td>The classpath resource from which to read the {@linkplain JbpmConfiguration jBPM
- * configuration}. Optional, defaults to <code>
- * jbpm.cfg.xml</code>.</td>
- * </tr>
- * <tr>
- * <td><code>jdbc/JbpmDataSource</code></td>
- * <td>Resource Manager Reference</td>
- * <td>Logical name of the data source that provides JDBC connections to the
- * {@linkplain JtaDbPersistenceServiceFactory persistence service}. Must match the
- * <code>hibernate.connection.datasource</code> property in the Hibernate configuration file.</td>
- * </tr>
- * <tr>
- * <td><code>jms/JbpmConnectionFactory</code></td>
- * <td>Resource Manager Reference</td>
- * <td>Logical name of the factory that provides JMS connections to the
- * {@linkplain JmsConnectorServiceFactory JMS connector service}. Required for processes that
- * contain asynchronous continuations.</td>
- * </tr>
- * <tr>
- * <td><code>jms/JobQueue</code></td>
- * <td>Message Destination Reference</td>
- * <td>The message service sends job messages to the queue referenced here. To ensure this is
- * the same queue from which the {@linkplain JobListenerBean job listener bean} receives
- * messages, the <code>message-destination-link</code> points to a common logical destination,
- * <code>JobQueue</code>.</td>
- * </tr>
- * </table>
- *
- * @author Alejandro Guizar
- */
-@Stateless
-@Resources(value = {
- @Resource(name = "jdbc/JbpmDataSource", type = DataSource.class),
- @Resource(name = "jms/JbpmConnectionFactory", type = ConnectionFactory.class),
- @Resource(name = "jms/JobQueue", type = Queue.class)
-})
-public class CommandServiceBean implements LocalCommandService {
-
- private static final long serialVersionUID = 1L;
-
- @Resource
- private SessionContext sessionContext;
- @Resource(name = "JbpmCfgResource")
- private String jbpmCfgResource;
-
- private JbpmConfiguration jbpmConfiguration;
-
- /**
- * Creates the {@link JbpmConfiguration} to be used by this command service. In case the
- * environment key <code>JbpmCfgResource</code> is specified, that value is interpreted as the
- * name of the configuration resource to load from the classpath. If that key is absent, the
- * default configuration file will be used (jbpm.cfg.xml).
- */
- @PostConstruct
- void createConfiguration() {
- jbpmConfiguration = JbpmConfiguration.getInstance(jbpmCfgResource);
- }
-
- public Object execute(Command command) {
- JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
- Object result = command.execute(jbpmContext);
- // check whether command requested a rollback
- if (jbpmContext.getServices().getTxService().isRollbackOnly()) {
- sessionContext.setRollbackOnly();
- }
- return result;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Exception e) {
- throw new JbpmException("failed to execute " + command, e);
- }
- finally {
- jbpmContext.close();
- }
- }
-}
Deleted: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java 2010-09-27 21:40:46 UTC (rev 6686)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java 2010-09-28 09:17:11 UTC (rev 6687)
@@ -1,49 +0,0 @@
-package org.jbpm.ejb.impl;
-
-import javax.ejb.ActivationConfigProperty;
-import javax.ejb.MessageDriven;
-import javax.jms.JMSException;
-import javax.jms.Message;
-import javax.jms.MessageListener;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
-import org.jbpm.command.Command;
-import org.jbpm.jms.ExecuteJobCommand;
-
-/**
- * Message-driven bean that listens for {@link Message messages} containing a reference to a
- * pending {@linkplain org.jbpm.job.Job job} for asynchronous continuations.
- * <p>
- * The message must have a <code>long</code> property called <code>jobId</code> which identifies
- * a job in the database. The message body, if any, is ignored.
- * </p>
- * <h3>Environment</h3>
- * <p>
- * This bean inherits its environment entries and resources available for customization from
- * {@link CommandListenerBean}.
- * </p>
- *
- * @author Alejandro Guizar
- */
-@MessageDriven(messageListenerInterface = MessageListener.class, activationConfig = {
- @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue")
-})
-public class JobListenerBean extends CommandListenerBean {
-
- private static final long serialVersionUID = 1L;
- private static final Log log = LogFactory.getLog(JobListenerBean.class);
-
- protected Command extractCommand(Message message) throws JMSException {
- // checking for jobId property
- if (message.propertyExists("jobId")) {
- long jobId = message.getLongProperty("jobId");
- return new ExecuteJobCommand(jobId);
- }
- else {
- log.warn("property jobId not found");
- }
- return null;
- }
-}
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/ejb-jar.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/ejb-jar.xml 2010-09-27 21:40:46 UTC (rev 6686)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/ejb-jar.xml 2010-09-28 09:17:11 UTC (rev 6687)
@@ -28,19 +28,28 @@
<message-destination-ref>
<description>
- The message service sends job messages to the queue referenced here. To ensure this is the
- same queue from which the JobListenerBean receives messages, the message-destination-link
- element points to a common logical destination, JobQueue.
+ The message service sends job messages to the queue referenced here.
+ Must be the same queue from which the JobListenerBean receives messages.
</description>
<message-destination-ref-name>jms/JobQueue</message-destination-ref-name>
<message-destination-usage>Produces</message-destination-usage>
<mapped-name>queue/JbpmJobQueue</mapped-name>
</message-destination-ref>
+
+ <message-destination-ref>
+ <description>
+ The scheduler service sends timer messages to the queue referenced here.
+ Must be the same queue from which the TimerListenerBean receives messages.
+ </description>
+ <message-destination-ref-name>jms/TimerQueue</message-destination-ref-name>
+ <message-destination-usage>Produces</message-destination-usage>
+ <mapped-name>queue/JbpmTimerQueue</mapped-name>
+ </message-destination-ref>
</session>
<message-driven>
<description>
- Listens for serialized commands and routes them to the command service session bean.
+ Listens for serialized commands and runs them through the command service.
</description>
<display-name>jBPM Command Listener</display-name>
<ejb-name>CommandListenerBean</ejb-name>
@@ -48,7 +57,7 @@
<resource-ref>
<description>
- Logical name of the factory that provides JMS connections for producing result messages.
+ Logical name of the factory that provides JMS connections for sending result messages.
Required for command messages that indicate a reply destination.
</description>
<res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
@@ -58,21 +67,44 @@
<message-driven>
<description>
- Listens for job references and delegates execution of the referenced Job to the command
- service session bean.
+ Listens for async job references and runs the jobs through the command service.
</description>
- <display-name>jBPM Job Listener</display-name>
- <ejb-name>JobListenerBean</ejb-name>
+ <display-name>jBPM Async Job Listener</display-name>
+ <ejb-name>AsyncJobListenerBean</ejb-name>
<mapped-name>queue/JbpmJobQueue</mapped-name>
+ <ejb-class>org.jbpm.ejb.JobListenerBean</ejb-class>
+ <messaging-type>javax.jms.MessageListener</messaging-type>
+ <message-destination-type>javax.jms.Queue</message-destination-type>
<resource-ref>
<description>
- Logical name of the factory that provides JMS connections for producing result messages.
+ Logical name of the factory that provides JMS connections for sending result messages.
Required for command messages that indicate a reply destination.
</description>
<res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
<mapped-name>java:JmsXA</mapped-name>
</resource-ref>
</message-driven>
+
+ <message-driven>
+ <description>
+ Listens for timer references and runs the timers through the command service.
+ </description>
+ <display-name>jBPM Timer Listener</display-name>
+ <ejb-name>TimerListenerBean</ejb-name>
+ <mapped-name>queue/JbpmTimerQueue</mapped-name>
+ <ejb-class>org.jbpm.ejb.JobListenerBean</ejb-class>
+ <messaging-type>javax.jms.MessageListener</messaging-type>
+ <message-destination-type>javax.jms.Queue</message-destination-type>
+
+ <resource-ref>
+ <description>
+ Logical name of the factory that provides JMS connections for sending result messages.
+ Required for command messages that indicate a reply destination.
+ </description>
+ <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
+ <mapped-name>java:JmsXA</mapped-name>
+ </resource-ref>
+ </message-driven>
</enterprise-beans>
</ejb-jar>
13 years, 7 months
JBoss JBPM SVN: r6686 - jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2010-09-27 17:40:46 -0400 (Mon, 27 Sep 2010)
New Revision: 6686
Modified:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
Log:
JBPM-2945 if an exception is thrown during command execution, have CommandListenerBean send the exception back as the result
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java 2010-09-27 15:32:02 UTC (rev 6685)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java 2010-09-27 21:40:46 UTC (rev 6686)
@@ -105,10 +105,6 @@
@PostConstruct
void createConnection() {
- Object cs = messageDrivenContext.lookup("ejb/LocalCommandService");
- if (!(cs instanceof LocalCommandService)) {
- throw new AssertionError(cs);
- }
try {
jmsConnection = jmsConnectionFactory.createConnection();
}
@@ -134,14 +130,11 @@
// extract command from message
Command command = extractCommand(message);
if (command == null) return;
+
+ // execute command via local command executor bean
+ Object result;
try {
- // execute command via local command executor bean
- Object result = commandService.execute(command);
- // send a response back if a "reply to" destination is set
- Destination replyTo = message.getJMSReplyTo();
- if (replyTo != null && (result instanceof Serializable || result == null)) {
- sendResult((Serializable) result, replyTo, message.getJMSMessageID());
- }
+ result = commandService.execute(command);
}
catch (RuntimeException e) {
// MDBs are not supposed to throw exceptions
@@ -149,13 +142,19 @@
// if this is a locking exception, keep it quiet
if (DbPersistenceService.isLockingException(e)) {
StaleObjectLogConfigurer.getStaleObjectExceptionsLog().error("failed to execute "
- + command,
- e);
+ + command, e);
}
else {
log.error("failed to execute " + command, e);
}
+ // the exception becomes the result
+ result = e;
}
+ // send a response back if a "reply to" destination is set
+ Destination replyTo = message.getJMSReplyTo();
+ if (replyTo != null && (result instanceof Serializable || result == null)) {
+ sendResult((Serializable) result, replyTo, message.getJMSMessageID());
+ }
}
catch (JMSException e) {
messageDrivenContext.setRollbackOnly();
13 years, 7 months
JBoss JBPM SVN: r6685 - in projects/migration_tool/trunk: src and 13 other directories.
by do-not-reply@jboss.org
Author: marcolof
Date: 2010-09-27 11:32:02 -0400 (Mon, 27 Sep 2010)
New Revision: 6685
Added:
projects/migration_tool/trunk/pom.xml
projects/migration_tool/trunk/src/main/resources/Schemas/
projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/
projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/BPMN20.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramDefinition.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramInterchange.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/Semantic.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/
projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.0.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.1.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.2.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.3.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.0.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.2.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.3.xsd
projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.4.xsd
projects/migration_tool/trunk/src/main/xslt/
projects/migration_tool/trunk/src/main/xslt/migrate.xslt
projects/migration_tool/trunk/src/test/
projects/migration_tool/trunk/src/test/java/
projects/migration_tool/trunk/src/test/java/test/
projects/migration_tool/trunk/src/test/java/test/XSLTTest.java
projects/migration_tool/trunk/src/test/resources/
projects/migration_tool/trunk/src/test/resources/bpmn/
projects/migration_tool/trunk/src/test/resources/bpmn/Test.bpmn.xml
projects/migration_tool/trunk/src/test/resources/bpmn/Test.bpmn_diagram
projects/migration_tool/trunk/src/test/resources/jbjPDL4ToBPMN2.xsl
projects/migration_tool/trunk/src/test/resources/jpdl/
projects/migration_tool/trunk/src/test/resources/jpdl/test/
projects/migration_tool/trunk/src/test/resources/jpdl/test/gpd.xml
projects/migration_tool/trunk/src/test/resources/jpdl/test/processdefinition.xml
projects/migration_tool/trunk/src/test/resources/jpdl/test/processimage.jpg
Modified:
projects/migration_tool/trunk/
Log:
Initial update of project.
Property changes on: projects/migration_tool/trunk
___________________________________________________________________
Name: svn:ignore
- *.settings
*.classpath
*.project
+ *.settings
*.classpath
*.project
target
Added: projects/migration_tool/trunk/pom.xml
===================================================================
--- projects/migration_tool/trunk/pom.xml (rev 0)
+++ projects/migration_tool/trunk/pom.xml 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+ <!-- Model Information -->
+ <modelVersion>4.0.0</modelVersion>
+ <prerequisites>
+ <maven>2.2.0</maven>
+ </prerequisites>
+
+ <!-- The Basics -->
+ <groupId>jboss</groupId>
+ <artifactId>jpdl2bpmn2</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ <packaging>jar</packaging>
+
+ <name>jPDL to BPMN2 translator</name>
+ <description>jpdl to bpmn2 translation project</description>
+
+ <developers>
+ <developer>
+ <id>erics</id>
+ <name>Eric Schabell</name>
+ <email>erics(a)redhat.com</email>
+ <roles>
+ <role>architect</role>
+ </roles>
+ <timezone>+2</timezone>
+ </developer>
+ </developers>
+
+ <dependencies>
+
+ <!-- XSLT -->
+ <dependency>
+ <groupId>xalan</groupId>
+ <artifactId>xalan</artifactId>
+ <version>2.7.1</version>
+ </dependency>
+ <dependency>
+ <groupId>xerces</groupId>
+ <artifactId>xercesImpl</artifactId>
+ <version>2.9.1</version>
+ </dependency>
+ <dependency>
+ <groupId>xml-apis</groupId>
+ <artifactId>xml-apis</artifactId>
+ <version>1.0.b2</version>
+ </dependency>
+
+ <!-- Test -->
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>4.8.1</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <testResources>
+ <testResource>
+ <directory>src/main/use_cases</directory>
+ </testResource>
+ </testResources>
+ <resources>
+ <resource>
+ <directory>src/main/xslt</directory>
+ </resource>
+ <resource>
+ <directory>src/main/resources</directory>
+ </resource>
+ </resources>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>2.3.1</version>
+ <configuration>
+ <source>1.6</source>
+ <target>1.6</target>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <!--
+ <scm>...</scm>
+ -->
+
+ <!-- <properties> </properties> -->
+
+ <!-- Environment Settings -->
+ <!-- <repositories> ... </repositories> <pluginRepositories> ... </pluginRepositories> -->
+ <!-- <profiles> ... </profiles> -->
+
+</project>
\ No newline at end of file
Property changes on: projects/migration_tool/trunk/pom.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/BPMN20.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/BPMN20.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/BPMN20.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsd:schema elementFormDefault="qualified" attributeFormDefault="unqualified"
+ xmlns="http://schema.omg.org/spec/BPMN/2.0"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:di="http://www.omg.com/di/1.0.0"
+ targetNamespace="http://schema.omg.org/spec/BPMN/2.0">
+
+ <xsd:import namespace="http://www.omg.com/di/1.0.0" schemaLocation="DiagramInterchange.xsd"/>
+ <xsd:include schemaLocation="Semantic.xsd"/>
+
+ <xsd:element name="definitions" type="tDefinitions"/>
+ <xsd:complexType name="tDefinitions">
+ <xsd:sequence>
+ <xsd:element ref="import" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="extension" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="rootElement" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="di:diagram" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="relationship" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="id" type="xsd:ID" use="optional"/>
+ <xsd:attribute name="targetNamespace" type="xsd:anyURI" use="required"/>
+ <xsd:attribute name="expressionLanguage" type="xsd:anyURI" use="optional" default="http://www.w3.org/1999/XPath"/>
+ <xsd:attribute name="typeLanguage" type="xsd:anyURI" use="optional" default="http://www.w3.org/2001/XMLSchema"/>
+ <xsd:anyAttribute namespace="##other" processContents="lax"/>
+ </xsd:complexType>
+
+ <xsd:element name="import" type="tImport"/>
+ <xsd:complexType name="tImport">
+ <xsd:attribute name="namespace" type="xsd:anyURI" use="required"/>
+ <xsd:attribute name="location" type="xsd:string" use="required"/>
+ <xsd:attribute name="importType" type="xsd:anyURI" use="required"/>
+ </xsd:complexType>
+
+</xsd:schema>
\ No newline at end of file
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/BPMN20.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramDefinition.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramDefinition.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramDefinition.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,95 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsd:schema targetNamespace="http://www.omg.com/dd/1.0.0" xmlns:dd="http://www.omg.com/dd/1.0.0" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <xsd:element name="namedElement" type="dd:NamedElement"/>
+ <xsd:element name="package" type="dd:Package"/>
+ <xsd:element name="viewDefinition" type="dd:ViewDefinition" abstract="true"/>
+ <xsd:element name="nodeDefinition" type="dd:NodeDefinition" substitutionGroup="dd:viewDefinition"/>
+ <xsd:element name="connectorDefinition" type="dd:ConnectorDefinition" substitutionGroup="dd:viewDefinition"/>
+ <xsd:element name="diagramDefinition" type="dd:DiagramDefinition" substitutionGroup="dd:viewDefinition"/>
+ <xsd:element name="childDefinition" type="dd:ChildDefinition"/>
+ <xsd:element name="styleDefinition" type="dd:StyleDefinition"/>
+ <xsd:element name="constraint" type="dd:Constraint"/>
+
+ <xsd:complexType abstract="true" name="NamedElement">
+ <xsd:attribute name="name" type="xsd:NCName" use="required"/>
+ </xsd:complexType>
+
+ <xsd:complexType name="Package">
+ <xsd:complexContent>
+ <xsd:extension base="dd:NamedElement">
+ <xsd:sequence>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="dd:viewDefinition"/>
+ </xsd:sequence>
+ <xsd:attribute name="nsURI" type="xsd:anyURI" use="required"/>
+ <xsd:attribute name="nsPrefix" type="xsd:NCName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType abstract="true" name="ViewDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="dd:NamedElement">
+ <xsd:sequence>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="dd:constraint"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="dd:styleDefinition"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="dd:childDefinition"/>
+ </xsd:sequence>
+ <xsd:attribute name="id" type="xsd:NCName" use="required"/>
+ <xsd:attribute name="abstract" type="xsd:boolean"/>
+ <xsd:attribute name="superDefinition" type="xsd:QName"/>
+ <xsd:attribute name="contextType" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="NodeDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="dd:ViewDefinition"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="ConnectorDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="dd:ViewDefinition">
+ <xsd:attribute name="sourceDefinition" type="xsd:QName" use="required"/>
+ <xsd:attribute name="targetDefinition" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="DiagramDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="dd:ViewDefinition"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="ChildDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="dd:NamedElement">
+ <xsd:attribute name="lowerBound" type="xsd:int" default="0" />
+ <xsd:attribute name="upperBound" type="xsd:int" default="-1"/>
+ <xsd:attribute name="typeDefinition" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="StyleDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="dd:NamedElement">
+ <xsd:attribute name="default" type="xsd:string"/>
+ <xsd:attribute name="inherited" type="xsd:boolean" default="false"/>
+ <xsd:attribute name="type" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="Constraint">
+ <xsd:complexContent>
+ <xsd:extension base="dd:NamedElement">
+ <xsd:attribute name="condition" type="xsd:string" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+</xsd:schema>
\ No newline at end of file
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramDefinition.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramInterchange.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramInterchange.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramInterchange.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,77 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsd:schema targetNamespace="http://www.omg.com/di/1.0.0" xmlns:dd="http://www.omg.com/dd/1.0.0" xmlns:di="http://www.omg.com/di/1.0.0" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
+
+ <xsd:import namespace="http://www.omg.com/dd/1.0.0" schemaLocation="DiagramDefinition.xsd"/>
+
+ <xsd:element name="view" type="di:View"/>
+ <xsd:element name="diagram" type="di:Diagram" substitutionGroup="di:view"/>
+ <xsd:element name="node" type="di:Node" substitutionGroup="di:view"/>
+ <xsd:element name="connector" type="di:Connector" substitutionGroup="di:view"/>
+ <xsd:element name="style" type="di:Style"/>
+ <xsd:element name="bendpoint" type="di:Bendpoint"/>
+
+ <xsd:complexType abstract="true" name="View">
+ <xsd:sequence>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="di:style"/>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" name="child" type="di:Node" form="qualified"/>
+ </xsd:sequence>
+ <xsd:attribute name="id" type="xsd:NCName" use="required"/>
+ <xsd:attribute name="context" type="xsd:anyURI"/>
+ <xsd:attribute name="definition" use="required">
+ <xsd:simpleType>
+ <xsd:list itemType="xsd:QName"/>
+ </xsd:simpleType>
+ </xsd:attribute>
+ <xsd:attribute name="targetConnector">
+ <xsd:simpleType>
+ <xsd:list itemType="xsd:anyURI"/>
+ </xsd:simpleType>
+ </xsd:attribute>
+ <xsd:attribute name="sourceConnector">
+ <xsd:simpleType>
+ <xsd:list itemType="xsd:anyURI"/>
+ </xsd:simpleType>
+ </xsd:attribute>
+ </xsd:complexType>
+
+ <xsd:complexType name="Diagram">
+ <xsd:complexContent>
+ <xsd:extension base="di:View">
+ <xsd:sequence>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="di:connector"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="Node">
+ <xsd:complexContent>
+ <xsd:extension base="di:View"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="Connector">
+ <xsd:complexContent>
+ <xsd:extension base="di:View">
+ <xsd:sequence>
+ <xsd:element maxOccurs="unbounded" minOccurs="0" ref="di:bendpoint"/>
+ </xsd:sequence>
+ <xsd:attribute name="source" type="xsd:anyURI" use="required"/>
+ <xsd:attribute name="target" type="xsd:anyURI" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:complexType name="Style">
+ <xsd:attribute name="name" type="xsd:NCName" use="required"/>
+ <xsd:attribute name="value" type="xsd:string" use="required"/>
+ </xsd:complexType>
+
+ <xsd:complexType name="Bendpoint">
+ <xsd:attribute name="sourceX" type="xsd:int" use="required"/>
+ <xsd:attribute name="sourceY" type="xsd:int" use="required"/>
+ <xsd:attribute name="targetX" type="xsd:int" use="required"/>
+ <xsd:attribute name="targetY" type="xsd:int" use="required"/>
+ </xsd:complexType>
+
+</xsd:schema>
\ No newline at end of file
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/DiagramInterchange.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/Semantic.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/Semantic.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/Semantic.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,1540 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsd:schema elementFormDefault="qualified" attributeFormDefault="unqualified"
+ xmlns="http://schema.omg.org/spec/BPMN/2.0"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="http://schema.omg.org/spec/BPMN/2.0">
+
+ <xsd:element name="activity" type="tActivity"/>
+ <xsd:complexType name="tActivity" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tFlowNode">
+ <xsd:sequence>
+ <xsd:element ref="ioSpecification" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="property" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="dataInputAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="dataOutputAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="activityResource" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="loopCharacteristics" minOccurs="0"/>
+ </xsd:sequence>
+ <xsd:attribute name="isForCompensation" type="xsd:boolean" default="false"/>
+ <xsd:attribute name="startQuantity" type="xsd:integer" default="1"/>
+ <xsd:attribute name="completionQuantity" type="xsd:integer" default="1"/>
+ <xsd:attribute name="default" type="xsd:IDREF" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="activityResource" type="tActivityResource"/>
+ <xsd:complexType name="tActivityResource">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="resourceAssignmentExpression" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="resourceParameterBinding" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="resourceRef" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="adHocSubProcess" type="tAdHocSubProcess" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tAdHocSubProcess">
+ <xsd:complexContent>
+ <xsd:extension base="tSubProcess">
+ <xsd:sequence>
+ <xsd:element name="completionCondition" type="tExpression" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="cancelRemainingInstances" type="xsd:boolean" default="true"/>
+ <xsd:attribute name="ordering" type="tAdHocOrdering"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tAdHocOrdering">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="parallel"/>
+ <xsd:enumeration value="sequential"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="artifact" type="tArtifact"/>
+ <xsd:complexType name="tArtifact" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="assignment" type="tAssignment" />
+ <xsd:complexType name="tAssignment">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="from" type="tBaseElementWithMixedContent" minOccurs="1" maxOccurs="1"/>
+ <xsd:element name="to" type="tBaseElementWithMixedContent" minOccurs="1" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="language" type="xsd:anyURI"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="association" type="tAssociation" substitutionGroup="artifact"/>
+ <xsd:complexType name="tAssociation">
+ <xsd:complexContent>
+ <xsd:extension base="tArtifact">
+ <xsd:attribute name="sourceRef" type="xsd:QName" use="required"/>
+ <xsd:attribute name="targetRef" type="xsd:QName" use="required"/>
+ <xsd:attribute name="associationDirection" type="tAssociationDirection" default="none"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tAssociationDirection">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="none"/>
+ <xsd:enumeration value="one"/>
+ <xsd:enumeration value="both"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="auditing" type="tAuditing"/>
+ <xsd:complexType name="tAuditing">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="baseElement" type="tBaseElement"/>
+ <xsd:complexType name="tBaseElement" abstract="true">
+ <xsd:sequence>
+ <xsd:element ref="documentation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="id" type="xsd:ID" use="optional"/>
+ <xsd:anyAttribute namespace="##other" processContents="lax"/>
+ </xsd:complexType>
+
+ <xsd:element name="baseElementWithMixedContent" type="tBaseElementWithMixedContent"/>
+ <xsd:complexType name="tBaseElementWithMixedContent" abstract="true" mixed="true">
+ <xsd:sequence>
+ <xsd:element ref="documentation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="category" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:any namespace="##other" processContents="lax" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="id" type="xsd:ID" use="optional"/>
+ <xsd:anyAttribute namespace="##other" processContents="lax"/>
+ </xsd:complexType>
+
+ <xsd:element name="boundaryEvent" type="tBoundaryEvent" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tBoundaryEvent">
+ <xsd:complexContent>
+ <xsd:extension base="tCatchEvent">
+ <xsd:attribute name="cancelActivity" type="xsd:boolean" default="true"/>
+ <xsd:attribute name="attachedToRef" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="businessRuleTask" type="tBusinessRuleTask" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tBusinessRuleTask">
+ <xsd:complexContent>
+ <xsd:extension base="tTask"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="callableElement" type="tCallableElement"/>
+ <xsd:complexType name="tCallableElement">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:sequence>
+ <xsd:element name="supportedInterfaceRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="ioSpecification" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="ioBinding" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="callActivity" type="tCallActivity" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tCallActivity">
+ <xsd:complexContent>
+ <xsd:extension base="tActivity">
+ <xsd:attribute name="calledElement" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="callChoreographyActivity" type="tCallChoreographyActivity" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tCallChoreographyActivity">
+ <xsd:complexContent>
+ <xsd:extension base="tChoreographyActivity">
+ <xsd:sequence>
+ <xsd:element ref="participantAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="calledElement" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="callConversation" type="tCallConversation" substitutionGroup="conversationNode"/>
+ <xsd:complexType name="tCallConversation">
+ <xsd:complexContent>
+ <xsd:extension base="tConversationNode">
+ <xsd:sequence>
+ <xsd:element ref="participantAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="calledElementRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="cancelEventDefinition" type="tCancelEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tCancelEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="catchEvent" type="tCatchEvent"/>
+ <xsd:complexType name="tCatchEvent" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tEvent">
+ <xsd:sequence>
+ <xsd:element ref="dataOutput" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="dataOutputAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="outputSet" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="eventDefinition" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="eventDefinitionRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="parallelMultiple" type="xsd:boolean" default="false"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="category" type="tCategory" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tCategory">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:sequence>
+ <xsd:element ref="categoryValue" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="categoryValue" type="tCategoryValue"/>
+ <xsd:complexType name="tCategoryValue">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:attribute name="value" type="xsd:string" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="choreography" type="tChoreography" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tChoreography">
+ <xsd:complexContent>
+ <xsd:extension base="tCallableElement">
+ <xsd:sequence>
+ <xsd:element ref="flowElement" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="artifact" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="messageFlow" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="participant" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="conversation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="conversationAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="messageFlowAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="participantAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="isClosed" type="xsd:boolean" default="false"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="choreographyActivity" type="tChoreographyActivity"/>
+ <xsd:complexType name="tChoreographyActivity" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tFlowNode">
+ <xsd:sequence>
+ <xsd:element name="participantRef" type="xsd:QName" minOccurs="2" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="initiatingParticipantRef" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="choreographySubProcess" type="tChoreographySubProcess" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tChoreographySubProcess">
+ <xsd:complexContent>
+ <xsd:extension base="tChoreographyActivity">
+ <xsd:sequence>
+ <xsd:element ref="flowElement" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="artifact" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="choreographyTask" type="tChoreographyTask" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tChoreographyTask">
+ <xsd:complexContent>
+ <xsd:extension base="tChoreographyActivity">
+ <xsd:sequence>
+ <xsd:element name="messageFlowRef" type="xsd:QName" minOccurs="1" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="collaboration" type="tCollaboration" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tCollaboration">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:sequence>
+ <xsd:element ref="participant" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="messageFlow" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="artifact" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="conversation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="conversationAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="participantAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="messageFlowAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string"/>
+ <xsd:attribute name="isClosed" type="xsd:boolean" default="false"/>
+ <xsd:attribute name="choreographyRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="communication" type="tCommunication" substitutionGroup="conversationNode"/>
+ <xsd:complexType name="tCommunication">
+ <xsd:complexContent>
+ <xsd:extension base="tConversationNode">
+ <xsd:sequence>
+ <xsd:element name="messageFlowRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="correlationKeyRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="compensateEventDefinition" type="tCompensateEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tCompensateEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition">
+ <xsd:attribute name="waitForCompletion" type="xsd:boolean"/>
+ <xsd:attribute name="activityRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="complexBehaviorDefinition" type="tComplexBehaviorDefinition"/>
+ <xsd:complexType name="tComplexBehaviorDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="condition" type="tFormalExpression" minOccurs="1" maxOccurs="1"/>
+ <xsd:element name="event" type="tImplicitThrowEvent" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="complexGateway" type="tComplexGateway" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tComplexGateway">
+ <xsd:complexContent>
+ <xsd:extension base="tGateway">
+ <xsd:sequence>
+ <xsd:element name="activationCondition" type="tExpression" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="default" type="xsd:IDREF"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="conditionalEventDefinition" type="tConditionalEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tConditionalEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition">
+ <xsd:sequence>
+ <xsd:element name="condition" type="tExpression"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="conversation" type="tConversation" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tConversation">
+ <xsd:complexContent>
+ <xsd:extension base="tCallableElement">
+ <xsd:sequence>
+ <xsd:element ref="conversationNode" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="participant" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="artifact" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="messageFlow" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="messageFlowRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="correlationKey" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="conversationAssociation" type="tConversationAssociation"/>
+ <xsd:complexType name="tConversationAssociation">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="messageFlowRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="conversationRef" type="xsd:QName"/>
+ <xsd:attribute name="correlationKeyRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="conversationNode" type="tConversationNode"/>
+ <xsd:complexType name="tConversationNode" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="participantRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="correlationKey" type="tCorrelationKey"/>
+ <xsd:complexType name="tCorrelationKey">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="correlationPropertyRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="correlationProperty" type="tCorrelationProperty" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tCorrelationProperty">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:sequence>
+ <xsd:element ref="correlationPropertyRetrievalExpression" minOccurs="1" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="correlationPropertyBinding" type="tCorrelationPropertyBinding"/>
+ <xsd:complexType name="tCorrelationPropertyBinding">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="dataPath" type="tFormalExpression" minOccurs="1" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="correlationPropertyRef" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="correlationPropertyRetrievalExpression" type="tCorrelationPropertyRetrievalExpression"/>
+ <xsd:complexType name="tCorrelationPropertyRetrievalExpression">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="messagePath" type="tFormalExpression" minOccurs="1" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="messageRef" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="correlationSubscription" type="tCorrelationSubscription"/>
+ <xsd:complexType name="tCorrelationSubscription">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="correlationPropertyBinding" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="process" type="xsd:QName" use="required"/>
+ <xsd:attribute name="correlationKeyRef" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="dataAssociation" type="tDataAssociation" />
+ <xsd:complexType name="tDataAssociation" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="transformation" type="tFormalExpression" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="assignment" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="dataInput" type="tDataInput" />
+ <xsd:complexType name="tDataInput">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="dataState" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="itemSubjectRef" type="xsd:QName" />
+ <xsd:attribute name="isCollection" type="xsd:boolean" default="false"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="dataInputAssociation" type="tDataInputAssociation" />
+ <xsd:complexType name="tDataInputAssociation">
+ <xsd:complexContent>
+ <xsd:extension base="tDataAssociation">
+ <xsd:sequence>
+ <xsd:element name="sourceRef" type="xsd:QName" minOccurs="1" maxOccurs="unbounded"/>
+ <xsd:element name="targetRef" type="xsd:QName" minOccurs="1" maxOccurs="1"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="dataObject" type="tDataObject" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tDataObject">
+ <xsd:complexContent>
+ <xsd:extension base="tFlowElement">
+ <xsd:sequence>
+ <xsd:element ref="dataState" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="itemSubjectRef" type="xsd:QName"/>
+ <xsd:attribute name="isCollection" type="xsd:boolean" default="false"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="dataOutput" type="tDataOutput" />
+ <xsd:complexType name="tDataOutput">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="dataState" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="optional" />
+ <xsd:attribute name="itemSubjectRef" type="xsd:QName"/>
+ <xsd:attribute name="isCollection" type="xsd:boolean" default="false"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="dataOutputAssociation" type="tDataOutputAssociation" />
+ <xsd:complexType name="tDataOutputAssociation">
+ <xsd:complexContent>
+ <xsd:extension base="tDataAssociation">
+ <xsd:sequence>
+ <xsd:element name="sourceRef" type="xsd:QName" minOccurs="1" maxOccurs="unbounded"/>
+ <xsd:element name="targetRef" type="xsd:QName" minOccurs="1" maxOccurs="1"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="dataState" type="tDataState" />
+ <xsd:complexType name="tDataState">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:attribute name="name" type="xsd:string"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="dataStore" type="tDataStore" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tDataStore">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:sequence>
+ <xsd:element ref="dataState" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string"/>
+ <xsd:attribute name="capacity" type="xsd:integer"/>
+ <xsd:attribute name="isUnlimited" type="xsd:boolean" default="true"/>
+ <xsd:attribute name="itemSubjectRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="dataStoreReference" type="tDataStoreReference" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tDataStoreReference">
+ <xsd:complexContent>
+ <xsd:extension base="tFlowElement">
+ <xsd:sequence>
+ <xsd:element ref="dataState" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="itemSubjectRef" type="xsd:QName"/>
+ <xsd:attribute name="dataStoreRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="documentation" type="tDocumentation"/>
+ <xsd:complexType name="tDocumentation" mixed="true">
+ <xsd:sequence>
+ <xsd:any namespace="##any" processContents="lax" minOccurs="0"/>
+ </xsd:sequence>
+ <xsd:attribute name="id" type="xsd:ID" use="optional"/>
+ </xsd:complexType>
+
+ <xsd:element name="endEvent" type="tEndEvent" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tEndEvent">
+ <xsd:complexContent>
+ <xsd:extension base="tThrowEvent"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="endPoint" type="tEndPoint" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tEndPoint">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="error" type="tError" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tError">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:attribute name="structureRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="errorEventDefinition" type="tErrorEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tErrorEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition">
+ <xsd:attribute name="errorCode" type="xsd:string"/>
+ <xsd:attribute name="errorRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="escalation" type="tEscalation" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tEscalation">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:attribute name="structureRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="escalationEventDefinition" type="tEscalationEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tEscalationEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition">
+ <xsd:attribute name="escalationCode" type="xsd:string"/>
+ <xsd:attribute name="escalationRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="event" type="tEvent" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tEvent" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tFlowNode"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="eventBasedGateway" type="tEventBasedGateway" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tEventBasedGateway">
+ <xsd:complexContent>
+ <xsd:extension base="tGateway">
+ <xsd:attribute name="instantiate" type="xsd:boolean" default="false"/>
+ <xsd:attribute name="eventGatewayType" type="tEventBasedGatewayType" default="Exclusive"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tEventBasedGatewayType">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="Exclusive"/>
+ <xsd:enumeration value="Parallel"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="eventDefinition" type="tEventDefinition" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tEventDefinition" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="exclusiveGateway" type="tExclusiveGateway" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tExclusiveGateway">
+ <xsd:complexContent>
+ <xsd:extension base="tGateway">
+ <xsd:attribute name="default" type="xsd:IDREF" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="expression" type="tExpression"/>
+ <xsd:complexType name="tExpression">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElementWithMixedContent"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="extension" type="tExtension"/>
+ <xsd:complexType name="tExtension">
+ <xsd:sequence>
+ <xsd:element ref="documentation" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="definition" type="xsd:QName"/>
+ <xsd:attribute name="mustUnderstand" type="xsd:boolean" use="optional" default="false"/>
+ </xsd:complexType>
+
+ <xsd:element name="flowElement" type="tFlowElement"/>
+ <xsd:complexType name="tFlowElement" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="auditing" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="monitoring" minOccurs="0" maxOccurs="1"/>
+ <xsd:element name="categoryValueRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="flowNode" type="tFlowNode"/>
+ <xsd:complexType name="tFlowNode" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tFlowElement">
+ <xsd:sequence>
+ <xsd:element name="incoming" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="outgoing" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="formalExpression" type="tFormalExpression" substitutionGroup="expression"/>
+ <xsd:complexType name="tFormalExpression" mixed="true">
+ <xsd:complexContent>
+ <xsd:extension base="tExpression">
+ <xsd:attribute name="language" type="xsd:anyURI" use="optional"/>
+ <xsd:attribute name="evaluatesToTypeRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="gateway" type="tGateway" abstract="true"/>
+ <xsd:complexType name="tGateway">
+ <xsd:complexContent>
+ <xsd:extension base="tFlowNode">
+ <xsd:attribute name="gatewayDirection" type="tGatewayDirection" default="unspecified"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tGatewayDirection">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="unspecified"/>
+ <xsd:enumeration value="converging"/>
+ <xsd:enumeration value="diverging"/>
+ <xsd:enumeration value="mixed"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="globalBusinessRuleTask" type="tGlobalBusinessRuleTask" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tGlobalBusinessRuleTask">
+ <xsd:complexContent>
+ <xsd:extension base="tGlobalTask"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="globalChoreographyTask" type="tGlobalChoreographyTask" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tGlobalChoreographyTask">
+ <xsd:complexContent>
+ <xsd:extension base="tCallableElement">
+ <xsd:sequence>
+ <xsd:element ref="participant" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="messageFlow" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="initiatingParticipantRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="globalCommunication" type="tGlobalCommunication" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tGlobalCommunication">
+ <xsd:complexContent>
+ <xsd:extension base="tCallableElement">
+ <xsd:sequence>
+ <xsd:element ref="participant" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="messageFlow" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="correlationKey" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="globalManualTask" type="tGlobalManualTask" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tGlobalManualTask">
+ <xsd:complexContent>
+ <xsd:extension base="tGlobalTask"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="globalScriptTask" type="tGlobalScriptTask" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tGlobalScriptTask">
+ <xsd:complexContent>
+ <xsd:extension base="tGlobalTask">
+ <xsd:sequence>
+ <xsd:element ref="script" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="scriptLanguage" type="xsd:anyURI"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="globalTask" type="tGlobalTask" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tGlobalTask">
+ <xsd:complexContent>
+ <xsd:extension base="tCallableElement">
+ <xsd:sequence>
+ <xsd:element ref="performer" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="globalUserTask" type="tGlobalUserTask" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tGlobalUserTask">
+ <xsd:complexContent>
+ <xsd:extension base="tGlobalTask">
+ <xsd:sequence>
+ <xsd:element ref="rendering" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="implementation" type="tUserTaskImplementation" default="unspecified"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="group" type="tGroup" substitutionGroup="artifact"/>
+ <xsd:complexType name="tGroup">
+ <xsd:complexContent>
+ <xsd:extension base="tArtifact">
+ <xsd:attribute name="categoryRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="humanPerformer" type="tHumanPerformer" substitutionGroup="performer"/>
+ <xsd:complexType name="tHumanPerformer">
+ <xsd:complexContent>
+ <xsd:extension base="tPerformer"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="implicitThrowEvent" type="tImplicitThrowEvent" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tImplicitThrowEvent">
+ <xsd:complexContent>
+ <xsd:extension base="tThrowEvent"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="inclusiveGateway" type="tInclusiveGateway" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tInclusiveGateway">
+ <xsd:complexContent>
+ <xsd:extension base="tGateway">
+ <xsd:attribute name="default" type="xsd:IDREF" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="inputSet" type="tInputSet" />
+ <xsd:complexType name="tInputSet">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="dataInputRefs" type="xsd:IDREF" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="optionalInputRefs" type="xsd:IDREF" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="whileExecutingInputRefs" type="xsd:IDREF" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="outputSetRefs" type="xsd:IDREF" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" />
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="interface" type="tInterface" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tInterface">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:sequence>
+ <xsd:element ref="operation" minOccurs="1" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="intermediateCatchEvent" type="tIntermediateCatchEvent" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tIntermediateCatchEvent">
+ <xsd:complexContent>
+ <xsd:extension base="tCatchEvent"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="intermediateThrowEvent" type="tIntermediateThrowEvent" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tIntermediateThrowEvent">
+ <xsd:complexContent>
+ <xsd:extension base="tThrowEvent"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="ioBinding" type="tInputOutputBinding" />
+ <xsd:complexType name="tInputOutputBinding">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:attribute name="operationRef" type="xsd:QName" use="required"/>
+ <xsd:attribute name="inputDataRef" type="xsd:IDREF" use="required"/>
+ <xsd:attribute name="outputDataRef" type="xsd:IDREF" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="ioSpecification" type="tInputOutputSpecification" />
+ <xsd:complexType name="tInputOutputSpecification">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="dataInput" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="dataOutput" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="inputSet" minOccurs="1" maxOccurs="unbounded"/>
+ <xsd:element ref="outputSet" minOccurs="1" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="itemDefinition" type="tItemDefinition" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tItemDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:attribute name="structureRef" type="xsd:QName"/>
+ <xsd:attribute name="isCollection" type="xsd:boolean" default="false"/>
+ <xsd:attribute name="itemKind" type="tItemKind" default="Information"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tItemKind">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="Information"/>
+ <xsd:enumeration value="Physical"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="lane" type="tLane"/>
+ <xsd:complexType name="tLane">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="partitionElement" type="tBaseElement" minOccurs="0" maxOccurs="1"/>
+ <xsd:element name="flowElementRef" type="xsd:IDREF" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="childLaneSet" type="tLaneSet" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string"/>
+ <xsd:attribute name="partitionElementRef" type="xsd:IDREF"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="laneSet" type="tLaneSet"/>
+ <xsd:complexType name="tLaneSet">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="lane" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="linkEventDefinition" type="tLinkEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tLinkEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition">
+ <xsd:attribute name="name" type="xsd:string" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="loopCharacteristics" type="tLoopCharacteristics"/>
+ <xsd:complexType name="tLoopCharacteristics" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="manualTask" type="tManualTask" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tManualTask">
+ <xsd:complexContent>
+ <xsd:extension base="tTask"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="message" type="tMessage" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tMessage">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:attribute name="name" type="xsd:string"/>
+ <xsd:attribute name="structureRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="messageEventDefinition" type="tMessageEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tMessageEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition">
+ <xsd:sequence>
+ <xsd:element name="operationRef" type="xsd:QName" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="messageRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="messageFlow" type="tMessageFlow"/>
+ <xsd:complexType name="tMessageFlow">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:attribute name="name" type="xsd:string" use="optional"/>
+ <xsd:attribute name="sourceRef" type="xsd:QName" use="required"/>
+ <xsd:attribute name="targetRef" type="xsd:QName" use="required"/>
+ <xsd:attribute name="messageRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="messageFlowAssociation" type="tMessageFlowAssociation"/>
+ <xsd:complexType name="tMessageFlowAssociation">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:attribute name="innerMessageFlowRef" type="xsd:QName" use="required"/>
+ <xsd:attribute name="outerMessageFlowRef" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="monitoring" type="tMonitoring"/>
+ <xsd:complexType name="tMonitoring">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="multiInstanceLoopCharacteristics" type="tMultiInstanceLoopCharacteristics" substitutionGroup="loopCharacteristics"/>
+ <xsd:complexType name="tMultiInstanceLoopCharacteristics">
+ <xsd:complexContent>
+ <xsd:extension base="tLoopCharacteristics">
+ <xsd:sequence>
+ <xsd:element name="loopCardinality" type="tExpression" minOccurs="0" maxOccurs="1"/>
+ <xsd:element name="loopDataInput" type="tDataInput" minOccurs="0" maxOccurs="1"/>
+ <xsd:element name="loopDataOutput" type="tDataOutput" minOccurs="0" maxOccurs="1"/>
+ <xsd:element name="inputDataItem" type="tProperty" minOccurs="0" maxOccurs="1"/>
+ <xsd:element name="outputDataItem" type="tProperty" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="complexBehaviorDefinition" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="completionCondition" type="tExpression" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="isSequential" type="xsd:boolean" default="false"/>
+ <xsd:attribute name="behavior" type="tMultiInstanceFlowCondition" default="all"/>
+ <xsd:attribute name="oneBehaviorEventRef" type="xsd:QName" use="optional"/>
+ <xsd:attribute name="noneBehaviorEventRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tMultiInstanceFlowCondition">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="none"/>
+ <xsd:enumeration value="one"/>
+ <xsd:enumeration value="all"/>
+ <xsd:enumeration value="complex"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="operation" type="tOperation"/>
+ <xsd:complexType name="tOperation">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="inMessageRef" type="xsd:QName" minOccurs="1" maxOccurs="1"/>
+ <xsd:element name="outMessageRef" type="xsd:QName" minOccurs="0" maxOccurs="1"/>
+ <xsd:element name="errorRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="outputSet" type="tOutputSet" />
+ <xsd:complexType name="tOutputSet">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="dataOutputRefs" type="xsd:IDREF" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="optionalOutputRefs" type="xsd:IDREF" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="whileExecutingOutputRefs" type="xsd:IDREF" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="inputSetRefs" type="xsd:IDREF" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="parallelGateway" type="tParallelGateway" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tParallelGateway">
+ <xsd:complexContent>
+ <xsd:extension base="tGateway"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="participant" type="tParticipant"/>
+ <xsd:complexType name="tParticipant">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="interfaceRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="endPointRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="participantMultiplicity" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string"/>
+ <xsd:attribute name="partnerRoleRef" type="xsd:QName" use="optional"/>
+ <xsd:attribute name="partnerEntityRef" type="xsd:QName" use="optional"/>
+ <xsd:attribute name="processRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="participantAssociation" type="tParticipantAssociation"/>
+ <xsd:complexType name="tParticipantAssociation">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="innerParticipantRef" type="xsd:QName" minOccurs="1" maxOccurs="1"/>
+ <xsd:element name="outerParticipantRef" type="xsd:QName" minOccurs="1" maxOccurs="1"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="participantMultiplicity" type="tParticipantMultiplicity"/>
+ <xsd:complexType name="tParticipantMultiplicity">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:attribute name="minimum" type="xsd:int"/>
+ <xsd:attribute name="maximum" type="xsd:int"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="partnerEntity" type="tPartnerEntity" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tPartnerEntity">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:attribute name="name" type="xsd:string"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="partnerRole" type="tPartnerRole" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tPartnerRole">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:attribute name="name" type="xsd:string"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="performer" type="tPerformer" substitutionGroup="activityResource"/>
+ <xsd:complexType name="tPerformer">
+ <xsd:complexContent>
+ <xsd:extension base="tActivityResource"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="potentialOwner" type="tPotentialOwner" substitutionGroup="performer"/>
+ <xsd:complexType name="tPotentialOwner">
+ <xsd:complexContent>
+ <xsd:extension base="tHumanPerformer"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="process" type="tProcess" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tProcess">
+ <xsd:complexContent>
+ <xsd:extension base="tCallableElement">
+ <xsd:sequence>
+ <xsd:element ref="auditing" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="monitoring" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="property" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="laneSet" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="flowElement" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="artifact" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="supports" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="processType" type="tProcessType" default="none"/>
+ <xsd:attribute name="isClosed" type="xsd:boolean" default="false"/>
+ <xsd:attribute name="definitionalCollaborationRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tProcessType">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="none"/>
+ <xsd:enumeration value="executable"/>
+ <xsd:enumeration value="non-executable"/>
+ <xsd:enumeration value="public"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="property" type="tProperty" />
+ <xsd:complexType name="tProperty">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="dataState" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string"/>
+ <xsd:attribute name="itemSubjectRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="receiveTask" type="tReceiveTask" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tReceiveTask">
+ <xsd:complexContent>
+ <xsd:extension base="tTask">
+ <xsd:attribute name="implementation" type="tServiceImplementation" default="WebService"/>
+ <xsd:attribute name="instantiate" type="xsd:boolean" default="false"/>
+ <xsd:attribute name="messageRef" type="xsd:QName" use="optional"/>
+ <xsd:attribute name="operationRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="relationship" type="tRelationship"/>
+ <xsd:complexType name="tRelationship">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element name="source" type="xsd:QName" minOccurs="1" maxOccurs="unbounded"/>
+ <xsd:element name="target" type="xsd:QName" minOccurs="1" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="type" type="xsd:string" use="required"/>
+ <xsd:attribute name="direction" type="tRelationshipDirection"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tRelationshipDirection">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="none"/>
+ <xsd:enumeration value="forward"/>
+ <xsd:enumeration value="backward"/>
+ <xsd:enumeration value="both"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="rendering" type="tRendering"/>
+ <xsd:complexType name="tRendering">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="resource" type="tResource" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tResource">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:sequence>
+ <xsd:element ref="resourceParameter" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="name" type="xsd:string" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="resourceAssignmentExpression" type="tResourceAssignmentExpression"/>
+ <xsd:complexType name="tResourceAssignmentExpression">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="expression" minOccurs="1" maxOccurs="1"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="resourceParameter" type="tResourceParameter"/>
+ <xsd:complexType name="tResourceParameter">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:attribute name="name" type="xsd:string"/>
+ <xsd:attribute name="type" type="xsd:QName"/>
+ <xsd:attribute name="isRequired" type="xsd:boolean"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="resourceParameterBinding" type="tResourceParameterBinding"/>
+ <xsd:complexType name="tResourceParameterBinding">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement">
+ <xsd:sequence>
+ <xsd:element ref="expression" minOccurs="1" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="parameterRef" type="xsd:QName" use="required"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="rootElement" type="tRootElement"/>
+ <xsd:complexType name="tRootElement" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tBaseElement"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="scriptTask" type="tScriptTask" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tScriptTask">
+ <xsd:complexContent>
+ <xsd:extension base="tTask">
+ <xsd:sequence>
+ <xsd:element ref="script" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="scriptLanguage" type="xsd:anyURI"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="script" type="tScript"/>
+ <xsd:complexType name="tScript" mixed="true">
+ <xsd:sequence>
+ <xsd:any namespace="##any" processContents="lax" minOccurs="0"/>
+ </xsd:sequence>
+ </xsd:complexType>
+
+ <xsd:element name="sendTask" type="tSendTask" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tSendTask">
+ <xsd:complexContent>
+ <xsd:extension base="tTask">
+ <xsd:attribute name="implementation" type="tServiceImplementation" default="WebService"/>
+ <xsd:attribute name="messageRef" type="xsd:QName" use="optional"/>
+ <xsd:attribute name="operationRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="sequenceFlow" type="tSequenceFlow" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tSequenceFlow">
+ <xsd:complexContent>
+ <xsd:extension base="tFlowElement">
+ <xsd:sequence>
+ <xsd:element name="conditionExpression" type="tExpression" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ <xsd:attribute name="sourceRef" type="xsd:IDREF" use="required"/>
+ <xsd:attribute name="targetRef" type="xsd:IDREF" use="required"/>
+ <xsd:attribute name="isImmediate" type="xsd:boolean" default="true"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="serviceTask" type="tServiceTask" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tServiceTask">
+ <xsd:complexContent>
+ <xsd:extension base="tTask">
+ <xsd:attribute name="implementation" type="tServiceImplementation" default="WebService"/>
+ <xsd:attribute name="operationRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tServiceImplementation">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="WebService"/>
+ <xsd:enumeration value="Other"/>
+ <xsd:enumeration value="Unspecified"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="signal" type="tSignal" substitutionGroup="rootElement"/>
+ <xsd:complexType name="tSignal">
+ <xsd:complexContent>
+ <xsd:extension base="tRootElement">
+ <xsd:attribute name="name" type="xsd:string"/>
+ <xsd:attribute name="structureRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="signalEventDefinition" type="tSignalEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tSignalEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition">
+ <xsd:attribute name="signalRef" type="xsd:QName"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="standardLoopCharacteristics" type="tStandardLoopCharacteristics" substitutionGroup="loopCharacteristics"/>
+ <xsd:complexType name="tStandardLoopCharacteristics">
+ <xsd:complexContent>
+ <xsd:extension base="tLoopCharacteristics">
+ <xsd:sequence>
+ <xsd:element name="loopCondition" type="tExpression" minOccurs="0"/>
+ </xsd:sequence>
+ <xsd:attribute name="testBefore" type="xsd:boolean" default="false"/>
+ <xsd:attribute name="loopMaximum" type="xsd:integer" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="startEvent" type="tStartEvent" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tStartEvent">
+ <xsd:complexContent>
+ <xsd:extension base="tCatchEvent">
+ <xsd:attribute name="isInterrupting" type="xsd:boolean" default="false"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="subConversation" type="tSubConversation" substitutionGroup="conversationNode"/>
+ <xsd:complexType name="tSubConversation">
+ <xsd:complexContent>
+ <xsd:extension base="tConversationNode">
+ <xsd:sequence>
+ <xsd:element ref="conversationNode" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="artifact" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="correlationKeyRef" type="xsd:QName" use="optional"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="subProcess" type="tSubProcess" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tSubProcess">
+ <xsd:complexContent>
+ <xsd:extension base="tActivity">
+ <xsd:sequence>
+ <xsd:element ref="flowElement" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="artifact" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="triggeredByEvent" type="xsd:boolean" default="false"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="task" type="tTask" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tTask">
+ <xsd:complexContent>
+ <xsd:extension base="tActivity"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="terminateEventDefinition" type="tTerminateEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tTerminateEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition"/>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="textAnnotation" type="tTextAnnotation" substitutionGroup="artifact"/>
+ <xsd:complexType name="tTextAnnotation">
+ <xsd:complexContent>
+ <xsd:extension base="tArtifact">
+ <xsd:sequence>
+ <xsd:element ref="text" minOccurs="0" maxOccurs="1"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="text" type="tText"/>
+ <xsd:complexType name="tText" mixed="true">
+ <xsd:sequence>
+ <xsd:any namespace="##any" processContents="lax" minOccurs="0"/>
+ </xsd:sequence>
+ </xsd:complexType>
+
+ <xsd:element name="throwEvent" type="tThrowEvent"/>
+ <xsd:complexType name="tThrowEvent" abstract="true">
+ <xsd:complexContent>
+ <xsd:extension base="tEvent">
+ <xsd:sequence>
+ <xsd:element ref="dataInput" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="dataInputAssociation" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element ref="inputSet" minOccurs="0" maxOccurs="1"/>
+ <xsd:element ref="eventDefinition" minOccurs="0" maxOccurs="unbounded"/>
+ <xsd:element name="eventDefinitionRef" type="xsd:QName" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="timerEventDefinition" type="tTimerEventDefinition" substitutionGroup="eventDefinition"/>
+ <xsd:complexType name="tTimerEventDefinition">
+ <xsd:complexContent>
+ <xsd:extension base="tEventDefinition">
+ <xsd:choice>
+ <xsd:element name="timeDate" type="tExpression" minOccurs="0" maxOccurs="1"/>
+ <xsd:element name="timeCycle" type="tExpression" minOccurs="0" maxOccurs="1"/>
+ </xsd:choice>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:element name="transaction" type="tTransaction" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tTransaction">
+ <xsd:complexContent>
+ <xsd:extension base="tActivity">
+ <xsd:attribute name="method" type="tTransactionMethod" default="compensate"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tTransactionMethod">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="compensate"/>
+ <xsd:enumeration value="image"/>
+ <xsd:enumeration value="store"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+ <xsd:element name="userTask" type="tUserTask" substitutionGroup="flowElement"/>
+ <xsd:complexType name="tUserTask">
+ <xsd:complexContent>
+ <xsd:extension base="tTask">
+ <xsd:sequence>
+ <xsd:element ref="rendering" minOccurs="0" maxOccurs="unbounded"/>
+ </xsd:sequence>
+ <xsd:attribute name="implementation" type="tUserTaskImplementation" default="unspecified"/>
+ </xsd:extension>
+ </xsd:complexContent>
+ </xsd:complexType>
+
+ <xsd:simpleType name="tUserTaskImplementation">
+ <xsd:restriction base="xsd:string">
+ <xsd:enumeration value="unspecified"/>
+ <xsd:enumeration value="other"/>
+ <xsd:enumeration value="webService"/>
+ <xsd:enumeration value="humanTaskWebService"/>
+ </xsd:restriction>
+ </xsd:simpleType>
+
+</xsd:schema>
\ No newline at end of file
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/BPMN/Semantic.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.0.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.0.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.0.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,866 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- edited with XMLSPY v2004 rel. 4 U (http://www.xmlspy.com) by Jim Rigsbee (private) -->
+<xs:schema targetNamespace="http://jbpm.org/3/jpdl" elementFormDefault="qualified" attributeFormDefault="unqualified" version="3.0" xmlns="http://jbpm.org/3/jpdl" xmlns:xs="http://www.w3.org/2001/XMLSchema">
+ <xs:element name="process-definition" type="process-definition-v3.0">
+ <xs:annotation>
+ <xs:documentation>jBPM Process Definition Language (JPDL) version 3.0 </xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ <xs:simpleType name="configType">
+ <xs:annotation>
+ <xs:documentation>Indicates how to use the metadata within a handler</xs:documentation>
+ </xs:annotation>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="field"/>
+ <xs:enumeration value="bean"/>
+ <xs:enumeration value="constructor"/>
+ <xs:enumeration value="configuration-property"/>
+ </xs:restriction>
+ </xs:simpleType>
+ <xs:simpleType name="duedateType">
+ <xs:annotation>
+ <xs:documentation>Expression that indicates when a timer is due to fire</xs:documentation>
+ </xs:annotation>
+ <xs:restriction base="xs:string">
+ <xs:pattern value="\p{N}+([ ]+business)?[ ]+((second)|(seconds)|(minute)|(minutes)|(hour)|(hours)|(day)|(days)|(week)|(weeks)|(month)|(months)|(year)|(years))([ ]+(and)[ ]+\p{N}+([ ]+business)?[ ]+((second)|(seconds)|(minute)|(minutes)|(hour)|(hours)|(day)|(days)|(week)|(weeks)|(month)|(months)|(year)|(years)))*"/>
+ </xs:restriction>
+ </xs:simpleType>
+ <xs:simpleType name="booleanType">
+ <xs:annotation>
+ <xs:documentation>Yes, no, true, false, on, and off</xs:documentation>
+ </xs:annotation>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="yes"/>
+ <xs:enumeration value="no"/>
+ <xs:enumeration value="true"/>
+ <xs:enumeration value="false"/>
+ <xs:enumeration value="on"/>
+ <xs:enumeration value="off"/>
+ </xs:restriction>
+ </xs:simpleType>
+ <xs:simpleType name="accessType">
+ <xs:annotation>
+ <xs:documentation>Defines how a variable may be accessed</xs:documentation>
+ </xs:annotation>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="read"/>
+ <xs:enumeration value="read,required"/>
+ <xs:enumeration value="read,write"/>
+ <xs:enumeration value="read,write,required"/>
+ <xs:enumeration value="write"/>
+ </xs:restriction>
+ </xs:simpleType>
+ <xs:simpleType name="repeatType">
+ <xs:annotation>
+ <xs:documentation>Defines if and when to repeat a timer</xs:documentation>
+ </xs:annotation>
+ <xs:union memberTypes="duedateType booleanType"/>
+ </xs:simpleType>
+ <xs:element name="action">
+ <xs:annotation>
+ <xs:documentation>Defines custom behavior</xs:documentation>
+ </xs:annotation>
+ <xs:complexType mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>The name of the action. When actions are given names, they can be looked up from the process definition. This can be useful for runtime actions and declaring actions only once.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="class" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>Either a class or ref-name must be specified.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="ref-name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>Either a class or ref-name must be specified. The content of this action is not processed if a referenced action is specified.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="accept-propagated-events" type="booleanType" use="optional" default="true">
+ <xs:annotation>
+ <xs:documentation>If set to false, the action will only be executed on events that were fired on this action's element.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="config-type" type="configType" use="optional">
+ <xs:annotation>
+ <xs:documentation>Specifies how the action object should be constructed and how the content of this element should be used as configuration information for the action object.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="assignment">
+ <xs:annotation>
+ <xs:documentation>Controls the behavior of assigning a task to an identity.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>The content of the assignment element can be used as configuration information for your custom assignment handler implementations. This allows the creation of reusable delegation classes.</xs:documentation>
+ </xs:annotation>
+ </xs:any>
+ </xs:sequence>
+ <xs:attribute name="class" type="xs:string" use="required">
+ <xs:annotation>
+ <xs:documentation>The fully qualified class name of an implementation of org.jbpm.taskmgmt.def.AssignmentHandler.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="config-type" type="configType" use="optional">
+ <xs:annotation>
+ <xs:documentation>Specifies how the assignment handler object should be constructed and how the content of this element should be used as configuration information for that object.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="expression" type="xs:string" use="optional"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="cancel-timer">
+ <xs:annotation>
+ <xs:documentation>Cancels a timer previously set with create-timer</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:attribute name="name" type="xs:string" use="required">
+ <xs:annotation>
+ <xs:documentation>The name of the timer to be cancelled.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="create-timer">
+ <xs:annotation>
+ <xs:documentation>See documentation for the timer element.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>The name of the timer. This name can be used later in a cancel-timer element.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="duedate" type="duedateType" use="required">
+ <xs:annotation>
+ <xs:documentation>The duration that specifies the time period between the creation of the timer and the execution of the timer. This can be expressed in business hours, minutes, etc. See the documentation for syntax for this attribute.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="repeat" type="repeatType" use="optional">
+ <xs:annotation>
+ <xs:documentation>yes, true, or duration. After a timer has been executed on the duedate, this repeat attribute specifies the duration between repeating timer executions until the node is left. If yes or true are specified then the value of duedate is used.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="transition" type="xs:string" use="optional"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="decision">
+ <xs:annotation>
+ <xs:documentation>Defines a decision to be made in the processing path</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:annotation>
+ <xs:documentation>Either a handler or transitions with conditions should be specified. The decision will look for the first transition for which the condition evaluates to true. A transition without a condition is considered to evaluate to true (to model the 'otherwise' branch. See the condition element.</xs:documentation>
+ </xs:annotation>
+ <xs:element name="handler" minOccurs="0">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>The content of the handler element can be used as configuration information for your custom decision handler implementations. This allows the creation of reusable delegation classes.</xs:documentation>
+ </xs:annotation>
+ </xs:any>
+ </xs:sequence>
+ <xs:attribute name="class" type="xs:string" use="required">
+ <xs:annotation>
+ <xs:documentation>The fully qualified class name of an implementation of org.jbpm.graph.node.DecisionHandler.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="config-type" type="configType" use="optional">
+ <xs:annotation>
+ <xs:documentation>Specifies how the decision handler object should be constructed and how the content of this element should be used as configuration information for that object.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="condition" minOccurs="0">
+ <xs:annotation>
+ <xs:documentation>A beanshell script that evaluates to true or false.</xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="action" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="script" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="create-timer" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="cancel-timer" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:choice>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required">
+ <xs:annotation>
+ <xs:documentation>The name of the transition. Note that each transition leaving a node must have a distinct name.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="to" type="xs:string" use="required">
+ <xs:annotation>
+ <xs:documentation>The hierarchical name of the destination node. See documentation for an description of hierarchical names.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="event" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="timer" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="end-state">
+ <xs:annotation>
+ <xs:documentation>Marks the end of a processing path.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="event" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>Event types supported: node-enter, before-signal</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="node-enter"/>
+ <xs:enumeration value="before-signal"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="event">
+ <xs:annotation>
+ <xs:documentation>Supported event types: node-enter, node-leave, before-signal, after-signal.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="node-enter"/>
+ <xs:enumeration value="node-leave"/>
+ <xs:enumeration value="before-signal"/>
+ <xs:enumeration value="after-signal"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="exception-handler">
+ <xs:annotation>
+ <xs:documentation>A list of exception handlers that applies to all exceptions thrown by delegation classes within this node.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="exception-class" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>Specifies the fully qualified class name of the java throwable class that should match this exception handler. If this attribute is not specified it matches all exceptions derived from java.lang.Throwable.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="fork">
+ <xs:annotation>
+ <xs:documentation>Defines a point in the processing path where multiple execution paths will run in parallel.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element ref="script" minOccurs="0"/>
+ <xs:element ref="transition" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="event" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="timer" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="join">
+ <xs:annotation>
+ <xs:documentation>Defines a point in the processing path where multiple execution paths merge into one path.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element ref="transition" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="event" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="timer" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="node">
+ <xs:annotation>
+ <xs:documentation>A generic node allowing custom behavior.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:choice minOccurs="0" maxOccurs="1">
+ <xs:annotation>
+ <xs:documentation>A custom action that represents the behaviour for this node</xs:documentation>
+ </xs:annotation>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:element ref="transition" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="event" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="timer" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="process-state">
+ <xs:annotation>
+ <xs:documentation>A node that allows execution of another subordinate process.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="sub-process">
+ <xs:complexType>
+ <xs:attribute name="name" type="xs:string" use="required">
+ <xs:annotation>
+ <xs:documentation>The name of the subordinate process definition to be executed within the enclosing process.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="version" type="xs:integer" use="optional">
+ <xs:annotation>
+ <xs:documentation>The version of the deployed process-definition that is to be executed. If none is specified the latest version of the identified process will be used.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="variable" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="transition" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element name="event" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>Supported event types: node-enter, node-leave, before-signal, after-signal, subprocess-created, subprocess-end.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="node-enter"/>
+ <xs:enumeration value="node-leave"/>
+ <xs:enumeration value="before-signal"/>
+ <xs:enumeration value="after-signal"/>
+ <xs:enumeration value="subprocess-created"/>
+ <xs:enumeration value="subprocess-end"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="timer" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="script">
+ <xs:annotation>
+ <xs:documentation>A beanshell script to execute. The script can be the content of this tag or you can specify one or more variables and a beanshell script in the expression tag.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence minOccurs="0">
+ <xs:element ref="variable" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element name="expression">
+ <xs:annotation>
+ <xs:documentation>The beanshell script.</xs:documentation>
+ </xs:annotation>
+ </xs:element>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>The name of the script action. When actions are given names, they can be looked up from the process definition. This can be useful for runtime actions and declaring actions only once.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="accept-propagated-events" type="booleanType" use="optional" default="true">
+ <xs:annotation>
+ <xs:documentation>If set to false the action will only be executed on events that were fired in this action's element.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="state">
+ <xs:annotation>
+ <xs:documentation>Represents a wait state in a process.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:choice minOccurs="0">
+ <xs:annotation>
+ <xs:documentation>A custom action that represents the behaviour for this node</xs:documentation>
+ </xs:annotation>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:element ref="transition" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="event" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="timer" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="super-state">
+ <xs:annotation>
+ <xs:documentation>Grouping mechanism for a named set of nodes.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>The nodes of the process definition. Note that a process without nodes is valid, but cannot be executed.</xs:documentation>
+ </xs:annotation>
+ <xs:element ref="state"/>
+ <xs:element ref="task-node"/>
+ <xs:element ref="super-state"/>
+ <xs:element ref="process-state"/>
+ <xs:element ref="node"/>
+ <xs:element ref="fork"/>
+ <xs:element ref="join"/>
+ <xs:element ref="decision"/>
+ <xs:element ref="end-state"/>
+ </xs:choice>
+ <xs:element ref="transition" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element name="event" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>Supports all event types except the process-start and end events.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="node-enter"/>
+ <xs:enumeration value="node-leave"/>
+ <xs:enumeration value="before-signal"/>
+ <xs:enumeration value="after-signal"/>
+ <xs:enumeration value="superstate-enter"/>
+ <xs:enumeration value="superstate-leave"/>
+ <xs:enumeration value="task-create"/>
+ <xs:enumeration value="task-assign"/>
+ <xs:enumeration value="task-start"/>
+ <xs:enumeration value="task-end"/>
+ <xs:enumeration value="transition"/>
+ <xs:enumeration value="timer"/>
+ <xs:enumeration value="subprocess-created"/>
+ <xs:enumeration value="subprocess-end"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="timer" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="swimlane">
+ <xs:annotation>
+ <xs:documentation>Groups tasks assigned to the same resource.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element ref="assignment" minOccurs="0"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="task">
+ <xs:annotation>
+ <xs:documentation>The tasks that should be created when execution arrives in this task node.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element ref="assignment" minOccurs="0"/>
+ <xs:element name="controller" minOccurs="0">
+ <xs:annotation>
+ <xs:documentation>Controller supports the inclusion of one or more "variable" tags as children. It also supports custom XML for use with a custom controller class as indicated by config-type.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>This section can include "variable" elements to identify input and output variables involved in this task.</xs:documentation>
+ </xs:annotation>
+ </xs:any>
+ </xs:sequence>
+ <xs:attribute name="class" type="xs:string" use="optional"/>
+ <xs:attribute name="config-type" type="configType" use="optional">
+ <xs:annotation>
+ <xs:documentation>Specifies how the assignment handler object should be constructed and how the content of this element should be used as configuration information for that object.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="event" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>Supports events: task-create, task-assign, task-start, task-end.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="task-create"/>
+ <xs:enumeration value="task-start"/>
+ <xs:enumeration value="task-assign"/>
+ <xs:enumeration value="task-end"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="timer" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>Specifies a timer that monitors the duration of an execution in this task.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>The name for this timer. Every timer should have a unique name. If a name is not specified then the name of the enclosing node is taken.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="duedate" type="duedateType" use="required">
+ <xs:annotation>
+ <xs:documentation>The duration that specifies the time period between the creation of the timer and the execution of the timer. This can be expressed in business hours, minutes, etc. See the documentation for syntax for this attribute.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="repeat" type="repeatType" use="optional">
+ <xs:annotation>
+ <xs:documentation>yes, true, or duration. After a timer has been executed on the duedate, this repeat attribute specifies the duration between repeating timer executions until the node is left. If yes or true are specified then the value of duedate is used.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="transition" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>A transition name to be taken after the timer executes, the timer event is fired and execution of any specified actions has completed.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="cancel-event" type="xs:string" use="optional" default="task-end">
+ <xs:annotation>
+ <xs:documentation>task-assign, task-start, task-end, or any combination of these specified as a comma separated list.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>Named tasks can be referenced and looked up via the TaskMgmtDefinition.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="blocking" type="booleanType" use="optional" default="false"/>
+ <xs:attribute name="signalling" type="booleanType" use="optional" default="true"/>
+ <xs:attribute name="description" type="xs:string" use="optional"/>
+ <xs:attribute name="duedate" type="duedateType" use="optional">
+ <xs:annotation>
+ <xs:documentation>The duration that specifies the time period between the creation of the timer and the execution of the timer. This can be expressed in business hours, minutes, etc. See the documentation for syntax for this attribute.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="swimlane" type="xs:string" use="optional"/>
+ <xs:attribute name="priority" use="optional" default="normal">
+ <xs:annotation>
+ <xs:documentation>This value can also be any integer where the lower the number the higher the priority.</xs:documentation>
+ </xs:annotation>
+ <xs:simpleType>
+ <xs:union>
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="highest"/>
+ <xs:enumeration value="high"/>
+ <xs:enumeration value="normal"/>
+ <xs:enumeration value="low"/>
+ <xs:enumeration value="lowest"/>
+ </xs:restriction>
+ </xs:simpleType>
+ <xs:simpleType>
+ <xs:restriction base="xs:int"/>
+ </xs:simpleType>
+ </xs:union>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="task-node">
+ <xs:annotation>
+ <xs:documentation>A node which accepts a list of tasks to be executed.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element ref="task" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="transition" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="event" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="timer" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="signal" use="optional" default="last">
+ <xs:annotation>
+ <xs:documentation>Signal specifies the effect of task completion on the process execution continuation.</xs:documentation>
+ </xs:annotation>
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="unsynchronized"/>
+ <xs:enumeration value="never"/>
+ <xs:enumeration value="first"/>
+ <xs:enumeration value="first-wait"/>
+ <xs:enumeration value="last"/>
+ <xs:enumeration value="last-wait"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ <xs:attribute name="create-tasks" type="booleanType" use="optional" default="true">
+ <xs:annotation>
+ <xs:documentation>Can be set to false when a runtime calculation has to determine which of the tasks have to be created. In that case, add an action on node-enter, create the tasks in the action, and set create-tasks to false.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="end-tasks" type="booleanType" use="optional" default="false">
+ <xs:annotation>
+ <xs:documentation>Can be set to true, in which all the tasks that are still open are ended on the node-leave event.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="timer">
+ <xs:annotation>
+ <xs:documentation>Specifies a timer that monitors the duration of an execution in this node.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>The name for this timer. Every timer should have a unique name. If a name is not specified then the name of the enclosing node is taken.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="duedate" type="duedateType" use="required">
+ <xs:annotation>
+ <xs:documentation>The duration that specifies the time period between the creation of the timer and the execution of the timer. This can be expressed in business hours, minutes, etc. See the documentation for syntax for this attribute.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="repeat" type="repeatType" use="optional">
+ <xs:annotation>
+ <xs:documentation>yes, true, or duration. After a timer has been executed on the duedate, this repeat attribute specifies the duration between repeating timer executions until the node is left. If yes or true are specified then the value of duedate is used.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="transition" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>A transition name to be taken after the timer executes, the timer event is fired and execution of any specified actions has completed.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="transition">
+ <xs:annotation>
+ <xs:documentation>The leaving transitions. Each transition leaving a node must have a distinct name. At most one transition can have no name. The first transition specified is the default transition: the path taken when the node is left without specifying a transition.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>The name of the transition. Note that each transition leaving a node must have a distinct name.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ <xs:attribute name="to" type="xs:string" use="required">
+ <xs:annotation>
+ <xs:documentation>The hierarchical name of the destination node. See documentation for an description of hierarchical names.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element name="variable">
+ <xs:annotation>
+ <xs:documentation>Input and Output variables for the node. Input variables are specified by access "read". If you have assigned variables during the script evaluation, the variables with "write" access allows you to store the values in the process instance. It does not matter whether the variables existed prior to this action.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>User defined metadata.</xs:documentation>
+ </xs:annotation>
+ </xs:any>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="access" type="accessType" use="optional" default="read,write"/>
+ <xs:attribute name="mapped-name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>Defaults to the process variable name as given by the name attribute.</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:complexType name="process-definition-v3.0">
+ <xs:annotation>
+ <xs:documentation>Version 3.0 of the PDL schema</xs:documentation>
+ </xs:annotation>
+ <xs:sequence>
+ <xs:element ref="swimlane" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element name="start-state" minOccurs="0">
+ <xs:annotation>
+ <xs:documentation>The start state of the process. Note that a process without a start-state is valid, but cannot be executed.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element ref="task" minOccurs="0"/>
+ <xs:element ref="transition" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element name="event" minOccurs="0" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="node-leave"/>
+ <xs:enumeration value="after-signal"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="optional"/>
+ <xs:attribute name="swimlane" type="xs:string" use="optional"/>
+ </xs:complexType>
+ </xs:element>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>The nodes of the process definition. Note that a process without nodes is valid, but cannot be executed.</xs:documentation>
+ </xs:annotation>
+ <xs:element ref="state"/>
+ <xs:element ref="task-node"/>
+ <xs:element ref="super-state"/>
+ <xs:element ref="process-state"/>
+ <xs:element ref="node"/>
+ <xs:element ref="fork"/>
+ <xs:element ref="join"/>
+ <xs:element ref="decision"/>
+ <xs:element ref="end-state"/>
+ </xs:choice>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>Globally defined actions that can be referenced from events and transitions. </xs:documentation>
+ </xs:annotation>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:element ref="task" minOccurs="0" maxOccurs="unbounded"/>
+ <xs:element name="event" minOccurs="0" maxOccurs="unbounded">
+ <xs:annotation>
+ <xs:documentation>Supports all event types. Uniquely supports process-start and process-end.</xs:documentation>
+ </xs:annotation>
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="node-enter"/>
+ <xs:enumeration value="node-leave"/>
+ <xs:enumeration value="before-signal"/>
+ <xs:enumeration value="after-signal"/>
+ <xs:enumeration value="superstate-enter"/>
+ <xs:enumeration value="superstate-leave"/>
+ <xs:enumeration value="task-create"/>
+ <xs:enumeration value="task-assign"/>
+ <xs:enumeration value="task-start"/>
+ <xs:enumeration value="task-end"/>
+ <xs:enumeration value="transition"/>
+ <xs:enumeration value="timer"/>
+ <xs:enumeration value="subprocess-created"/>
+ <xs:enumeration value="subprocess-end"/>
+ <xs:enumeration value="process-start"/>
+ <xs:enumeration value="process-end"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="exception-handler" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="optional">
+ <xs:annotation>
+ <xs:documentation>the name of the process</xs:documentation>
+ </xs:annotation>
+ </xs:attribute>
+ </xs:complexType>
+</xs:schema>
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.0.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.1.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.1.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.1.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,456 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<xs:schema xmlns= "urn:jbpm.org:jpdl-3.1"
+ targetNamespace="urn:jbpm.org:jpdl-3.1"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"
+ elementFormDefault="qualified">
+
+ <!-- PROCESS-DEFINITION -->
+ <!-- ################## -->
+ <xs:element name="process-definition">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="swimlane" />
+ <xs:element ref="start-state" />
+ <xs:group ref="node-elements"/>
+ <xs:group ref="action-elements" />
+ <xs:element ref="event" />
+ <xs:element ref="exception-handler" />
+ <xs:element ref="task" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- SWIMLANE -->
+ <!-- ######## -->
+ <xs:element name="swimlane">
+ <xs:complexType>
+ <xs:sequence minOccurs="0" maxOccurs="1">
+ <xs:element ref="assignment"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- NODES -->
+ <!-- ##### -->
+ <xs:element name="start-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="task"/>
+ <xs:element ref="transition"/>
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="end-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="decision">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element name="handler" type="delegation" />
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ <xs:element name="transition">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element name="condition">
+ <xs:complexType mixed="true">
+ <xs:sequence minOccurs="0" maxOccurs="unbounded">
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="expression" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+ <xs:group ref="action-elements"/>
+ <xs:element ref="exception-handler"/>
+ </xs:choice>
+ <xs:attribute name="to" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="expression" type="xs:string" />
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="fork">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="script" />
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="join">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="node">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:choice minOccurs="0">
+ <xs:group ref="action-elements" />
+ </xs:choice>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="process-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element name="sub-process">
+ <xs:complexType>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ <xs:attribute name="version" type="xs:integer" />
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="variable" />
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-content-elements"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="super-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-elements"/>
+ <xs:group ref="node-content-elements"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="task-node">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="task" />
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="create-tasks" type="booleanType" default="true" />
+ <xs:attribute name="end-tasks" type="booleanType" default="false" />
+ <xs:attribute name="signal" default="last">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="unsynchronized"/>
+ <xs:enumeration value="never"/>
+ <xs:enumeration value="first"/>
+ <xs:enumeration value="first-wait"/>
+ <xs:enumeration value="last"/>
+ <xs:enumeration value="last-wait"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- TRANSITION -->
+ <!-- ########## -->
+ <xs:element name="transition">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="action-elements"/>
+ <xs:element ref="exception-handler" />
+ </xs:choice>
+ <xs:attribute name="to" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- ACTIONS -->
+ <!-- ####### -->
+ <xs:element name="action">
+ <xs:complexType mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="class" type="xs:string" />
+ <xs:attribute name="config-type" default="field">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="field"/>
+ <xs:enumeration value="bean"/>
+ <xs:enumeration value="constructor"/>
+ <xs:enumeration value="configuration-property"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="ref-name" type="xs:string" />
+ <xs:attribute name="accept-propagated-events" type="booleanType" default="true" />
+ <xs:attribute name="expression" type="xs:string" />
+ <xs:attribute name="async" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="cancel-timer">
+ <xs:complexType>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="create-timer">
+ <xs:complexType>
+ <xs:choice>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="duedate" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="repeat" type="xs:string" />
+ <xs:attribute name="transition" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="script">
+ <xs:complexType mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="accept-propagated-events" type="booleanType" default="true" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- EVENT -->
+ <!-- ##### -->
+ <xs:element name="event">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="action-elements"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:union>
+ <xs:simpleType>
+ <xs:restriction base="xs:string"/>
+ </xs:simpleType>
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="node-enter"/>
+ <xs:enumeration value="node-leave"/>
+ <xs:enumeration value="process-start"/>
+ <xs:enumeration value="process-end"/>
+ <xs:enumeration value="task-create"/>
+ <xs:enumeration value="task-assign"/>
+ <xs:enumeration value="task-start"/>
+ <xs:enumeration value="task-end"/>
+ <xs:enumeration value="before-signal"/>
+ <xs:enumeration value="after-signal"/>
+ <xs:enumeration value="superstate-enter"/>
+ <xs:enumeration value="superstate-leave"/>
+ <xs:enumeration value="timer-create"/>
+ <xs:enumeration value="subprocess-created"/>
+ <xs:enumeration value="subprocess-end"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:union>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- EXCEPTION-HANDLER -->
+ <!-- ################# -->
+ <xs:element name="exception-handler">
+ <xs:complexType>
+ <xs:choice minOccurs="1" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="exception-class" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- TASK -->
+ <!-- #### -->
+ <xs:element name="task">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="assignment"/>
+ <xs:element ref="controller"/>
+ <xs:element ref="event"/>
+ <xs:element ref="timer"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="blocking" type="booleanType" default="false"/>
+ <xs:attribute name="signalling" type="booleanType" default="true"/>
+ <xs:attribute name="description" type="xs:string" />
+ <xs:attribute name="duedate" type="xs:string" />
+ <xs:attribute name="swimlane" type="xs:string" />
+ <xs:attribute name="priority" type="priorityType" default="normal" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="controller" type="delegation" />
+
+ <xs:element name="assignment">
+ <xs:complexType>
+ <xs:complexContent>
+ <xs:extension base="delegation">
+ <xs:attribute name="expression" type="xs:string" />
+ <xs:attribute name="actor-id" type="xs:string" />
+ <xs:attribute name="pooled-actors" type="xs:string" />
+ </xs:extension>
+ </xs:complexContent>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- TIMER -->
+ <!-- ##### -->
+ <xs:element name="timer">
+ <xs:complexType>
+ <xs:choice>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="duedate" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="repeat" type="xs:string" />
+ <xs:attribute name="transition" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="variable">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="access" type="xs:string" default="read,write"/>
+ <xs:attribute name="mapped-name" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- TYPES AND GROUPS -->
+ <!-- ################ -->
+ <xs:complexType name="delegation" mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="class" type="xs:string" />
+ <xs:attribute name="config-type" default="field">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="field"/>
+ <xs:enumeration value="bean"/>
+ <xs:enumeration value="constructor"/>
+ <xs:enumeration value="configuration-property"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+
+ <xs:simpleType name="configType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="field"/>
+ <xs:enumeration value="bean"/>
+ <xs:enumeration value="constructor"/>
+ <xs:enumeration value="configuration-property"/>
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="booleanType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="yes"/>
+ <xs:enumeration value="no"/>
+ <xs:enumeration value="true"/>
+ <xs:enumeration value="false"/>
+ <xs:enumeration value="on"/>
+ <xs:enumeration value="off"/>
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="priorityType">
+ <xs:union>
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="highest"/>
+ <xs:enumeration value="high"/>
+ <xs:enumeration value="normal"/>
+ <xs:enumeration value="low"/>
+ <xs:enumeration value="lowest"/>
+ </xs:restriction>
+ </xs:simpleType>
+ <xs:simpleType>
+ <xs:restriction base="xs:int"/>
+ </xs:simpleType>
+ </xs:union>
+ </xs:simpleType>
+
+ <xs:group name="node-elements">
+ <xs:choice>
+ <xs:element ref="node"/>
+ <xs:element ref="state"/>
+ <xs:element ref="task-node"/>
+ <xs:element ref="super-state"/>
+ <xs:element ref="process-state"/>
+ <xs:element ref="fork"/>
+ <xs:element ref="join"/>
+ <xs:element ref="decision"/>
+ <xs:element ref="end-state"/>
+ </xs:choice>
+ </xs:group>
+
+ <xs:group name="action-elements">
+ <xs:choice>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ </xs:choice>
+ </xs:group>
+
+ <xs:group name="node-content-elements">
+ <xs:choice>
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ <xs:element ref="timer"/>
+ <xs:element ref="transition"/>
+ </xs:choice>
+ </xs:group>
+
+</xs:schema>
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.1.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.2.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.2.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.2.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,499 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<xs:schema xmlns= "urn:jbpm.org:jpdl-3.2"
+ targetNamespace="urn:jbpm.org:jpdl-3.2"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"
+ elementFormDefault="qualified">
+
+ <!-- PROCESS-DEFINITION -->
+ <!-- ################## -->
+ <xs:element name="process-definition">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element ref="swimlane" />
+ <xs:element ref="start-state" />
+ <xs:group ref="node-elements"/>
+ <xs:group ref="action-elements" />
+ <xs:element ref="event" />
+ <xs:element ref="exception-handler" />
+ <xs:element ref="task" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- SWIMLANE -->
+ <!-- ######## -->
+ <xs:element name="swimlane">
+ <xs:complexType>
+ <xs:sequence minOccurs="0" maxOccurs="1">
+ <xs:element ref="assignment"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- NODES -->
+ <!-- ##### -->
+ <xs:element name="start-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element ref="task"/>
+ <xs:element ref="transition"/>
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="end-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="end-complete-process" type="booleanType" use="optional" default="false"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="decision">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element name="handler" type="delegation" />
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ <xs:element ref="transition"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="expression" type="xs:string" />
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="fork">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="script" />
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="join">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="node">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:choice minOccurs="0" maxOccurs="1">
+ <xs:group ref="action-elements" />
+ </xs:choice>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="process-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element name="sub-process">
+ <xs:complexType>
+ <xs:attribute name="name" type="xs:string"
+ use="required" />
+ <xs:attribute name="version" type="xs:integer" />
+ <xs:attribute name="binding" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="variable" />
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ <xs:attribute name="async" type="xs:string" default="false" />
+ <xs:attribute name="binding" type="bindingType"></xs:attribute>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-content-elements"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="super-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-elements"/>
+ <xs:group ref="node-content-elements"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="task-node">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="task" />
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="create-tasks" type="booleanType" default="true" />
+ <xs:attribute name="end-tasks" type="booleanType" default="false" />
+ <xs:attribute name="signal" default="last">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="unsynchronized"/>
+ <xs:enumeration value="never"/>
+ <xs:enumeration value="first"/>
+ <xs:enumeration value="first-wait"/>
+ <xs:enumeration value="last"/>
+ <xs:enumeration value="last-wait"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="mail-node">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="subject" />
+ <xs:element ref="text" />
+ <xs:group ref="node-content-elements"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ <xs:attribute name="template" type="xs:string"/>
+ <xs:attribute name="actors" type="xs:string"/>
+ <xs:attribute name="to" type="xs:string"/>
+ <xs:attribute name="subject" type="xs:string"/>
+ <xs:attribute name="text" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+
+ <!-- TRANSITION -->
+ <!-- ########## -->
+ <xs:element name="transition">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element name="condition">
+ <xs:complexType mixed="true">
+ <xs:sequence minOccurs="0" maxOccurs="unbounded">
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="expression" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+ <xs:group ref="action-elements"/>
+ <xs:element ref="exception-handler" />
+ </xs:choice>
+ <xs:attribute name="to" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- ACTIONS -->
+ <!-- ####### -->
+ <xs:element name="action">
+ <xs:complexType mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="class" type="xs:string" />
+ <xs:attribute name="config-type" default="field" type="xs:string" />
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="ref-name" type="xs:string" />
+ <xs:attribute name="accept-propagated-events" type="booleanType" default="true" />
+ <xs:attribute name="expression" type="xs:string" />
+ <xs:attribute name="async" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="cancel-timer">
+ <xs:complexType>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="create-timer">
+ <xs:complexType>
+ <xs:choice minOccurs="0">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="duedate" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="repeat" type="xs:string" />
+ <xs:attribute name="transition" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="script">
+ <xs:complexType mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="accept-propagated-events" type="booleanType" default="true" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="mail">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="subject" />
+ <xs:element ref="text" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ <xs:attribute name="template" type="xs:string"/>
+ <xs:attribute name="actors" type="xs:string"/>
+ <xs:attribute name="to" type="xs:string"/>
+ <xs:attribute name="subject" type="xs:string"/>
+ <xs:attribute name="text" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- EVENT -->
+ <!-- ##### -->
+ <xs:element name="event">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="action-elements"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:union>
+ <xs:simpleType>
+ <xs:restriction base="xs:string"/>
+ </xs:simpleType>
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="node-enter"/>
+ <xs:enumeration value="node-leave"/>
+ <xs:enumeration value="process-start"/>
+ <xs:enumeration value="process-end"/>
+ <xs:enumeration value="task-create"/>
+ <xs:enumeration value="task-assign"/>
+ <xs:enumeration value="task-start"/>
+ <xs:enumeration value="task-end"/>
+ <xs:enumeration value="before-signal"/>
+ <xs:enumeration value="after-signal"/>
+ <xs:enumeration value="superstate-enter"/>
+ <xs:enumeration value="superstate-leave"/>
+ <xs:enumeration value="timer-create"/>
+ <xs:enumeration value="subprocess-created"/>
+ <xs:enumeration value="subprocess-end"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:union>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- EXCEPTION-HANDLER -->
+ <!-- ################# -->
+ <xs:element name="exception-handler">
+ <xs:complexType>
+ <xs:choice minOccurs="1" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="exception-class" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- TASK -->
+ <!-- #### -->
+ <xs:element name="task">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element ref="assignment"/>
+ <xs:element ref="controller"/>
+ <xs:element ref="event"/>
+ <xs:element ref="timer"/>
+ <xs:element name="reminder">
+ <xs:complexType>
+ <xs:attribute name="duedate" type="xs:string" use="required" />
+ <xs:attribute name="repeat" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="blocking" type="booleanType" default="false"/>
+ <xs:attribute name="signalling" type="booleanType" default="true"/>
+ <xs:attribute name="description" type="xs:string" />
+ <xs:attribute name="duedate" type="xs:string" />
+ <xs:attribute name="swimlane" type="xs:string" />
+ <xs:attribute name="priority" type="priorityType" default="normal" />
+ <xs:attribute name="notify" type="booleanType" default="false"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="controller" type="delegation" />
+
+ <xs:element name="assignment">
+ <xs:complexType>
+ <xs:complexContent>
+ <xs:extension base="delegation">
+ <xs:attribute name="expression" type="xs:string" />
+ <xs:attribute name="actor-id" type="xs:string" />
+ <xs:attribute name="pooled-actors" type="xs:string" />
+ </xs:extension>
+ </xs:complexContent>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- TIMER -->
+ <!-- ##### -->
+ <xs:element name="timer">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="1">
+ <xs:group ref="action-elements" />
+ </xs:choice>
+ <xs:attribute name="duedate" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="repeat" type="xs:string" />
+ <xs:attribute name="transition" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="variable">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="access" type="xs:string" default="read,write"/>
+ <xs:attribute name="mapped-name" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- MAIL -->
+ <!-- #### -->
+ <xs:element name="to" type="xs:string"/>
+ <xs:element name="recipients" type="xs:string"/>
+ <xs:element name="subject" type="xs:string"/>
+ <xs:element name="text" type="xs:string"/>
+ <xs:element name="template" type="xs:string"/>
+
+ <!-- TYPES AND GROUPS -->
+ <!-- ################ -->
+
+ <xs:element name="description" type="xs:string" />
+
+ <xs:complexType name="delegation" mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="class" type="xs:string" />
+ <xs:attribute name="config-type" default="field" type="xs:string" />
+ </xs:complexType>
+
+ <xs:simpleType name="configType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="field"/>
+ <xs:enumeration value="bean"/>
+ <xs:enumeration value="constructor"/>
+ <xs:enumeration value="configuration-property"/>
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="booleanType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="yes"/>
+ <xs:enumeration value="no"/>
+ <xs:enumeration value="true"/>
+ <xs:enumeration value="false"/>
+ <xs:enumeration value="on"/>
+ <xs:enumeration value="off"/>
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="priorityType">
+ <xs:union>
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="highest"/>
+ <xs:enumeration value="high"/>
+ <xs:enumeration value="normal"/>
+ <xs:enumeration value="low"/>
+ <xs:enumeration value="lowest"/>
+ </xs:restriction>
+ </xs:simpleType>
+ <xs:simpleType>
+ <xs:restriction base="xs:int"/>
+ </xs:simpleType>
+ </xs:union>
+ </xs:simpleType>
+
+ <xs:group name="node-elements">
+ <xs:choice>
+ <xs:element ref="node"/>
+ <xs:element ref="state"/>
+ <xs:element ref="task-node"/>
+ <xs:element ref="super-state"/>
+ <xs:element ref="process-state"/>
+ <xs:element ref="fork"/>
+ <xs:element ref="join"/>
+ <xs:element ref="decision"/>
+ <xs:element ref="end-state"/>
+ <xs:element ref="mail-node"/>
+ </xs:choice>
+ </xs:group>
+
+ <xs:group name="action-elements">
+ <xs:choice>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ <xs:element ref="mail"/>
+ </xs:choice>
+ </xs:group>
+
+ <xs:group name="node-content-elements">
+ <xs:choice>
+ <xs:element ref="description" />
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ <xs:element ref="timer"/>
+ <xs:element ref="transition"/>
+ </xs:choice>
+ </xs:group>
+
+ <xs:simpleType name="bindingType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="late"></xs:enumeration>
+ <xs:enumeration value="early"></xs:enumeration>
+ </xs:restriction>
+ </xs:simpleType>
+</xs:schema>
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.2.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.3.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.3.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.3.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,511 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<xs:schema targetNamespace="urn:jbpm.org:jpdl-3.3"
+ elementFormDefault="qualified"
+ xmlns="urn:jbpm.org:jpdl-3.3"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema">
+
+ <!-- PROCESS-DEFINITION -->
+ <!-- ################## -->
+ <xs:element name="process-definition">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element ref="swimlane" />
+ <xs:element ref="start-state" />
+ <xs:group ref="node-elements"/>
+ <xs:group ref="action-elements" />
+ <xs:element ref="event" />
+ <xs:element ref="exception-handler" />
+ <xs:element ref="task" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- SWIMLANE -->
+ <!-- ######## -->
+ <xs:element name="swimlane">
+ <xs:complexType>
+ <xs:sequence minOccurs="0" maxOccurs="1">
+ <xs:element ref="assignment"/>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- NODES -->
+ <!-- ##### -->
+ <xs:element name="start-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element ref="task"/>
+ <xs:element ref="transition"/>
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="end-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="end-complete-process" type="booleanType" use="optional" default="false"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="decision">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element name="handler" type="delegation" />
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ <xs:element ref="transition"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="expression" type="xs:string" />
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="fork">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="script" />
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="join">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ <xs:attribute name="lock" type="lockMode"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="node">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:choice minOccurs="0" maxOccurs="1">
+ <xs:group ref="action-elements" />
+ </xs:choice>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="process-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element name="sub-process">
+ <xs:complexType>
+ <xs:attribute name="name" type="xs:string"
+ use="required" />
+ <xs:attribute name="version" type="xs:integer" />
+ <xs:attribute name="binding" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+ <xs:element ref="variable" />
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ <xs:attribute name="async" type="xs:string" default="false" />
+ <xs:attribute name="binding" type="bindingType"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-content-elements"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="super-state">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="node-elements"/>
+ <xs:group ref="node-content-elements"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="task-node">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="task" />
+ <xs:group ref="node-content-elements" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="create-tasks" type="booleanType" default="true" />
+ <xs:attribute name="end-tasks" type="booleanType" default="false" />
+ <xs:attribute name="signal" default="last">
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="unsynchronized"/>
+ <xs:enumeration value="never"/>
+ <xs:enumeration value="first"/>
+ <xs:enumeration value="first-wait"/>
+ <xs:enumeration value="last"/>
+ <xs:enumeration value="last-wait"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:attribute>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="mail-node">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="subject" />
+ <xs:element ref="text" />
+ <xs:group ref="node-content-elements"/>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ <xs:attribute name="template" type="xs:string"/>
+ <xs:attribute name="actors" type="xs:string"/>
+ <xs:attribute name="to" type="xs:string"/>
+ <xs:attribute name="subject" type="xs:string"/>
+ <xs:attribute name="text" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+
+ <!-- TRANSITION -->
+ <!-- ########## -->
+ <xs:element name="transition">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element name="condition">
+ <xs:complexType mixed="true">
+ <xs:sequence minOccurs="0" maxOccurs="unbounded">
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="expression" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+ <xs:group ref="action-elements"/>
+ <xs:element ref="exception-handler" />
+ </xs:choice>
+ <xs:attribute name="to" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- ACTIONS -->
+ <!-- ####### -->
+ <xs:element name="action">
+ <xs:complexType mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="class" type="xs:string" />
+ <xs:attribute name="config-type" default="field" type="xs:string" />
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="ref-name" type="xs:string" />
+ <xs:attribute name="accept-propagated-events" type="booleanType" default="true" />
+ <xs:attribute name="expression" type="xs:string" />
+ <xs:attribute name="async" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="cancel-timer">
+ <xs:complexType>
+ <xs:attribute name="name" type="xs:string" use="required" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="create-timer">
+ <xs:complexType>
+ <xs:choice minOccurs="0">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="duedate" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="repeat" type="xs:string" />
+ <xs:attribute name="transition" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="script">
+ <xs:complexType mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="accept-propagated-events" type="booleanType" default="true" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="mail">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="subject" />
+ <xs:element ref="text" />
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="async" type="xs:string" default="false" />
+ <xs:attribute name="template" type="xs:string"/>
+ <xs:attribute name="actors" type="xs:string"/>
+ <xs:attribute name="to" type="xs:string"/>
+ <xs:attribute name="subject" type="xs:string"/>
+ <xs:attribute name="text" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- EVENT -->
+ <!-- ##### -->
+ <xs:element name="event">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:group ref="action-elements"/>
+ </xs:choice>
+ <xs:attribute name="type" use="required">
+ <xs:simpleType>
+ <xs:union>
+ <xs:simpleType>
+ <xs:restriction base="xs:string"/>
+ </xs:simpleType>
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="node-enter"/>
+ <xs:enumeration value="node-leave"/>
+ <xs:enumeration value="process-start"/>
+ <xs:enumeration value="process-end"/>
+ <xs:enumeration value="task-create"/>
+ <xs:enumeration value="task-assign"/>
+ <xs:enumeration value="task-start"/>
+ <xs:enumeration value="task-end"/>
+ <xs:enumeration value="before-signal"/>
+ <xs:enumeration value="after-signal"/>
+ <xs:enumeration value="superstate-enter"/>
+ <xs:enumeration value="superstate-leave"/>
+ <xs:enumeration value="timer-create"/>
+ <xs:enumeration value="subprocess-created"/>
+ <xs:enumeration value="subprocess-end"/>
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:union>
+ </xs:simpleType>
+ </xs:attribute>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- EXCEPTION-HANDLER -->
+ <!-- ################# -->
+ <xs:element name="exception-handler">
+ <xs:complexType>
+ <xs:choice minOccurs="1" maxOccurs="unbounded">
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ </xs:choice>
+ <xs:attribute name="exception-class" type="xs:string"/>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- TASK -->
+ <!-- #### -->
+ <xs:element name="task">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="unbounded">
+ <xs:element ref="description" />
+ <xs:element ref="assignment"/>
+ <xs:element ref="controller"/>
+ <xs:element ref="event"/>
+ <xs:element ref="timer"/>
+ <xs:element name="reminder">
+ <xs:complexType>
+ <xs:attribute name="duedate" type="xs:string" use="required" />
+ <xs:attribute name="repeat" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+ </xs:choice>
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="blocking" type="booleanType" default="false"/>
+ <xs:attribute name="signalling" type="booleanType" default="true"/>
+ <xs:attribute name="description" type="xs:string" />
+ <xs:attribute name="duedate" type="xs:string" />
+ <xs:attribute name="swimlane" type="xs:string" />
+ <xs:attribute name="priority" type="priorityType" default="normal" />
+ <xs:attribute name="notify" type="booleanType" default="false"/>
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="controller" type="delegation" />
+
+ <xs:element name="assignment">
+ <xs:complexType>
+ <xs:complexContent>
+ <xs:extension base="delegation">
+ <xs:attribute name="expression" type="xs:string" />
+ <xs:attribute name="actor-id" type="xs:string" />
+ <xs:attribute name="pooled-actors" type="xs:string" />
+ </xs:extension>
+ </xs:complexContent>
+ </xs:complexType>
+ </xs:element>
+
+ <!-- TIMER -->
+ <!-- ##### -->
+ <xs:element name="timer">
+ <xs:complexType>
+ <xs:choice minOccurs="0" maxOccurs="1">
+ <xs:group ref="action-elements" />
+ </xs:choice>
+ <xs:attribute name="duedate" type="xs:string" use="required" />
+ <xs:attribute name="name" type="xs:string" />
+ <xs:attribute name="repeat" type="xs:string" />
+ <xs:attribute name="transition" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <xs:element name="variable">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="name" type="xs:string" use="required"/>
+ <xs:attribute name="access" type="xs:string" default="read,write"/>
+ <xs:attribute name="mapped-name" type="xs:string" />
+ </xs:complexType>
+ </xs:element>
+
+ <!-- MAIL -->
+ <!-- #### -->
+ <xs:element name="to" type="xs:string"/>
+ <xs:element name="recipients" type="xs:string"/>
+ <xs:element name="subject" type="xs:string"/>
+ <xs:element name="text" type="xs:string"/>
+ <xs:element name="template" type="xs:string"/>
+
+ <!-- TYPES AND GROUPS -->
+ <!-- ################ -->
+
+ <xs:element name="description" type="xs:string" />
+
+ <xs:complexType name="delegation" mixed="true">
+ <xs:sequence>
+ <xs:any processContents="lax" minOccurs="0" maxOccurs="unbounded" />
+ </xs:sequence>
+ <xs:attribute name="class" type="xs:string" />
+ <xs:attribute name="config-type" default="field" type="xs:string" />
+ </xs:complexType>
+
+ <xs:simpleType name="configType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="field"/>
+ <xs:enumeration value="bean"/>
+ <xs:enumeration value="constructor"/>
+ <xs:enumeration value="configuration-property"/>
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="booleanType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="yes"/>
+ <xs:enumeration value="no"/>
+ <xs:enumeration value="true"/>
+ <xs:enumeration value="false"/>
+ <xs:enumeration value="on"/>
+ <xs:enumeration value="off"/>
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="priorityType">
+ <xs:union>
+ <xs:simpleType>
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="highest"/>
+ <xs:enumeration value="high"/>
+ <xs:enumeration value="normal"/>
+ <xs:enumeration value="low"/>
+ <xs:enumeration value="lowest"/>
+ </xs:restriction>
+ </xs:simpleType>
+ <xs:simpleType>
+ <xs:restriction base="xs:int"/>
+ </xs:simpleType>
+ </xs:union>
+ </xs:simpleType>
+
+ <xs:group name="node-elements">
+ <xs:choice>
+ <xs:element ref="node"/>
+ <xs:element ref="state"/>
+ <xs:element ref="task-node"/>
+ <xs:element ref="super-state"/>
+ <xs:element ref="process-state"/>
+ <xs:element ref="fork"/>
+ <xs:element ref="join"/>
+ <xs:element ref="decision"/>
+ <xs:element ref="end-state"/>
+ <xs:element ref="mail-node"/>
+ </xs:choice>
+ </xs:group>
+
+ <xs:group name="action-elements">
+ <xs:choice>
+ <xs:element ref="action"/>
+ <xs:element ref="script"/>
+ <xs:element ref="create-timer"/>
+ <xs:element ref="cancel-timer"/>
+ <xs:element ref="mail"/>
+ </xs:choice>
+ </xs:group>
+
+ <xs:group name="node-content-elements">
+ <xs:choice>
+ <xs:element ref="description" />
+ <xs:element ref="event"/>
+ <xs:element ref="exception-handler"/>
+ <xs:element ref="timer"/>
+ <xs:element ref="transition"/>
+ </xs:choice>
+ </xs:group>
+
+ <xs:simpleType name="bindingType">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="late"/>
+ <xs:enumeration value="early"/>
+ </xs:restriction>
+ </xs:simpleType>
+
+ <xs:simpleType name="lockMode">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="NONE"/>
+ <xs:enumeration value="READ"/>
+ <xs:enumeration value="UPGRADE"/>
+ <xs:enumeration value="UPGRADE_NOWAIT"/>
+ <xs:enumeration value="FORCE"/>
+ <xs:enumeration value="pessimistic"/>
+ </xs:restriction>
+ </xs:simpleType>
+</xs:schema>
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-3.3.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.0.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.0.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.0.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,1196 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<schema xmlns="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="http://jbpm.org/4.0/jpdl"
+ xmlns:tns="http://jbpm.org/4.0/jpdl"
+ elementFormDefault="qualified"
+ attributeFormDefault="unqualified">
+
+ <annotation>
+ <documentation>Schema for jPDL 4 process descriptions;
+ element process is the top level element.
+
+ TODO: Add activity pluggability. (add the proper any's and
+ anyAttributes)
+
+ TODO: Pull up expression. The expression element in the
+ delegation group can be pulled up as an expression
+ attribute in each use case of the delegationGroup
+
+ TODO: Investigate if object-refs to centrally defined objects would
+ add value over inline defined objects.
+ </documentation>
+ </annotation>
+
+ <!-- ### PROCESS DEFINITION ############################################# -->
+
+ <element name="process">
+ <annotation><documentation>A jPDL process definition description; This
+ is the top level element in a jPDL process file.</documentation></annotation>
+ <complexType>
+ <sequence minOccurs="0" maxOccurs="unbounded">
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element ref="tns:swimlane" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ <group ref="tns:activityGroup" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attribute name="name" use="required" type="string">
+ <annotation>
+ <documentation>
+ The process name. Multiple processes can be deployed with the same name, as long as they have a different
+ version.
+ </documentation>
+ </annotation>
+ </attribute>
+ <attribute name="key" type="string">
+ <annotation>
+ <documentation>
+ The key can be used to provide a short acronym that will replace the name as the basis for the generated
+ process definition id
+ </documentation>
+ </annotation>
+ </attribute>
+ <attribute name="version" type="int">
+ <annotation>
+ <documentation>
+ Indicates the sequence number of this version for all processes with the same name. By specifying a version
+ automatic deployment can figure out if this process is already deployed or not.
+ </documentation>
+ </annotation>
+ </attribute>
+ <anyAttribute processContents="skip">
+ <annotation><documentation>for extensibility
+ </documentation></annotation>
+ </anyAttribute>
+ </complexType>
+ </element>
+
+ <!-- ### ACTIVITIES ##################################################### -->
+
+ <group name="activityGroup">
+ <choice>
+ <!-- ~~~ START ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="start">
+ <annotation><documentation>Start event
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="form" type="string">
+ <annotation><documentation>the resource name of the form in the
+ deployment.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ END ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="end">
+ <annotation><documentation>End event.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution"/>
+ <enumeration value="process-instance"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ <attribute name="state" default="ended" type="string">
+ <annotation><documentation>sets the state of the execution explicitely</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="end-cancel">
+ <annotation><documentation>End cancel event.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution"/>
+ <enumeration value="process-instance"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="end-error">
+ <annotation><documentation>End cancel event.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution"/>
+ <enumeration value="process-instance"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ STATE ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="state">
+ <annotation><documentation>A wait state. When an execution arrives in this
+ activity, the execution will wait until an external trigger is received
+ with execution.signal() or execution.getActivityInstance().signal()
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ DECISION ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="decision">
+ <annotation><documentation>Decision gateway: selects one path out of many alternatives.
+ When an execution comes in, exactly one outgoing transition is taken.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="handler" minOccurs="0" type="tns:wireObjectType" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element name="condition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script text that will be evaluated.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ <!-- TODO add conditions -->
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script that will be evaluated and resolve to
+ the name of the outgoing transition.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use for the expr attribute.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ FORK ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="fork">
+ <annotation><documentation>Spawns multiple concurrent paths of
+ execution.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ JOIN ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="join">
+ <annotation><documentation>Spawns multiple concurrent paths of
+ execution.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="multiplicity" type="int" />
+ <attribute name="lockmode" default="upgrade">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="none"/>
+ <enumeration value="read"/>
+ <enumeration value="upgrade"/>
+ <enumeration value="upgrade_nowait"/>
+ <enumeration value="write"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ SCRIPT ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="script">
+ <annotation><documentation>Evaluates a piece of text as a script
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:scriptType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ HQL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="hql">
+ <annotation><documentation>Performs a hibernate query
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ SQL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="sql">
+ <annotation><documentation>Performs a hibernate SQL query
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ MAIL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="mail">
+ <annotation><documentation>Sends an email
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:mailType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ JAVA ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="java">
+ <annotation><documentation>Invokes a method on a java object.
+ Either the java class is instantiated with reflection, or the
+ java object is fetched from the environment. Then values from the
+ environment are injected into the fields and a method is executed.
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:javaType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ CUSTOM ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="custom">
+ <annotation><documentation>Uses a user defined, custom implementation of
+ ActivityBehaviour
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:wireObjectType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ TASK ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="task">
+ <annotation><documentation>Creates a task in the task component.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="assignment-handler" minOccurs="0" type="tns:wireObjectType" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="notification" minOccurs="0">
+ <complexType>
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ <attribute name="template" type="tns:templateType" use="optional" />
+ </complexType>
+ </element>
+ <element name="reminder" minOccurs="0">
+ <complexType>
+ <attribute name="duedate" type="string" />
+ <attribute name="repeat" type="string" />
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ <attribute name="template" type="tns:templateType" use="optional"/>
+ </complexType>
+ </element>
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attributeGroup ref="tns:assignmentAttributes"/>
+ <attribute name="swimlane" type="string" />
+ <attribute name="form" type="string">
+ <annotation><documentation>the resource name of the form in the
+ deployment.</documentation></annotation>
+ </attribute>
+ <attribute name="duedate" type="string" />
+ <attribute name="on-transition" default="cancel">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="keep"/>
+ <enumeration value="cancel"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ <attribute name="completion" type="string" default="complete" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ SUB-PROCESS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="sub-process">
+ <annotation><documentation>Waits while a sub process instance is
+ being executed and continues when the sub process instance ends.
+ </documentation></annotation>
+ <complexType>
+ <sequence minOccurs="0" maxOccurs="unbounded">
+ <element name="parameter-in" type="tns:parameterType" minOccurs="0" maxOccurs="unbounded" />
+ <element name="parameter-out" type="tns:parameterType" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Events on which listeners can be registered.</documentation></annotation>
+ </element>
+ <element name="swimlane-mapping" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="swimlane" type="string" use="required" />
+ <attribute name="sub-swimlane" type="string" use="required" />
+ </complexType>
+ </element>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence minOccurs="0" maxOccurs="unbounded">
+ <element name="outcome-value">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="sub-process-id" type="string">
+ <annotation><documentation>Identifies the sub process by the id. This means that a specific
+ version of a process definition is referenced
+ </documentation></annotation>
+ </attribute>
+ <attribute name="sub-process-key" type="string">
+ <annotation><documentation>Identifies the sub process by the key. This means that the latest
+ version of the process definition with the given key is referenced. The latest version
+ of the process is looked up each time the activity executes.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="outcome" type="string">
+ <annotation><documentation>Expression that is evaluated when the sub process
+ instance ends. The value is then used for outcome transition mapping.
+ </documentation></annotation>
+ </attribute>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ group ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="group">
+ <annotation><documentation>Scope enclosing a number of activities.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <group ref="tns:activityGroup" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Events on which listeners can be registered.</documentation></annotation>
+ </element>
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+ </choice>
+ </group>
+
+ <group name="wireObjectGroup">
+ <choice>
+ <!-- SPECIAL OBJECTS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+
+ <element name="null">
+ <annotation><documentation>the null value
+ </documentation></annotation>
+ </element>
+ <element name="ref">
+ <annotation><documentation>A reference to an object in the current environment</documentation></annotation>
+ <complexType>
+ <attribute name="object" type="string" use="required">
+ <annotation><documentation>The name of the referred object</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="env-ref">
+ <annotation><documentation>The current environment.
+ </documentation></annotation>
+ </element>
+ <element name="jndi">
+ <annotation><documentation>A lookup from JNDI through the InitialContext
+ </documentation></annotation>
+ <complexType>
+ <attribute name="jndi-name" type="string" use="required" />
+ </complexType>
+ </element>
+
+ <!-- COLLECTIONS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+
+ <element name="list">
+ <annotation><documentation>A java.util.List</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <group ref="tns:wireObjectGroup" />
+ </choice>
+ <attribute name="class" type="string" default="java.util.ArrayList">
+ <annotation><documentation>Implementation class for this list.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation><documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedList(List)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="map">
+ <annotation><documentation>A java.util.Map</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="entry">
+ <complexType>
+ <choice minOccurs="0">
+ <element name="key" minOccurs="0">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ <element name="value" minOccurs="0">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ </choice>
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="class" type="string" default="java.util.HashMap">
+ <annotation><documentation>Implementation class for this map.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation><documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedList(List)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="set">
+ <annotation><documentation>A java.util.Set
+ </documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <group ref="tns:wireObjectGroup" />
+ </choice>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="class" type="string" default="java.util.HashList">
+ <annotation><documentation>Implementation class for this set.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation><documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedSet(Set)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="properties">
+ <annotation><documentation>A java.util.Properties</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="property">
+ <complexType>
+ <attribute name="name" type="string" use="required" />
+ <attribute name="value" type="string" use="required" />
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="file" type="string">
+ <annotation><documentation>A file on the file system</documentation></annotation>
+ </attribute>
+ <attribute name="resource" type="string">
+ <annotation><documentation>A file as a resource in the classpath</documentation></annotation>
+ </attribute>
+ <attribute name="url" type="string">
+ <annotation><documentation>the contents is fetched by loading a url</documentation></annotation>
+ </attribute>
+ <attribute name="is-xml" type="tns:booleanValueType">
+ <annotation><documentation>optionally indicates if the content of referenced file in attributes
+ 'file', 'resource' or 'url' is XML. The default is the
+ plain properties format with a space or the equals character (=) separating key and value on
+ each line.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- OBJECT ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+
+ <element name="object" type="tns:wireObjectType" />
+
+ <!-- BASIC TYPES ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+
+ <element name="string">
+ <complexType>
+ <attribute name="name">
+ <annotation><documentation>the name of the string object</documentation></annotation>
+ </attribute>
+ <attribute name="value">
+ <annotation><documentation>the actual string value</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="byte">
+ <annotation><documentation>A java.lang.Byte</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="byte" use="required" />
+ </complexType>
+ </element>
+ <element name="char">
+ <annotation><documentation>A java.lang.Character</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" use="required">
+ <simpleType>
+ <restriction base="string">
+ <maxLength value="1" />
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="double">
+ <annotation><documentation>A java.lang.Double</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="double" use="required" />
+ </complexType>
+ </element>
+ <element name="false">
+ <annotation><documentation>java.lang.Boolean.FALSE
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="float">
+ <annotation><documentation>A java.lang.Float
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="float" use="required" />
+ </complexType>
+ </element>
+ <element name="int">
+ <annotation><documentation>A java.lang.Integer
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="int" use="required"/>
+ </complexType>
+ </element>
+ <element name="long">
+ <annotation><documentation>A java.lang.Long</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="long" use="required"/>
+ </complexType>
+ </element>
+ <element name="short">
+ <annotation><documentation>a java.lang.Short
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="short" use="required"/>
+ </complexType>
+ </element>
+ <element name="true">
+ <annotation><documentation>java.lang.Boolean.TRUE
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+
+ </choice>
+ </group>
+
+ <complexType name="wireObjectType">
+ <annotation><documentation>Any java object that will be created by reflection. .
+ <p>There are three main ways to create an object: by constructor or by a factory
+ object or a static factory method.</p>
+ <p><b>Using the constructor</b>: Then the <code>class</code> attribute must provide the
+ fully qualified class name. In case another constructor then the default is
+ targetted, a <code>constructor</code> child element can be provided.
+ The <code>factory</code> attribute should not be provided for using a constructor.
+ </p>
+ <p><b>Using a factory</b>: Then the <code>factory</code> attribute or one
+ <code>factory</code> element must be provided along with the attribute
+ <code>method</code>.
+ </p>
+ <p><b>Using a static factory method</b>: Then the <code>class</code> and
+ <code>method</code> attributes should be specified. There should be no
+ reference to a <code>factory</code> attribute of element.
+ </p>
+ <p><b>Construction and initialization</b>: all objects (constructor and factory)
+ are build in two phases: construction and initialisation phase. During construction
+ all is done until a pointer is obtained to the object. In initialisation, operations
+ are applied to the object until it is ready to be used. The separation between
+ construction and initialisation is made to allow for bidirectional references. In
+ that case, at least one of both ends can not be fully initialised before it is injected
+ into the other end.
+ </p>
+ <p><b>Operations</b>: after construction, various operations can be applied to objects
+ like e.g. direct field injection, injection through setters, method invocation,
+ enlist with the standard transaction, subscribe the object as a listener to an observable
+ </p>
+ <p><b>Arguments</b>: There are two different places for arguments. The <code>arg</code>
+ elements for the factory method invocation should be placed as child elements under the
+ <code>object</code> element. The <code>arg</code> elements for the constructor should be
+ placed as child elements under the <code>constructor</code> element.
+ </p>
+ </documentation></annotation>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="factory">
+ <annotation><documentation>Contains one element that describes the factory object.</documentation></annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ <element name="constructor">
+ <annotation><documentation>Specifies the arguments to use for a non-default constructor.</documentation></annotation>
+ <complexType>
+ <choice maxOccurs="unbounded">
+ <element name="arg" type="tns:argType" />
+ </choice>
+ </complexType>
+ </element>
+ <element name="arg" type="tns:argType">
+ <annotation><documentation>The factory method arguments.</documentation></annotation>
+ </element>
+ <element name="field">
+ <annotation><documentation>Injects a value into a member field of this object.
+ Exactly one child element must specify the value.
+ </documentation></annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ <attribute name="name">
+ <annotation><documentation>The member field name</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="property">
+ <annotation><documentation>Injects a value through a setter method.
+ Exactly one child element must specify the value.
+ </documentation></annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ <attribute name="name">
+ <annotation><documentation>The name of the property (without the 'set' prefix)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="invoke">
+ <annotation><documentation>Invokes a method</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="arg" type="tns:argType" />
+ </choice>
+ <attribute name="method" type="string" use="required">
+ <annotation><documentation>the method name</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="class" type="string">
+ <annotation><documentation>The fully qualified class name</documentation></annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The class to instantiate.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>The class to instantiate.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="factory" type="string">
+ <annotation><documentation>The name of the factory object</documentation></annotation>
+ </attribute>
+ <attribute name="method" type="string">
+ <annotation><documentation>The factory method name</documentation></annotation>
+ </attribute>
+ <attribute name="auto-wire" type="string">
+ <annotation><documentation>Indicates if the member fields and setter properties
+ should be automatically wired based on matching the property names and types with the
+ object names and types</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="argType">
+ <annotation><documentation>The method arguments.
+ Each 'arg' element should have exactly one child element
+ that represents the value of the argument.
+ </documentation></annotation>
+ <attribute name="type" type="string">
+ <annotation><documentation>The java class name representing
+ the type of the method. This is optional and can be used to
+ indicate the appropriate method in case of method overloading.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="javaType">
+ <sequence>
+ <element name="field" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Field injections from the environment
+ invocation.</documentation></annotation>
+ </element>
+ <element name="arg" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Method arguments.</documentation></annotation>
+ </element>
+ </sequence>
+ <attribute name="object" type="string">
+ <annotation><documentation>Name of the object in the environment
+ </documentation></annotation>
+ </attribute>
+ <attribute name="method" type="string" use="required">
+ <annotation><documentation>The name of the method to invoke.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="class" type="string">
+ <annotation><documentation>The class to instantiate.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation><documentation>Expression that resolves to the target object
+ on which the method should be invoked.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>The language in which attribute 'expr' is to be
+ resolved.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation><documentation>The variable name to store the return value
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="scriptType">
+ <sequence>
+ <element name="text" type="string" minOccurs="0">
+ <annotation><documentation>The content of this expression element
+ is the script text that will be evaluated. This is mutually
+ exclusive with the expression attribute.</documentation></annotation>
+ </element>
+ </sequence>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script text that will be evaluated. This
+ is mutually exclusive with the expression element.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use.</documentation></annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation><documentation>Name of the variable in which the result
+ of the script evaluation will be stored</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="qlType">
+ <sequence>
+ <element name="query" type="string">
+ <annotation><documentation>The query text.</documentation></annotation>
+ </element>
+ <element name="parameters" minOccurs="0">
+ <annotation><documentation>Query parameters.</documentation></annotation>
+ <complexType>
+ <sequence>
+ <group ref="tns:wireObjectGroup" maxOccurs="unbounded" />
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="var" type="string">
+ <annotation><documentation>Name of the variable in which the result
+ of the script evaluation will be stored</documentation></annotation>
+ </attribute>
+ <attribute name="unique" type="string">
+ <annotation><documentation>Does this query return a unique result or a list
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <attributeGroup name="activityAttributes">
+ <attribute name="name" type="string">
+ <annotation><documentation>The id of this activity. The name should be unique
+ in the complete scope of the process.</documentation></annotation>
+ </attribute>
+ <attribute name="g" type="string">
+ <annotation><documentation>Graphical information used by process designer tool.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="continue" default="sync" type="tns:continueType">
+ <annotation><documentation>To specify async continuations.
+ sync is the default.
+ </documentation></annotation>
+ </attribute>
+ </attributeGroup>
+
+ <simpleType name="continueType">
+ <restriction base="string">
+ <enumeration value="async" />
+ <enumeration value="sync" />
+ <enumeration value="exclusive" />
+ </restriction>
+ </simpleType>
+
+
+ <attributeGroup name="assignmentAttributes">
+ <annotation><documentation>the assignment attributes will be used in
+ tasks and swimlanes to specify to whom these respectively are assigned.
+ </documentation></annotation>
+ <attribute name="assignee" type="string">
+ <annotation><documentation>Expression that resolves to a userId referencing
+ the person to which the task or swimlane will be assigned.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="assignee-lang" type="string">
+ <annotation><documentation>Expression language for the assignee attribute.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="candidate-users" type="string">
+ <annotation><documentation>Expression that resolves to a comma separated
+ list of userId's. All the referred people will be candidates for
+ take the task or swimlane.</documentation></annotation>
+ </attribute>
+ <attribute name="candidate-users-lang" type="string">
+ <annotation><documentation>Expression language for the
+ candidate-users attribute.</documentation></annotation>
+ </attribute>
+ <attribute name="candidate-groups" type="string">
+ <annotation><documentation>Resolves to a comma separated list of groupId's.
+ All the referred people will be candidates to
+ take the task or swimlane.</documentation></annotation>
+ </attribute>
+ <attribute name="candidate-groups-lang" type="string">
+ <annotation><documentation>Expression language for the
+ candidate-groups attribute.</documentation></annotation>
+ </attribute>
+ </attributeGroup>
+
+ <element name="swimlane">
+ <annotation><documentation>A process role.</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string" use="required" />
+ <attributeGroup ref="tns:assignmentAttributes" />
+ </complexType>
+ </element>
+
+ <complexType name="transitionType">
+ <annotation><documentation>The outgoing transitions. The first in the list
+ will be the default outgoing transition.
+ </documentation></annotation>
+ <sequence>
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attribute name="name" type="string">
+ <annotation><documentation>Name of this outgoing transition</documentation></annotation>
+ </attribute>
+ <attribute name="to" type="string">
+ <annotation><documentation>Name of the destination activity of this transition.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="g" type="string">
+ <annotation><documentation>Graphical information used by process designer tool.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <element name="transition" type="tns:transitionType">
+ <annotation><documentation>A transition from one activity to another.</documentation></annotation>
+ </element>
+
+ <element name="on">
+ <complexType>
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>A list of event listeners that will
+ be notified when the event is fired</documentation></annotation>
+ </group>
+ </sequence>
+ <attribute name="event" type="string">
+ <annotation><documentation>The event identification. start, end, take or
+ any other custom event.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <complexType name="parameterType">
+ <attribute name="subvar" type="string">
+ <annotation><documentation>The name of the sub process variable.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation><documentation>An expression for which the resulting
+ value will be used as value.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Language of the expression.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation><documentation>Name of the process variable
+ in the super process execution..
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+
+ <element name="timer">
+ <complexType>
+ <sequence>
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>A list of event listeners that will
+ be notified when the timer fires</documentation></annotation>
+ </group>
+ </sequence>
+ <attribute name="duedate" type="string">
+ <annotation><documentation>Timer duedate expression that defines the duedate of this
+ timer relative to the creation time of the timer. E.g. '2 hours' or '4 business days'
+ </documentation></annotation>
+ </attribute>
+ <attribute name="repeat" type="string">
+ <annotation><documentation>Timer duedate expression that defines repeated scheduling
+ relative to the last timer fire event. E.g. '2 hours' or '4 business days'
+ </documentation></annotation>
+ </attribute>
+ <attribute name="duedatetime" type="string">
+ <annotation><documentation>Absolute time in format <code>HH:mm dd/MM/yyyy</code>
+ (see SimpleDateFormat). The format for the absolute time can be customized in the
+ jbpm configuration.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <group name="eventListenerGroup">
+ <choice>
+ <element name="event-listener" type="tns:wireObjectType" />
+ <element name="hql" type="tns:qlType" />
+ <element name="sql" type="tns:qlType" />
+ <element name="java" type="tns:javaType" />
+ <element name="script" type="tns:scriptType" />
+ <element name="mail" type="tns:mailType" />
+ </choice>
+ </group>
+
+ <complexType name="mailType">
+ <sequence>
+ <element name="from" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="to" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="cc" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="bcc" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="subject" type="string" minOccurs="0" />
+ <element name="text" type="string" minOccurs="0" />
+ <element name="html" type="string" minOccurs="0" />
+ <element name="attachments" minOccurs="0" >
+ <complexType>
+ <sequence>
+ <element name="attachment" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="url" type="string">
+ <annotation><documentation>URL reference to the attachment</documentation></annotation>
+ </attribute>
+ <attribute name="resource" type="string">
+ <annotation><documentation>Name of the attachment resource on the classpath</documentation></annotation>
+ </attribute>
+ <attribute name="file" type="string">
+ <annotation><documentation>File reference to the attachment</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="template" type="tns:templateType" />
+ </complexType>
+
+ <complexType name="mailRecipientType">
+ <attribute name="addresses" type="string">
+ <annotation><documentation>list of email address separated by ',' (comma) ';' (semicolon) '|' or whitespace</documentation></annotation>
+ </attribute>
+ <attribute name="users" type="string">
+ <annotation><documentation>list of user ids that are resolved to the email address against configured identity component.
+ user ids should be separated by ',' (comma) ';' (semicolon) '|' or whitespace</documentation></annotation>
+ </attribute>
+ <attribute name="groups" type="string">
+ <annotation><documentation>list of group ids that are resolved to the email address against configured identity component.
+ group ids should be separated by ',' (comma) ';' (semicolon) '|' or whitespace</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <simpleType name="booleanValueType">
+ <restriction base="string">
+ <enumeration value="true" />
+ <enumeration value="on" />
+ <enumeration value="enabled" />
+ <enumeration value="false" />
+ <enumeration value="off" />
+ <enumeration value="disabled" />
+ </restriction>
+ </simpleType>
+
+
+ <simpleType name="templateType">
+ <annotation><documentation>Reference to the email template</documentation></annotation>
+ <restriction base="string"></restriction>
+ </simpleType>
+</schema>
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.0.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.2.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.2.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.2.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,1241 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<schema xmlns="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="http://jbpm.org/4.2/jpdl"
+ xmlns:tns="http://jbpm.org/4.2/jpdl"
+ elementFormDefault="qualified"
+ attributeFormDefault="unqualified">
+
+ <annotation>
+ <documentation>Schema for jPDL 4 process descriptions;
+ element process is the top level element.
+ </documentation>
+ </annotation>
+
+ <!-- ### PROCESS DEFINITION ############################################# -->
+
+ <element name="process">
+ <annotation><documentation>A jPDL process definition description; This
+ is the top level element in a jPDL process file.</documentation></annotation>
+ <complexType>
+ <sequence minOccurs="0" maxOccurs="unbounded">
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:swimlane" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ <group ref="tns:activityGroup" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:migrate-instances" minOccurs="0" maxOccurs="1" />
+ </sequence>
+ <attribute name="name" use="required" type="string">
+ <annotation>
+ <documentation>
+ The process name. Multiple processes can be deployed with the same name, as long as they have a different
+ version.
+ </documentation>
+ </annotation>
+ </attribute>
+ <attribute name="key" type="string">
+ <annotation>
+ <documentation>
+ The key can be used to provide a short acronym that will replace the name as the basis for the generated
+ process definition id
+ </documentation>
+ </annotation>
+ </attribute>
+ <attribute name="version" type="int">
+ <annotation>
+ <documentation>
+ Indicates the sequence number of this version for all processes with the same name. By specifying a version
+ automatic deployment can figure out if this process is already deployed or not.
+ </documentation>
+ </annotation>
+ </attribute>
+ <anyAttribute processContents="skip">
+ <annotation><documentation>for extensibility
+ </documentation></annotation>
+ </anyAttribute>
+ </complexType>
+ </element>
+
+ <!-- ### ACTIVITIES ##################################################### -->
+
+ <group name="activityGroup">
+ <choice>
+ <!-- ~~~ START ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="start">
+ <annotation><documentation>Start event
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="form" type="string">
+ <annotation><documentation>the resource name of the form in the
+ deployment.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ END ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="end">
+ <annotation><documentation>End event.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution"/>
+ <enumeration value="process-instance"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ <attribute name="state" default="ended" type="string">
+ <annotation><documentation>sets the state of the execution explicitely</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="end-cancel">
+ <annotation><documentation>End cancel event.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution"/>
+ <enumeration value="process-instance"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="end-error">
+ <annotation><documentation>End cancel event.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution"/>
+ <enumeration value="process-instance"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ STATE ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="state">
+ <annotation><documentation>A wait state. When an execution arrives in this
+ activity, the execution will wait until an external trigger is received
+ with execution.signal() or execution.getActivityInstance().signal()
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ DECISION ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="decision">
+ <annotation><documentation>Decision gateway: selects one path out of many alternatives.
+ When an execution comes in, exactly one outgoing transition is taken.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="handler" minOccurs="0" type="tns:wireObjectType" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element name="condition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <sequence>
+ <element name="handler" minOccurs="0" type="tns:wireObjectType" />
+ </sequence>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script text that will be evaluated.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ <!-- TODO add conditions -->
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script that will be evaluated and resolve to
+ the name of the outgoing transition.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use for the expr attribute.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ FORK ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="fork">
+ <annotation><documentation>Spawns multiple concurrent paths of
+ execution.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ JOIN ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="join">
+ <annotation><documentation>Spawns multiple concurrent paths of
+ execution.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="multiplicity" type="int" />
+ <attribute name="lockmode" default="upgrade">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="none"/>
+ <enumeration value="read"/>
+ <enumeration value="upgrade"/>
+ <enumeration value="upgrade_nowait"/>
+ <enumeration value="write"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ SCRIPT ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="script">
+ <annotation><documentation>Evaluates a piece of text as a script
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:scriptType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ HQL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="hql">
+ <annotation><documentation>Performs a hibernate query
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ SQL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="sql">
+ <annotation><documentation>Performs a hibernate SQL query
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ MAIL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="mail">
+ <annotation><documentation>Sends an email
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:mailType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ JAVA ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="java">
+ <annotation><documentation>Invokes a method on a java object.
+ Either the java class is instantiated with reflection, or the
+ java object is fetched from the environment. Then values from the
+ environment are injected into the fields and a method is executed.
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:javaType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ CUSTOM ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="custom">
+ <annotation><documentation>Uses a user defined, custom implementation of
+ ActivityBehaviour
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:wireObjectType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ TASK ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="task">
+ <annotation><documentation>Creates a task in the task component.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="assignment-handler" minOccurs="0" type="tns:wireObjectType" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="notification" minOccurs="0">
+ <complexType>
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ <attribute name="template" type="tns:templateType" use="optional" />
+ </complexType>
+ </element>
+ <element name="reminder" minOccurs="0">
+ <complexType>
+ <attribute name="duedate" type="string" />
+ <attribute name="repeat" type="string" />
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ <attribute name="template" type="tns:templateType" use="optional"/>
+ </complexType>
+ </element>
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attributeGroup ref="tns:assignmentAttributes"/>
+ <attribute name="swimlane" type="string" />
+ <attribute name="form" type="string">
+ <annotation><documentation>the resource name of the form in the
+ deployment.</documentation></annotation>
+ </attribute>
+ <attribute name="duedate" type="string" />
+ <attribute name="on-transition" default="cancel">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="keep"/>
+ <enumeration value="cancel"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ <attribute name="completion" type="string" default="complete" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ SUB-PROCESS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="sub-process">
+ <annotation><documentation>Waits while a sub process instance is
+ being executed and continues when the sub process instance ends.
+ </documentation></annotation>
+ <complexType>
+ <sequence minOccurs="0" maxOccurs="unbounded">
+ <element name="description" minOccurs="0" type="string" />
+ <element name="parameter-in" type="tns:parameterType" minOccurs="0" maxOccurs="unbounded" />
+ <element name="parameter-out" type="tns:parameterType" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Events on which listeners can be registered.</documentation></annotation>
+ </element>
+ <element name="swimlane-mapping" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="swimlane" type="string" use="required" />
+ <attribute name="sub-swimlane" type="string" use="required" />
+ </complexType>
+ </element>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence minOccurs="0" maxOccurs="unbounded">
+ <element name="outcome-value">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="sub-process-id" type="string">
+ <annotation><documentation>Identifies the sub process by the id. This means that a specific
+ version of a process definition is referenced
+ </documentation></annotation>
+ </attribute>
+ <attribute name="sub-process-key" type="string">
+ <annotation><documentation>Identifies the sub process by the key. This means that the latest
+ version of the process definition with the given key is referenced. The latest version
+ of the process is looked up each time the activity executes.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="outcome" type="string">
+ <annotation><documentation>Expression that is evaluated when the sub process
+ instance ends. The value is then used for outcome transition mapping.
+ </documentation></annotation>
+ </attribute>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ group ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="group">
+ <annotation><documentation>Scope enclosing a number of activities.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <group ref="tns:activityGroup" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Events on which listeners can be registered.</documentation></annotation>
+ </element>
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+ </choice>
+ </group>
+
+ <group name="wireObjectGroup">
+ <choice>
+
+ <!-- SPECIAL OBJECTS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="null">
+ <annotation><documentation>the null value
+ </documentation></annotation>
+ </element>
+ <element name="ref">
+ <annotation><documentation>A reference to an object in the current environment</documentation></annotation>
+ <complexType>
+ <attribute name="object" type="string" use="required">
+ <annotation><documentation>The name of the referred object</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="env-ref">
+ <annotation><documentation>The current environment.
+ </documentation></annotation>
+ </element>
+ <element name="jndi">
+ <annotation><documentation>A lookup from JNDI through the InitialContext
+ </documentation></annotation>
+ <complexType>
+ <attribute name="jndi-name" type="string" use="required" />
+ </complexType>
+ </element>
+
+ <!-- COLLECTIONS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="list">
+ <annotation><documentation>A java.util.List</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <group ref="tns:wireObjectGroup" />
+ </choice>
+ <attribute name="class" type="string" default="java.util.ArrayList">
+ <annotation><documentation>Implementation class for this list.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation><documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedList(List)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="map">
+ <annotation><documentation>A java.util.Map</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="entry">
+ <complexType>
+ <choice minOccurs="0">
+ <element name="key" minOccurs="0">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ <element name="value" minOccurs="0">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ </choice>
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="class" type="string" default="java.util.HashMap">
+ <annotation><documentation>Implementation class for this map.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation><documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedList(List)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="set">
+ <annotation><documentation>A java.util.Set
+ </documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <group ref="tns:wireObjectGroup" />
+ </choice>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="class" type="string" default="java.util.HashList">
+ <annotation><documentation>Implementation class for this set.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation><documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedSet(Set)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="properties">
+ <annotation><documentation>A java.util.Properties</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="property">
+ <complexType>
+ <attribute name="name" type="string" use="required" />
+ <attribute name="value" type="string" use="required" />
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="file" type="string">
+ <annotation><documentation>A file on the file system</documentation></annotation>
+ </attribute>
+ <attribute name="resource" type="string">
+ <annotation><documentation>A file as a resource in the classpath</documentation></annotation>
+ </attribute>
+ <attribute name="url" type="string">
+ <annotation><documentation>the contents is fetched by loading a url</documentation></annotation>
+ </attribute>
+ <attribute name="is-xml" type="tns:booleanValueType">
+ <annotation><documentation>optionally indicates if the content of referenced file in attributes
+ 'file', 'resource' or 'url' is XML. The default is the
+ plain properties format with a space or the equals character (=) separating key and value on
+ each line.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- OBJECT ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="object" type="tns:wireObjectType" />
+
+ <!-- BASIC TYPES ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="string">
+ <complexType>
+ <attribute name="name">
+ <annotation><documentation>the name of the string object</documentation></annotation>
+ </attribute>
+ <attribute name="value">
+ <annotation><documentation>the actual string value</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="byte">
+ <annotation><documentation>A java.lang.Byte</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="byte" use="required" />
+ </complexType>
+ </element>
+ <element name="char">
+ <annotation><documentation>A java.lang.Character</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" use="required">
+ <simpleType>
+ <restriction base="string">
+ <maxLength value="1" />
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="double">
+ <annotation><documentation>A java.lang.Double</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="double" use="required" />
+ </complexType>
+ </element>
+ <element name="false">
+ <annotation><documentation>java.lang.Boolean.FALSE
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="float">
+ <annotation><documentation>A java.lang.Float
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="float" use="required" />
+ </complexType>
+ </element>
+ <element name="int">
+ <annotation><documentation>A java.lang.Integer
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="int" use="required"/>
+ </complexType>
+ </element>
+ <element name="long">
+ <annotation><documentation>A java.lang.Long</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="long" use="required"/>
+ </complexType>
+ </element>
+ <element name="short">
+ <annotation><documentation>a java.lang.Short
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="short" use="required"/>
+ </complexType>
+ </element>
+ <element name="true">
+ <annotation><documentation>java.lang.Boolean.TRUE
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+
+ </choice>
+ </group>
+
+ <complexType name="wireObjectType">
+ <annotation><documentation>Any java object that will be created by reflection. .
+ <p>There are three main ways to create an object: by constructor or by a factory
+ object or a static factory method.</p>
+ <p><b>Using the constructor</b>: Then the <code>class</code> attribute must provide the
+ fully qualified class name. In case another constructor then the default is
+ targetted, a <code>constructor</code> child element can be provided.
+ The <code>factory</code> attribute should not be provided for using a constructor.
+ </p>
+ <p><b>Using a factory</b>: Then the <code>factory</code> attribute or one
+ <code>factory</code> element must be provided along with the attribute
+ <code>method</code>.
+ </p>
+ <p><b>Using a static factory method</b>: Then the <code>class</code> and
+ <code>method</code> attributes should be specified. There should be no
+ reference to a <code>factory</code> attribute of element.
+ </p>
+ <p><b>Construction and initialization</b>: all objects (constructor and factory)
+ are build in two phases: construction and initialisation phase. During construction
+ all is done until a pointer is obtained to the object. In initialisation, operations
+ are applied to the object until it is ready to be used. The separation between
+ construction and initialisation is made to allow for bidirectional references. In
+ that case, at least one of both ends can not be fully initialised before it is injected
+ into the other end.
+ </p>
+ <p><b>Operations</b>: after construction, various operations can be applied to objects
+ like e.g. direct field injection, injection through setters, method invocation,
+ enlist with the standard transaction, subscribe the object as a listener to an observable
+ </p>
+ <p><b>Arguments</b>: There are two different places for arguments. The <code>arg</code>
+ elements for the factory method invocation should be placed as child elements under the
+ <code>object</code> element. The <code>arg</code> elements for the constructor should be
+ placed as child elements under the <code>constructor</code> element.
+ </p>
+ </documentation></annotation>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="factory">
+ <annotation><documentation>Contains one element that describes the factory object.</documentation></annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ <element name="constructor">
+ <annotation><documentation>Specifies the arguments to use for a non-default constructor.</documentation></annotation>
+ <complexType>
+ <choice maxOccurs="unbounded">
+ <element name="arg" type="tns:argType" />
+ </choice>
+ </complexType>
+ </element>
+ <element name="arg" type="tns:argType">
+ <annotation><documentation>The factory method arguments.</documentation></annotation>
+ </element>
+ <element name="field">
+ <annotation><documentation>Injects a value into a member field of this object.
+ Exactly one child element must specify the value.
+ </documentation></annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ <attribute name="name">
+ <annotation><documentation>The member field name</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="property">
+ <annotation><documentation>Injects a value through a setter method.
+ Exactly one child element must specify the value.
+ </documentation></annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ <attribute name="name">
+ <annotation><documentation>The name of the property (without the 'set' prefix)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="invoke">
+ <annotation><documentation>Invokes a method</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="arg" type="tns:argType" />
+ </choice>
+ <attribute name="method" type="string" use="required">
+ <annotation><documentation>the method name</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="class" type="string">
+ <annotation><documentation>The fully qualified class name</documentation></annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The class to instantiate.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>The class to instantiate.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="factory" type="string">
+ <annotation><documentation>The name of the factory object</documentation></annotation>
+ </attribute>
+ <attribute name="method" type="string">
+ <annotation><documentation>The factory method name</documentation></annotation>
+ </attribute>
+ <attribute name="auto-wire" type="string">
+ <annotation><documentation>Indicates if the member fields and setter properties
+ should be automatically wired based on matching the property names and types with the
+ object names and types</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="argType">
+ <annotation><documentation>The method arguments.
+ Each 'arg' element should have exactly one child element
+ that represents the value of the argument.
+ </documentation></annotation>
+ <attribute name="type" type="string">
+ <annotation><documentation>The java class name representing
+ the type of the method. This is optional and can be used to
+ indicate the appropriate method in case of method overloading.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="javaType">
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="field" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Field injections from the environment
+ invocation.</documentation></annotation>
+ </element>
+ <element name="arg" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Method arguments.</documentation></annotation>
+ </element>
+ </sequence>
+ <attribute name="method" type="string" use="required">
+ <annotation><documentation>The name of the method to invoke.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="class" type="string">
+ <annotation><documentation>The class to instantiate.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation><documentation>Expression that resolves to the target object
+ on which the method should be invoked.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>The language in which attribute 'expr' is to be
+ resolved.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation><documentation>The variable name to store the return value
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="scriptType">
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="text" type="string" minOccurs="0">
+ <annotation><documentation>The content of this expression element
+ is the script text that will be evaluated. This is mutually
+ exclusive with the expression attribute.</documentation></annotation>
+ </element>
+ </sequence>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script text that will be evaluated. This
+ is mutually exclusive with the expression element.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use.</documentation></annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation><documentation>Name of the variable in which the result
+ of the script evaluation will be stored</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="qlType">
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="query" type="string">
+ <annotation><documentation>The query text.</documentation></annotation>
+ </element>
+ <element name="parameters" minOccurs="0">
+ <annotation><documentation>Query parameters.</documentation></annotation>
+ <complexType>
+ <sequence>
+ <group ref="tns:wireObjectGroup" maxOccurs="unbounded" />
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="var" type="string">
+ <annotation><documentation>Name of the variable in which the result
+ of the script evaluation will be stored</documentation></annotation>
+ </attribute>
+ <attribute name="unique" type="string">
+ <annotation><documentation>Does this query return a unique result or a list
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <attributeGroup name="activityAttributes">
+ <attribute name="name" type="string">
+ <annotation><documentation>The id of this activity. The name should be unique
+ in the complete scope of the process.</documentation></annotation>
+ </attribute>
+ <attribute name="g" type="string">
+ <annotation><documentation>Graphical information used by process designer tool.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="continue" default="sync" type="tns:continueType">
+ <annotation><documentation>To specify async continuations.
+ sync is the default.
+ </documentation></annotation>
+ </attribute>
+ </attributeGroup>
+
+ <simpleType name="continueType">
+ <restriction base="string">
+ <enumeration value="async" />
+ <enumeration value="sync" />
+ <enumeration value="exclusive" />
+ </restriction>
+ </simpleType>
+
+
+ <attributeGroup name="assignmentAttributes">
+ <annotation><documentation>the assignment attributes will be used in
+ tasks and swimlanes to specify to whom these respectively are assigned.
+ </documentation></annotation>
+ <attribute name="assignee" type="string">
+ <annotation><documentation>Expression that resolves to a userId referencing
+ the person to which the task or swimlane will be assigned.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="assignee-lang" type="string">
+ <annotation><documentation>Expression language for the assignee attribute.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="candidate-users" type="string">
+ <annotation><documentation>Expression that resolves to a comma separated
+ list of userId's. All the referred people will be candidates for
+ take the task or swimlane.</documentation></annotation>
+ </attribute>
+ <attribute name="candidate-users-lang" type="string">
+ <annotation><documentation>Expression language for the
+ candidate-users attribute.</documentation></annotation>
+ </attribute>
+ <attribute name="candidate-groups" type="string">
+ <annotation><documentation>Resolves to a comma separated list of groupId's.
+ All the referred people will be candidates to
+ take the task or swimlane.</documentation></annotation>
+ </attribute>
+ <attribute name="candidate-groups-lang" type="string">
+ <annotation><documentation>Expression language for the
+ candidate-groups attribute.</documentation></annotation>
+ </attribute>
+ </attributeGroup>
+
+ <element name="swimlane">
+ <annotation><documentation>A process role.</documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ </sequence>
+ <attribute name="name" type="string" use="required" />
+ <attributeGroup ref="tns:assignmentAttributes" />
+ </complexType>
+ </element>
+
+ <complexType name="transitionType">
+ <annotation><documentation>The outgoing transitions. The first in the list
+ will be the default outgoing transition.
+ </documentation></annotation>
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attribute name="name" type="string">
+ <annotation><documentation>Name of this outgoing transition</documentation></annotation>
+ </attribute>
+ <attribute name="to" type="string">
+ <annotation><documentation>Name of the destination activity of this transition.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="g" type="string">
+ <annotation><documentation>Graphical information used by process designer tool.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <element name="transition" type="tns:transitionType">
+ <annotation><documentation>A transition from one activity to another.</documentation></annotation>
+ </element>
+
+ <element name="on">
+ <complexType>
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>A list of event listeners that will
+ be notified when the event is fired</documentation></annotation>
+ </group>
+ </sequence>
+ <attribute name="event" type="string">
+ <annotation><documentation>The event identification. start, end, take or
+ any other custom event.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ </complexType>
+ </element>
+
+ <complexType name="parameterType">
+ <attribute name="subvar" type="string">
+ <annotation><documentation>The name of the sub process variable.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation><documentation>An expression for which the resulting
+ value will be used as value.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Language of the expression.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation><documentation>Name of the process variable
+ in the super process execution..
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+
+ <element name="timer">
+ <complexType>
+ <sequence>
+ <annotation><documentation>A list of event listeners that will
+ be notified when the timer fires</documentation></annotation>
+ <element name="description" minOccurs="0" type="string" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded">
+ </group>
+ </sequence>
+ <attribute name="duedate" type="string">
+ <annotation><documentation>Timer duedate expression that defines the duedate of this
+ timer relative to the creation time of the timer. E.g. '2 hours' or '4 business days'
+ </documentation></annotation>
+ </attribute>
+ <attribute name="repeat" type="string">
+ <annotation><documentation>Timer duedate expression that defines repeated scheduling
+ relative to the last timer fire event. E.g. '2 hours' or '4 business days'
+ </documentation></annotation>
+ </attribute>
+ <attribute name="duedatetime" type="string">
+ <annotation><documentation>Absolute time in format <code>HH:mm dd/MM/yyyy</code>
+ (see SimpleDateFormat). The format for the absolute time can be customized in the
+ jbpm configuration.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <group name="eventListenerGroup">
+ <choice>
+ <element name="event-listener" type="tns:wireObjectType" />
+ <element name="hql" type="tns:qlType" />
+ <element name="sql" type="tns:qlType" />
+ <element name="java" type="tns:javaType" />
+ <element name="script" type="tns:scriptType" />
+ <element name="mail" type="tns:mailType" />
+ </choice>
+ </group>
+
+ <complexType name="mailType">
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="from" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="to" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="cc" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="bcc" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="subject" type="string" minOccurs="0" />
+ <element name="text" type="string" minOccurs="0" />
+ <element name="html" type="string" minOccurs="0" />
+ <element name="attachments" minOccurs="0" >
+ <complexType>
+ <sequence>
+ <element name="attachment" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="url" type="string">
+ <annotation><documentation>URL reference to the attachment</documentation></annotation>
+ </attribute>
+ <attribute name="resource" type="string">
+ <annotation><documentation>Name of the attachment resource on the classpath</documentation></annotation>
+ </attribute>
+ <attribute name="file" type="string">
+ <annotation><documentation>File reference to the attachment</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="template" type="tns:templateType" />
+ </complexType>
+
+ <complexType name="mailRecipientType">
+ <attribute name="addresses" type="string">
+ <annotation><documentation>list of email address separated by ',' (comma) ';' (semicolon) '|' or whitespace</documentation></annotation>
+ </attribute>
+ <attribute name="users" type="string">
+ <annotation><documentation>list of user ids that are resolved to the email address against configured identity component.
+ user ids should be separated by ',' (comma) ';' (semicolon) '|' or whitespace</documentation></annotation>
+ </attribute>
+ <attribute name="groups" type="string">
+ <annotation><documentation>list of group ids that are resolved to the email address against configured identity component.
+ group ids should be separated by ',' (comma) ';' (semicolon) '|' or whitespace</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <simpleType name="booleanValueType">
+ <restriction base="string">
+ <enumeration value="true" />
+ <enumeration value="on" />
+ <enumeration value="enabled" />
+ <enumeration value="false" />
+ <enumeration value="off" />
+ <enumeration value="disabled" />
+ </restriction>
+ </simpleType>
+
+
+ <simpleType name="templateType">
+ <annotation><documentation>Reference to the email template</documentation></annotation>
+ <restriction base="string"></restriction>
+ </simpleType>
+
+ <element name="migrate-instances">
+ <annotation><documentation>Information to migrate instances of previously deployed process definitions
+ to the new one</documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="migration-handler" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>The migration handler specifies the name of a class to be executed while migrating the process instance.</documentation></annotation>
+ <complexType>
+ <attribute name="class"/>
+ </complexType>
+ </element>
+ <element name="activity-mapping" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>One activity mapping will be present for each activity of which the name changed.</documentation></annotation>
+ <complexType>
+ <attribute name="old-name" type="string" use="required">
+ <annotation><documentation>The name of the activity in the previously deployed process definition.</documentation></annotation>
+ </attribute>
+ <attribute name="new-name" type="string" use="required">
+ <annotation><documentation>The name of the activity in the newly deployed process definition</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="action" type="tns:migrationActionType" default="migrate">
+ </attribute>
+ </complexType>
+ </element>
+
+ <simpleType name="migrationActionType">
+ <restriction base="string">
+ <enumeration value="end" />
+ <enumeration value="migrate" />
+ </restriction>
+ </simpleType>
+
+</schema>
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.2.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.3.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.3.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.3.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,1400 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<schema xmlns="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="http://jbpm.org/4.3/jpdl"
+ xmlns:tns="http://jbpm.org/4.3/jpdl"
+ elementFormDefault="qualified"
+ attributeFormDefault="unqualified">
+
+ <annotation>
+ <documentation>Schema for jPDL 4 process descriptions;
+ element process is the top level element.
+ </documentation>
+ </annotation>
+
+ <!-- ### PROCESS DEFINITION ############################################# -->
+
+ <element name="process">
+ <annotation><documentation>A jPDL process definition description; This
+ is the top level element in a jPDL process file.</documentation></annotation>
+ <complexType>
+ <sequence minOccurs="0" maxOccurs="unbounded">
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:swimlane" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ <group ref="tns:activityGroup" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:migrate-instances" minOccurs="0" maxOccurs="1" />
+ </sequence>
+ <attribute name="name" use="required" type="string">
+ <annotation>
+ <documentation>
+ The process name. Multiple processes can be deployed with the same name, as long as they have a different
+ version.
+ </documentation>
+ </annotation>
+ </attribute>
+ <attribute name="key" type="string">
+ <annotation>
+ <documentation>
+ The key can be used to provide a short acronym that will replace the name as the basis for the generated
+ process definition id
+ </documentation>
+ </annotation>
+ </attribute>
+ <attribute name="version" type="int">
+ <annotation>
+ <documentation>
+ Indicates the sequence number of this version for all processes with the same name. By specifying a version
+ automatic deployment can figure out if this process is already deployed or not.
+ </documentation>
+ </annotation>
+ </attribute>
+ <anyAttribute processContents="skip">
+ <annotation><documentation>for extensibility
+ </documentation></annotation>
+ </anyAttribute>
+ </complexType>
+ </element>
+
+ <!-- ### ACTIVITIES ##################################################### -->
+
+ <group name="activityGroup">
+ <choice>
+ <!-- ~~~ START ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="start">
+ <annotation><documentation>Start event
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="form" type="string">
+ <annotation><documentation>the resource name of the form in the
+ deployment.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ END ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="end">
+ <annotation><documentation>End event.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution"/>
+ <enumeration value="process-instance"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ <attribute name="state" default="ended" type="string">
+ <annotation><documentation>sets the state of the execution explicitely</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="end-cancel">
+ <annotation><documentation>End cancel event.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution"/>
+ <enumeration value="process-instance"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="end-error">
+ <annotation><documentation>End cancel event.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution"/>
+ <enumeration value="process-instance"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ STATE ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="state">
+ <annotation><documentation>A wait state. When an execution arrives in this
+ activity, the execution will wait until an external trigger is received
+ with execution.signal() or execution.getActivityInstance().signal()
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ DECISION ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="decision">
+ <annotation><documentation>Decision gateway: selects one path out of many alternatives.
+ When an execution comes in, exactly one outgoing transition is taken.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="handler" minOccurs="0" type="tns:wireObjectType" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element name="condition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <sequence>
+ <element name="handler" minOccurs="0" type="tns:wireObjectType" />
+ </sequence>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script text that will be evaluated.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script that will be evaluated and resolve to
+ the name of the outgoing transition.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use for the expr attribute.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ FORK ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="fork">
+ <annotation><documentation>Spawns multiple concurrent paths of
+ execution.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ JOIN ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="join">
+ <annotation><documentation>Spawns multiple concurrent paths of
+ execution.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="multiplicity" type="int" />
+ <attribute name="lockmode" default="upgrade">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="none"/>
+ <enumeration value="read"/>
+ <enumeration value="upgrade"/>
+ <enumeration value="upgrade_nowait"/>
+ <enumeration value="write"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ SCRIPT ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="script">
+ <annotation><documentation>Evaluates a piece of text as a script
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:scriptType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ HQL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="hql">
+ <annotation><documentation>Performs a hibernate query
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ SQL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="sql">
+ <annotation><documentation>Performs a hibernate SQL query
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ MAIL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="mail">
+ <annotation><documentation>Sends an email
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:mailType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ JMS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="jms">
+ <annotation><documentation>Sends an email
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:jmsType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ JAVA ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="java">
+ <annotation><documentation>Invokes a method on a java object.
+ Either the java class is instantiated with reflection, or the
+ java object is fetched from the environment. Then values from the
+ environment are injected into the fields and a method is executed.
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:javaType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ CUSTOM ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="custom">
+ <annotation><documentation>Uses a user defined, custom implementation of
+ ActivityBehaviour
+ </documentation></annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:wireObjectType">
+ <sequence>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ TASK ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="task">
+ <annotation><documentation>Creates a task in the task component.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="assignment-handler" minOccurs="0" type="tns:wireObjectType" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="notification" minOccurs="0">
+ <complexType>
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ <attribute name="template" type="tns:templateType" use="optional" />
+ </complexType>
+ </element>
+ <element name="reminder" minOccurs="0">
+ <complexType>
+ <attribute name="duedate" type="string" />
+ <attribute name="repeat" type="string" />
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ <attribute name="template" type="tns:templateType" use="optional"/>
+ </complexType>
+ </element>
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attributeGroup ref="tns:assignmentAttributes"/>
+ <attribute name="swimlane" type="string" />
+ <attribute name="form" type="string">
+ <annotation><documentation>the resource name of the form in the
+ deployment.</documentation></annotation>
+ </attribute>
+ <attribute name="duedate" type="string" />
+ <attribute name="on-transition" default="cancel">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="keep"/>
+ <enumeration value="cancel"/>
+ </restriction>
+ </simpleType>
+ </attribute>
+ <attribute name="completion" type="string" default="complete" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ SUB-PROCESS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="sub-process">
+ <annotation><documentation>Waits while a sub process instance is
+ being executed and continues when the sub process instance ends.
+ </documentation></annotation>
+ <complexType>
+ <sequence minOccurs="0" maxOccurs="unbounded">
+ <element name="description" minOccurs="0" type="string" />
+ <element name="parameter-in" type="tns:parameterType" minOccurs="0" maxOccurs="unbounded" />
+ <element name="parameter-out" type="tns:parameterType" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Events on which listeners can be registered.</documentation></annotation>
+ </element>
+ <element name="swimlane-mapping" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="swimlane" type="string" use="required" />
+ <attribute name="sub-swimlane" type="string" use="required" />
+ </complexType>
+ </element>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence minOccurs="0" maxOccurs="unbounded">
+ <element name="outcome-value">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="sub-process-id" type="string">
+ <annotation><documentation>Identifies the sub process by the id. This means that a specific
+ version of a process definition is referenced
+ </documentation></annotation>
+ </attribute>
+ <attribute name="sub-process-key" type="string">
+ <annotation><documentation>Identifies the sub process by the key. This means that the latest
+ version of the process definition with the given key is referenced. The latest version
+ of the process is looked up each time the activity executes.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="outcome" type="string">
+ <annotation><documentation>Expression that is evaluated when the sub process
+ instance ends. The value is then used for outcome transition mapping.
+ </documentation></annotation>
+ </attribute>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ GROUP ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="group">
+ <annotation><documentation>Scope enclosing a number of activities.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <group ref="tns:activityGroup" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Events on which listeners can be registered.</documentation></annotation>
+ </element>
+ <element ref="tns:timer" minOccurs="0" maxOccurs="unbounded"/>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ RULES DECISION ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="rules-decision">
+ <annotation><documentation>Selects one outgoing transition based on evaluation of rules.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:transition" minOccurs="0" maxOccurs="unbounded" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Events on which listeners can be registered.</documentation></annotation>
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ RULES ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="rules">
+ <annotation><documentation>Evaluates rules after feeding in some facts in a stateful knowledge session.
+ </documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="fact" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="var" type="string" />
+ <attribute name="expr" type="string" />
+ </complexType>
+ </element>
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element name="condition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <sequence>
+ <element name="handler" minOccurs="0" type="tns:wireObjectType" />
+ </sequence>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script text that will be evaluated.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Events on which listeners can be registered.</documentation></annotation>
+ </element>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ </choice>
+ </group>
+
+ <group name="wireObjectGroup">
+ <choice>
+
+ <!-- SPECIAL OBJECTS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="null">
+ <annotation><documentation>the null value
+ </documentation></annotation>
+ </element>
+ <element name="ref">
+ <annotation><documentation>A reference to an object in the current environment</documentation></annotation>
+ <complexType>
+ <attribute name="object" type="string" use="required">
+ <annotation><documentation>The name of the referred object</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="env-ref">
+ <annotation><documentation>The current environment.
+ </documentation></annotation>
+ </element>
+ <element name="jndi">
+ <annotation><documentation>A lookup from JNDI through the InitialContext
+ </documentation></annotation>
+ <complexType>
+ <attribute name="jndi-name" type="string" use="required" />
+ </complexType>
+ </element>
+
+ <!-- COLLECTIONS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="list">
+ <annotation><documentation>A java.util.List</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <group ref="tns:wireObjectGroup" />
+ </choice>
+ <attribute name="class" type="string" default="java.util.ArrayList">
+ <annotation><documentation>Implementation class for this list.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation><documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedList(List)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="map" type="tns:mapType"/>
+
+ <element name="set">
+ <annotation><documentation>A java.util.Set
+ </documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <group ref="tns:wireObjectGroup" />
+ </choice>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="class" type="string" default="java.util.HashList">
+ <annotation><documentation>Implementation class for this set.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation><documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedSet(Set)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="properties">
+ <annotation><documentation>A java.util.Properties</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="property">
+ <complexType>
+ <attribute name="name" type="string" use="required" />
+ <attribute name="value" type="string" use="required" />
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="file" type="string">
+ <annotation><documentation>A file on the file system</documentation></annotation>
+ </attribute>
+ <attribute name="resource" type="string">
+ <annotation><documentation>A file as a resource in the classpath</documentation></annotation>
+ </attribute>
+ <attribute name="url" type="string">
+ <annotation><documentation>the contents is fetched by loading a url</documentation></annotation>
+ </attribute>
+ <attribute name="is-xml" type="tns:booleanValueType">
+ <annotation><documentation>optionally indicates if the content of referenced file in attributes
+ 'file', 'resource' or 'url' is XML. The default is the
+ plain properties format with a space or the equals character (=) separating key and value on
+ each line.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- OBJECT ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="object" type="tns:wireObjectType" />
+
+ <!-- BASIC TYPES ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="string">
+ <complexType>
+ <attribute name="name">
+ <annotation><documentation>the name of the string object</documentation></annotation>
+ </attribute>
+ <attribute name="value">
+ <annotation><documentation>the actual string value</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="byte">
+ <annotation><documentation>A java.lang.Byte</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="byte" use="required" />
+ </complexType>
+ </element>
+ <element name="char">
+ <annotation><documentation>A java.lang.Character</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" use="required">
+ <simpleType>
+ <restriction base="string">
+ <maxLength value="1" />
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="double">
+ <annotation><documentation>A java.lang.Double</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="double" use="required" />
+ </complexType>
+ </element>
+ <element name="false">
+ <annotation><documentation>java.lang.Boolean.FALSE
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="float">
+ <annotation><documentation>A java.lang.Float
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="float" use="required" />
+ </complexType>
+ </element>
+ <element name="int">
+ <annotation><documentation>A java.lang.Integer
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="int" use="required"/>
+ </complexType>
+ </element>
+ <element name="long">
+ <annotation><documentation>A java.lang.Long</documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="long" use="required"/>
+ </complexType>
+ </element>
+ <element name="short">
+ <annotation><documentation>a java.lang.Short
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ <attribute name="value" type="short" use="required"/>
+ </complexType>
+ </element>
+ <element name="true">
+ <annotation><documentation>java.lang.Boolean.TRUE
+ </documentation></annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation><documentation>The name of the object. It's optional and serves
+ as an id to refer to this object from other object declarations. This name can
+ also be used lookup the object programmatically.</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+
+ </choice>
+ </group>
+
+ <complexType name="wireObjectType">
+ <annotation><documentation>Any java object that will be created by reflection. .
+ <p>There are three main ways to create an object: by constructor or by a factory
+ object or a static factory method.</p>
+ <p><b>Using the constructor</b>: Then the <code>class</code> attribute must provide the
+ fully qualified class name. In case another constructor then the default is
+ targetted, a <code>constructor</code> child element can be provided.
+ The <code>factory</code> attribute should not be provided for using a constructor.
+ </p>
+ <p><b>Using a factory</b>: Then the <code>factory</code> attribute or one
+ <code>factory</code> element must be provided along with the attribute
+ <code>method</code>.
+ </p>
+ <p><b>Using a static factory method</b>: Then the <code>class</code> and
+ <code>method</code> attributes should be specified. There should be no
+ reference to a <code>factory</code> attribute of element.
+ </p>
+ <p><b>Construction and initialization</b>: all objects (constructor and factory)
+ are build in two phases: construction and initialisation phase. During construction
+ all is done until a pointer is obtained to the object. In initialisation, operations
+ are applied to the object until it is ready to be used. The separation between
+ construction and initialisation is made to allow for bidirectional references. In
+ that case, at least one of both ends can not be fully initialised before it is injected
+ into the other end.
+ </p>
+ <p><b>Operations</b>: after construction, various operations can be applied to objects
+ like e.g. direct field injection, injection through setters, method invocation,
+ enlist with the standard transaction, subscribe the object as a listener to an observable
+ </p>
+ <p><b>Arguments</b>: There are two different places for arguments. The <code>arg</code>
+ elements for the factory method invocation should be placed as child elements under the
+ <code>object</code> element. The <code>arg</code> elements for the constructor should be
+ placed as child elements under the <code>constructor</code> element.
+ </p>
+ </documentation></annotation>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="factory">
+ <annotation><documentation>Contains one element that describes the factory object.</documentation></annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ <element name="constructor">
+ <annotation><documentation>Specifies the arguments to use for a non-default constructor.</documentation></annotation>
+ <complexType>
+ <choice maxOccurs="unbounded">
+ <element name="arg" type="tns:argType" />
+ </choice>
+ </complexType>
+ </element>
+ <element name="arg" type="tns:argType">
+ <annotation><documentation>The factory method arguments.</documentation></annotation>
+ </element>
+ <element name="field">
+ <annotation><documentation>Injects a value into a member field of this object.
+ Exactly one child element must specify the value.
+ </documentation></annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ <attribute name="name">
+ <annotation><documentation>The member field name</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="property">
+ <annotation><documentation>Injects a value through a setter method.
+ Exactly one child element must specify the value.
+ </documentation></annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ <attribute name="name">
+ <annotation><documentation>The name of the property (without the 'set' prefix)</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="invoke">
+ <annotation><documentation>Invokes a method</documentation></annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="arg" type="tns:argType" />
+ </choice>
+ <attribute name="method" type="string" use="required">
+ <annotation><documentation>the method name</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="class" type="string">
+ <annotation><documentation>The fully qualified class name</documentation></annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The class to instantiate.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>The class to instantiate.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="factory" type="string">
+ <annotation><documentation>The name of the factory object</documentation></annotation>
+ </attribute>
+ <attribute name="method" type="string">
+ <annotation><documentation>The factory method name</documentation></annotation>
+ </attribute>
+ <attribute name="auto-wire" type="string">
+ <annotation><documentation>Indicates if the member fields and setter properties
+ should be automatically wired based on matching the property names and types with the
+ object names and types</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="argType">
+ <annotation><documentation>The method arguments.
+ Each 'arg' element should have exactly one child element
+ that represents the value of the argument.
+ </documentation></annotation>
+ <attribute name="type" type="string">
+ <annotation><documentation>The java class name representing
+ the type of the method. This is optional and can be used to
+ indicate the appropriate method in case of method overloading.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="mapType">
+ <annotation><documentation>A java.util.Map</documentation></annotation>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="entry">
+ <complexType>
+ <sequence minOccurs="0">
+ <element name="key" minOccurs="0">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ <element name="value" minOccurs="0">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="class" type="string" default="java.util.HashMap">
+ <annotation><documentation>Implementation class for this map.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation><documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedList(List)</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="javaType">
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="field" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Field injections from the environment
+ invocation.</documentation></annotation>
+ </element>
+ <element name="arg" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>Method arguments.</documentation></annotation>
+ </element>
+ </sequence>
+ <attribute name="method" type="string" use="required">
+ <annotation><documentation>The name of the method to invoke.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="ejb-jndi-name" type="string">
+ <annotation><documentation>The jndi name of the ejb that needs to be invoked.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="class" type="string">
+ <annotation><documentation>The class to instantiate.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation><documentation>Expression that resolves to the target object
+ on which the method should be invoked.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>The language in which attribute 'expr' is to be
+ resolved.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation><documentation>The variable name to store the return value
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="scriptType">
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="text" type="string" minOccurs="0">
+ <annotation><documentation>The content of this expression element
+ is the script text that will be evaluated. This is mutually
+ exclusive with the expression attribute.</documentation></annotation>
+ </element>
+ </sequence>
+ <attribute name="expr" type="string">
+ <annotation><documentation>The script text that will be evaluated. This
+ is mutually exclusive with the expression element.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Identification of the scripting language
+ to use.</documentation></annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation><documentation>Name of the variable in which the result
+ of the script evaluation will be stored</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="qlType">
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="query" type="string">
+ <annotation><documentation>The query text.</documentation></annotation>
+ </element>
+ <element name="parameters" minOccurs="0">
+ <annotation><documentation>Query parameters.</documentation></annotation>
+ <complexType>
+ <sequence>
+ <group ref="tns:wireObjectGroup" maxOccurs="unbounded" />
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="var" type="string">
+ <annotation><documentation>Name of the variable in which the result
+ of the script evaluation will be stored</documentation></annotation>
+ </attribute>
+ <attribute name="unique" type="string">
+ <annotation><documentation>Does this query return a unique result or a list
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <attributeGroup name="activityAttributes">
+ <attribute name="name" type="string">
+ <annotation><documentation>The id of this activity. The name should be unique
+ in the complete scope of the process.</documentation></annotation>
+ </attribute>
+ <attribute name="g" type="string">
+ <annotation><documentation>Graphical information used by process designer tool.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="continue" default="sync" type="tns:continueType">
+ <annotation><documentation>To specify async continuations.
+ sync is the default.
+ </documentation></annotation>
+ </attribute>
+ </attributeGroup>
+
+ <simpleType name="continueType">
+ <restriction base="string">
+ <enumeration value="async" />
+ <enumeration value="sync" />
+ <enumeration value="exclusive" />
+ </restriction>
+ </simpleType>
+
+
+ <attributeGroup name="assignmentAttributes">
+ <annotation><documentation>the assignment attributes will be used in
+ tasks and swimlanes to specify to whom these respectively are assigned.
+ </documentation></annotation>
+ <attribute name="assignee" type="string">
+ <annotation><documentation>Expression that resolves to a userId referencing
+ the person to which the task or swimlane will be assigned.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="assignee-lang" type="string">
+ <annotation><documentation>Expression language for the assignee attribute.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="candidate-users" type="string">
+ <annotation><documentation>Expression that resolves to a comma separated
+ list of userId's. All the referred people will be candidates for
+ take the task or swimlane.</documentation></annotation>
+ </attribute>
+ <attribute name="candidate-users-lang" type="string">
+ <annotation><documentation>Expression language for the
+ candidate-users attribute.</documentation></annotation>
+ </attribute>
+ <attribute name="candidate-groups" type="string">
+ <annotation><documentation>Resolves to a comma separated list of groupId's.
+ All the referred people will be candidates to
+ take the task or swimlane.</documentation></annotation>
+ </attribute>
+ <attribute name="candidate-groups-lang" type="string">
+ <annotation><documentation>Expression language for the
+ candidate-groups attribute.</documentation></annotation>
+ </attribute>
+ </attributeGroup>
+
+ <element name="swimlane">
+ <annotation><documentation>A process role.</documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ </sequence>
+ <attribute name="name" type="string" use="required" />
+ <attributeGroup ref="tns:assignmentAttributes" />
+ </complexType>
+ </element>
+
+ <complexType name="transitionType">
+ <annotation><documentation>The outgoing transitions. The first in the list
+ will be the default outgoing transition.
+ </documentation></annotation>
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attribute name="name" type="string">
+ <annotation><documentation>Name of this outgoing transition</documentation></annotation>
+ </attribute>
+ <attribute name="to" type="string">
+ <annotation><documentation>Name of the destination activity of this transition.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="g" type="string">
+ <annotation><documentation>Graphical information used by process designer tool.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <element name="transition" type="tns:transitionType">
+ <annotation><documentation>A transition from one activity to another.</documentation></annotation>
+ </element>
+
+ <element name="on">
+ <complexType>
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>A list of event listeners that will
+ be notified when the event is fired</documentation></annotation>
+ </group>
+ </sequence>
+ <attribute name="event" type="string">
+ <annotation><documentation>The event identification. start, end, take or
+ any other custom event.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ </complexType>
+ </element>
+
+ <complexType name="parameterType">
+ <attribute name="subvar" type="string">
+ <annotation><documentation>The name of the sub process variable.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation><documentation>An expression for which the resulting
+ value will be used as value.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation><documentation>Language of the expression.
+ </documentation></annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation><documentation>Name of the process variable
+ in the super process execution..
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+
+
+ <element name="timer">
+ <complexType>
+ <sequence>
+ <annotation><documentation>A list of event listeners that will
+ be notified when the timer fires</documentation></annotation>
+ <element name="description" minOccurs="0" type="string" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded">
+ </group>
+ </sequence>
+ <attribute name="duedate" type="string">
+ <annotation><documentation>Timer duedate expression that defines the duedate of this
+ timer relative to the creation time of the timer. E.g. '2 hours' or '4 business days'
+ </documentation></annotation>
+ </attribute>
+ <attribute name="repeat" type="string">
+ <annotation><documentation>Timer duedate expression that defines repeated scheduling
+ relative to the last timer fire event. E.g. '2 hours' or '4 business days'
+ </documentation></annotation>
+ </attribute>
+ <attribute name="duedatetime" type="string">
+ <annotation><documentation>Absolute time in format <code>HH:mm dd/MM/yyyy</code>
+ (see SimpleDateFormat). The format for the absolute time can be customized in the
+ jbpm configuration.
+ </documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <group name="eventListenerGroup">
+ <choice>
+ <element name="event-listener">
+ <complexType>
+ <complexContent>
+ <extension base="tns:wireObjectType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="hql">
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="sql">
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="java">
+ <complexType>
+ <complexContent>
+ <extension base="tns:javaType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="script">
+ <complexType>
+ <complexContent>
+ <extension base="tns:scriptType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="mail">
+ <complexType>
+ <complexContent>
+ <extension base="tns:mailType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </choice>
+ </group>
+
+ <complexType name="mailType">
+ <sequence>
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="from" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="to" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="cc" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="bcc" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="subject" type="string" minOccurs="0" />
+ <element name="text" type="string" minOccurs="0" />
+ <element name="html" type="string" minOccurs="0" />
+ <element name="attachments" minOccurs="0" >
+ <complexType>
+ <sequence>
+ <element name="attachment" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="url" type="string">
+ <annotation><documentation>URL reference to the attachment</documentation></annotation>
+ </attribute>
+ <attribute name="resource" type="string">
+ <annotation><documentation>Name of the attachment resource on the classpath</documentation></annotation>
+ </attribute>
+ <attribute name="file" type="string">
+ <annotation><documentation>File reference to the attachment</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="template" type="tns:templateType" />
+ </complexType>
+
+ <complexType name="jmsType">
+ <choice minOccurs="1" maxOccurs="1">
+ <element name="object" type="tns:wireObjectType"/>
+ <element name="text" type="string"/>
+ <element name="map" type="tns:mapType"/>
+ </choice>
+ <attribute name="connection-factory" type="string">
+ <annotation><documentation>jndi name of the jms connection factory</documentation></annotation>
+ </attribute>
+ <attribute name="destination" type="string">
+ <annotation><documentation>jndi name of the destination to send the message to</documentation></annotation>
+ </attribute>
+ <attribute name="transacted" type="tns:booleanValueType" default="false">
+ <annotation><documentation>indicates whether the message should be sent in a transactional way</documentation></annotation>
+ </attribute>
+ <attribute name="acknowledge" type="tns:acknowledgeType" default="auto">
+ <annotation><documentation>indicates the acknowledgment mode</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="mailRecipientType">
+ <attribute name="addresses" type="string">
+ <annotation><documentation>list of email address separated by ',' (comma) ';' (semicolon) '|' or whitespace</documentation></annotation>
+ </attribute>
+ <attribute name="users" type="string">
+ <annotation><documentation>list of user ids that are resolved to the email address against configured identity component.
+ user ids should be separated by ',' (comma) ';' (semicolon) '|' or whitespace</documentation></annotation>
+ </attribute>
+ <attribute name="groups" type="string">
+ <annotation><documentation>list of group ids that are resolved to the email address against configured identity component.
+ group ids should be separated by ',' (comma) ';' (semicolon) '|' or whitespace</documentation></annotation>
+ </attribute>
+ </complexType>
+
+ <simpleType name="booleanValueType">
+ <restriction base="string">
+ <enumeration value="true" />
+ <enumeration value="on" />
+ <enumeration value="enabled" />
+ <enumeration value="false" />
+ <enumeration value="off" />
+ <enumeration value="disabled" />
+ </restriction>
+ </simpleType>
+
+ <simpleType name="acknowledgeType">
+ <restriction base="string">
+ <enumeration value="auto" />
+ <enumeration value="client" />
+ <enumeration value="dups-ok" />
+ </restriction>
+ </simpleType>
+
+
+ <simpleType name="templateType">
+ <annotation><documentation>Reference to the email template</documentation></annotation>
+ <restriction base="string"></restriction>
+ </simpleType>
+
+ <element name="migrate-instances">
+ <annotation><documentation>Information to migrate instances of previously deployed process definitions
+ to the new one</documentation></annotation>
+ <complexType>
+ <sequence>
+ <element name="migration-handler" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>The migration handler specifies the name of a class to be executed while migrating the process instance.</documentation></annotation>
+ <complexType>
+ <attribute name="class"/>
+ </complexType>
+ </element>
+ <element name="activity-mapping" minOccurs="0" maxOccurs="unbounded">
+ <annotation><documentation>One activity mapping will be present for each activity of which the name changed.</documentation></annotation>
+ <complexType>
+ <attribute name="old-name" type="string" use="required">
+ <annotation><documentation>The name of the activity in the previously deployed process definition.</documentation></annotation>
+ </attribute>
+ <attribute name="new-name" type="string" use="required">
+ <annotation><documentation>The name of the activity in the newly deployed process definition</documentation></annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="action" type="tns:migrationActionType" default="migrate">
+ </attribute>
+ </complexType>
+ </element>
+
+ <simpleType name="migrationActionType">
+ <restriction base="string">
+ <enumeration value="end" />
+ <enumeration value="migrate" />
+ </restriction>
+ </simpleType>
+
+</schema>
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.3.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.4.xsd
===================================================================
--- projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.4.xsd (rev 0)
+++ projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.4.xsd 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,1776 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://jbpm.org/4.4/jpdl"
+ xmlns:tns="http://jbpm.org/4.4/jpdl" elementFormDefault="qualified">
+ <annotation>
+ <documentation>Schema for jPDL 4 process descriptions;
+ the top level element is process.</documentation>
+ </annotation>
+
+ <!-- ### PROCESS DEFINITION ############################################# -->
+
+ <element name="process">
+ <annotation>
+ <documentation>jBPM Process Definition Language definition.
+ This is the top level element in a process definition file.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:swimlane" />
+ <element ref="tns:on" />
+ <element ref="tns:timer" />
+ <element ref="tns:variable" />
+ <group ref="tns:activityGroup" />
+ </choice>
+ <element ref="tns:migrate-instances" minOccurs="0" />
+ </sequence>
+ <attribute name="name" use="required" type="string">
+ <annotation>
+ <documentation>The process name. Multiple processes can be deployed with the same
+ name, as long as they have a different version.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="key" type="string">
+ <annotation>
+ <documentation>The key can be used to provide a short acronym that replaces the name
+ as the basis for the generated process definition id.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="version" type="int">
+ <annotation>
+ <documentation>Indicates the version number of this process definition among its
+ homonyms. By specifying a version, automatic deployment can tell whether this
+ process is already deployed.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ### ACTIVITIES ##################################################### -->
+
+ <group name="activityGroup">
+ <choice>
+ <!-- ~~~ START ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="start">
+ <annotation>
+ <documentation>Start event.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="form" type="string">
+ <annotation>
+ <documentation>Resource name of the form in the deployment.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ END ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="end">
+ <annotation>
+ <documentation>End event.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution" />
+ <enumeration value="process-instance" />
+ </restriction>
+ </simpleType>
+ </attribute>
+ <attribute name="state" default="ended" type="string">
+ <annotation>
+ <documentation>Specify the end state of the execution explicitly.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="end-cancel">
+ <annotation>
+ <documentation>End cancel event.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution" />
+ <enumeration value="process-instance" />
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="end-error">
+ <annotation>
+ <documentation>End cancel event.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="ends" default="process-instance">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="execution" />
+ <enumeration value="process-instance" />
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ STATE ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="state">
+ <annotation>
+ <documentation>Wait state. When an execution arrives in this activity,
+ the execution stops until an external trigger is delivered through
+ execution.signal() or execution.getActivityInstance().signal()</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element name="transition">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ DECISION ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="decision">
+ <annotation>
+ <documentation>Decision gateway: selects one path out of many alternatives.
+ When an execution arrives, it takes exactly one outgoing transition.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="handler" minOccurs="0" type="tns:wireObjectType" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" minOccurs="0" maxOccurs="unbounded" />
+ <element name="transition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element name="condition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="expr" type="string">
+ <annotation>
+ <documentation>Expression to evaluate.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation>
+ <documentation>Scripting language to interpret.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="expr" type="string">
+ <annotation>
+ <documentation>The script that will be evaluated and resolve to
+ the name of the outgoing transition.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation>
+ <documentation>Identification of the scripting language
+ to use for the expr attribute.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ FOREACH ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="foreach">
+ <annotation>
+ <documentation>Spawns concurrent paths of execution
+ over each element of a collection.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="var" type="string" use="required" />
+ <attribute name="in" type="string" use="required" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ FORK ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="fork">
+ <annotation>
+ <documentation>Spawns multiple concurrent paths of
+ execution.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ JOIN ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="join">
+ <annotation>
+ <documentation>Spawns multiple concurrent paths of
+ execution.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attribute name="multiplicity" type="string" />
+ <attribute name="lockmode" default="upgrade">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="none" />
+ <enumeration value="read" />
+ <enumeration value="upgrade" />
+ <enumeration value="upgrade_nowait" />
+ <enumeration value="write" />
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- ~~~ SCRIPT ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="script">
+ <annotation>
+ <documentation>Evaluates a piece of text as a script.</documentation>
+ </annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:scriptType">
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ HQL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="hql">
+ <annotation>
+ <documentation>Performs a Hibernate query.</documentation>
+ </annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ SQL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="sql">
+ <annotation>
+ <documentation>Performs a Hibernate SQL query.</documentation>
+ </annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ MAIL ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="mail">
+ <annotation>
+ <documentation>Sends an email.</documentation>
+ </annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:mailType">
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ JMS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="jms">
+ <annotation>
+ <documentation>Sends an email.</documentation>
+ </annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:jmsType">
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ JAVA ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="java">
+ <annotation>
+ <documentation>Invokes a method on a java object.
+ Either the java class is instantiated with reflection,
+ or the java object is fetched from the environment.
+ Values are then injected into the fields and.
+ Finally a method is invoked.</documentation>
+ </annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:javaType">
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ ASSIGN ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="assign">
+ <annotation>
+ <documentation>Assigns a source value to a target location.</documentation>
+ </annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:assignType">
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:transition" />
+ </choice>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ CUSTOM ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="custom">
+ <annotation>
+ <documentation>Calls a user defined, custom implementation of
+ ActivityBehaviour.</documentation>
+ </annotation>
+ <complexType>
+ <complexContent>
+ <extension base="tns:wireObjectType">
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element name="transition">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </choice>
+ <attributeGroup ref="tns:activityAttributes" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+
+ <!-- ~~~ TASK ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="task">
+ <annotation>
+ <documentation>Creates a task in the task component.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="assignment-handler" minOccurs="0" type="tns:wireObjectType" />
+ <element name="notification" minOccurs="0">
+ <complexType>
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ <attribute name="template" type="tns:templateType" use="optional" />
+ </complexType>
+ </element>
+ <element name="reminder" minOccurs="0">
+ <complexType>
+ <attribute name="duedate" type="string" />
+ <attribute name="repeat" type="string" />
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ <attribute name="template" type="tns:templateType" use="optional" />
+ </complexType>
+ </element>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:on" />
+ <element ref="tns:timer" />
+ <element name="transition">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ <attributeGroup ref="tns:assignmentAttributes" />
+ <attribute name="swimlane" type="string" />
+ <attribute name="form" type="string">
+ <annotation>
+ <documentation>Resource name of the form in the deployment.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="duedate" type="string" />
+ <attribute name="on-transition" default="cancel">
+ <simpleType>
+ <restriction base="string">
+ <enumeration value="keep" />
+ <enumeration value="cancel" />
+ </restriction>
+ </simpleType>
+ </attribute>
+ <attribute name="completion" type="string" default="complete" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ SUB-PROCESS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="sub-process">
+ <annotation>
+ <documentation>Waits while a sub process instance is being executed
+ and continues when the sub process instance ends.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="parameter-in" type="tns:parameterType" />
+ <element name="parameter-out" type="tns:parameterType" />
+ <element ref="tns:timer" />
+ <element ref="tns:on">
+ <annotation>
+ <documentation>Events on which listeners can be registered.</documentation>
+ </annotation>
+ </element>
+ <element name="swimlane-mapping">
+ <complexType>
+ <attribute name="swimlane" type="string" use="required" />
+ <attribute name="sub-swimlane" type="string" use="required" />
+ </complexType>
+ </element>
+ <element name="transition">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element name="outcome-value" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </choice>
+ </sequence>
+ <attribute name="sub-process-id" type="string">
+ <annotation>
+ <documentation>References a sub-process by id. This means that a specific
+ version of a process definition is referenced.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="sub-process-key" type="string">
+ <annotation>
+ <documentation>References a sub-process by key. Therefore, the latest
+ version of the process definition with the given key is referenced.
+ The latest version is resolved in each execution.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="outcome" type="string">
+ <annotation>
+ <documentation>Expression that is evaluated when the sub process instance ends.
+ The value is then used for outcome transition mapping.</documentation>
+ </annotation>
+ </attribute>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ GROUP ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="group">
+ <annotation>
+ <documentation>Scope enclosing a number of activities.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <group ref="tns:activityGroup" />
+ <element ref="tns:transition" />
+ <element ref="tns:on">
+ <annotation>
+ <documentation>Events on which listeners can be registered.</documentation>
+ </annotation>
+ </element>
+ <element ref="tns:timer" />
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ RULES DECISION ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="rules-decision">
+ <annotation>
+ <documentation>Selects one outgoing transition based on evaluation
+ of rules.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element ref="tns:transition" />
+ <element ref="tns:on">
+ <annotation>
+ <documentation>Events on which listeners can be registered.</documentation>
+ </annotation>
+ </element>
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+
+ <!-- ~~~ RULES ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="rules">
+ <annotation>
+ <documentation>Evaluates rules after feeding in some facts in a stateful
+ knowledge session.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="fact">
+ <complexType>
+ <attribute name="var" type="string" />
+ <attribute name="expr" type="string" />
+ </complexType>
+ </element>
+ <element name="transition">
+ <complexType>
+ <complexContent>
+ <extension base="tns:transitionType">
+ <sequence>
+ <element name="condition" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <sequence>
+ <element name="handler" minOccurs="0" type="tns:wireObjectType" />
+ </sequence>
+ <attribute name="expr" type="string">
+ <annotation>
+ <documentation>Expression to evaluate.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation>
+ <documentation>Script language to interpret.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element ref="tns:on">
+ <annotation>
+ <documentation>Events on which listeners can be registered.</documentation>
+ </annotation>
+ </element>
+ </choice>
+ </sequence>
+ <attributeGroup ref="tns:activityAttributes" />
+ </complexType>
+ </element>
+ </choice>
+ </group>
+
+ <group name="wireObjectGroup">
+ <choice>
+
+ <!-- SPECIAL OBJECTS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="null">
+ <annotation>
+ <documentation>The null value.</documentation>
+ </annotation>
+ </element>
+ <element name="ref">
+ <annotation>
+ <documentation>Reference to an object in the current environment.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="object" type="string" use="required">
+ <annotation>
+ <documentation>The name of the referred object.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="env-ref">
+ <annotation>
+ <documentation>The current environment.</documentation>
+ </annotation>
+ </element>
+ <element name="jndi">
+ <annotation>
+ <documentation>JNDI lookup based off the initial context.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="jndi-name" type="string" use="required" />
+ </complexType>
+ </element>
+
+ <!-- COLLECTIONS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="list">
+ <annotation>
+ <documentation>java.util.List instance.</documentation>
+ </annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <group ref="tns:wireObjectGroup" />
+ </choice>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="class" type="string" default="java.util.ArrayList">
+ <annotation>
+ <documentation>List implementation class.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation>
+ <documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedList()</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="map" type="tns:mapType" />
+
+ <element name="set">
+ <annotation>
+ <documentation>java.util.Set instance.</documentation>
+ </annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <group ref="tns:wireObjectGroup" />
+ </choice>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="class" type="string" default="java.util.HashList">
+ <annotation>
+ <documentation>Set implementation class.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation>
+ <documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedSet()</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="properties">
+ <annotation>
+ <documentation>java.util.Properties instance.</documentation>
+ </annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="property">
+ <complexType>
+ <attribute name="name" type="string" use="required" />
+ <attribute name="value" type="string" use="required" />
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="file" type="string">
+ <annotation>
+ <documentation>File in the file system.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="resource" type="string">
+ <annotation>
+ <documentation>Resource in the classpath.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="url" type="string">
+ <annotation>
+ <documentation>Resource in the web.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="is-xml" type="tns:booleanValueType">
+ <annotation>
+ <documentation>tells whether the resource referenced by
+ attributes 'file', 'resource' or 'url' is XML. The default is the
+ plain properties format, where a space or '=' separates the key
+ from the value in each line.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <!-- OBJECT ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="object" type="tns:wireObjectType" />
+
+ <!-- BASIC TYPES ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <element name="string">
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="value" />
+ </complexType>
+ </element>
+
+ <element name="byte">
+ <annotation>
+ <documentation>8-bit signed integer.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="value" type="byte" use="required" />
+ </complexType>
+ </element>
+ <element name="char">
+ <annotation>
+ <documentation>16-bit Unicode character.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="value" use="required">
+ <simpleType>
+ <restriction base="string">
+ <maxLength value="1" />
+ </restriction>
+ </simpleType>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="double">
+ <annotation>
+ <documentation>64-bit floating point number.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="value" type="double" use="required" />
+ </complexType>
+ </element>
+ <element name="false">
+ <annotation>
+ <documentation>Boolean false value</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="float">
+ <annotation>
+ <documentation>32-bit floating point number.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="value" type="float" use="required" />
+ </complexType>
+ </element>
+ <element name="int">
+ <annotation>
+ <documentation>32-bit signed integer.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="value" type="int" use="required" />
+ </complexType>
+ </element>
+ <element name="long">
+ <annotation>
+ <documentation>64-bit signed integer.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="value" type="long" use="required" />
+ </complexType>
+ </element>
+ <element name="short">
+ <annotation>
+ <documentation>16-bit signed integer.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="value" type="short" use="required" />
+ </complexType>
+ </element>
+ <element name="true">
+ <annotation>
+ <documentation>Boolean true value.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>The name of the object. Optional, serves as an identifier
+ to refer to this object from other object descriptions.
+ Also used to fetch the object programmatically.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </choice>
+ </group>
+
+ <complexType name="wireObjectType">
+ <annotation>
+ <documentation>Any java object that will be created by reflection.
+ <p>There are three main ways to create an object: by constructor or by a factory
+ object or a static factory method.</p>
+ <p><b>Using the constructor</b>: the <code>class</code> attribute must provide
+ the fully qualified class name. In case a constructor other than the default
+ should be invoked, a <code>constructor</code> child element can be provided.
+ The <code>factory</code> attribute should be absent when using a constructor.</p>
+ <p><b>Using a factory</b>: the <code>factory</code> attribute or one
+ <code>factory</code> element must be provided along with the attribute
+ <code>method</code>.</p>
+ <p><b>Using a static factory method</b>: the <code>class</code> and <code>method</code>
+ attributes should be specified. There should not be a <code>factory</code>
+ attribute or element.</p>
+ <p><b>Construction and initialization</b>: all objects (constructor and factory)
+ are build in two phases: construction and initialisation phase. During construction
+ all is done until a pointer is obtained to the object. In initialisation, operations
+ are applied to the object until it is ready to be used. The separation between
+ construction and initialisation is made to allow for bidirectional references.</p>
+ <p><b>Operations</b>: after construction, various operations can be applied to objects
+ like e.g. direct field injection, injection through setters, method invocation,
+ enlist with the standard transaction, subscribe the object to an observable.</p>
+ <p><b>Arguments</b>: there are two different places for arguments. The <code>arg</code>
+ elements for the factory method invocation should be placed as child elements under
+ the <code>object</code> element. The <code>arg</code> elements for the constructor
+ should be placed as child elements of the <code>constructor</code> element.</p>
+ </documentation>
+ </annotation>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="description" minOccurs="0" maxOccurs="unbounded" type="string" />
+ <element name="factory">
+ <annotation>
+ <documentation>Contains one element that describes the factory object.</documentation>
+ </annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ <element name="constructor">
+ <annotation>
+ <documentation>Specifies the arguments for a non-default constructor.</documentation>
+ </annotation>
+ <complexType>
+ <choice maxOccurs="unbounded">
+ <element name="arg" type="tns:argType" />
+ </choice>
+ </complexType>
+ </element>
+ <element name="arg" type="tns:argType">
+ <annotation>
+ <documentation>The factory method arguments.</documentation>
+ </annotation>
+ </element>
+ <element name="field">
+ <annotation>
+ <documentation>Injects a value into a member field of this object.
+ Exactly one child element must specify the value.</documentation>
+ </annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ <attribute name="name">
+ <annotation>
+ <documentation>Member field name.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="property">
+ <annotation>
+ <documentation>Injects a value through a setter method.
+ Exactly one child element must specify the value.</documentation>
+ </annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ <attribute name="name">
+ <annotation>
+ <documentation>Name of the property (without the 'set' prefix).</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ <element name="invoke">
+ <annotation>
+ <documentation>Invokes a method.</documentation>
+ </annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="arg" type="tns:argType" />
+ </choice>
+ <attribute name="method" type="string" use="required">
+ <annotation>
+ <documentation>Method name.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="class" type="string">
+ <annotation>
+ <documentation>Fully qualified class name</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation>
+ <documentation>Expression that provides the object.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation>
+ <documentation>Script language to interpret.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="factory" type="string">
+ <annotation>
+ <documentation>Name of the factory object.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="method" type="string">
+ <annotation>
+ <documentation>Factory method name</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="auto-wire" type="string">
+ <annotation>
+ <documentation>Indicates if the member fields and setter properties
+ should be wired automatically based on matching the property names and types
+ with the object names and types.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="cache" type="tns:booleanValueType">
+ <annotation>
+ <documentation>Indicates if the user code should be cached.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="argType">
+ <annotation>
+ <documentation>The method arguments.
+ Each 'arg' element should have exactly one child
+ element that represents the value of the argument.</documentation>
+ </annotation>
+ <group ref="tns:wireObjectGroup" />
+ <attribute name="type" type="string">
+ <annotation>
+ <documentation>Class name representing the method type.
+ Optional, helps resolve the appropriate method in case of overloading.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="mapType">
+ <annotation>
+ <documentation>java.util.Map instance.</documentation>
+ </annotation>
+ <sequence>
+ <element name="entry" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <sequence>
+ <element name="key" minOccurs="0">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ <element name="value" minOccurs="0">
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="class" type="string" default="java.util.HashMap">
+ <annotation>
+ <documentation>Map implementation class.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="synchronized" type="tns:booleanValueType" default="false">
+ <annotation>
+ <documentation>Indicates if this collection should be synchronized
+ with Collections.synchronizedCollection()</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="javaType">
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="field">
+ <annotation>
+ <documentation>Field injections from the environment invocation.</documentation>
+ </annotation>
+ </element>
+ <element name="arg">
+ <annotation>
+ <documentation>Method arguments.</documentation>
+ </annotation>
+ </element>
+ </choice>
+ </sequence>
+ <attribute name="method" type="string" use="required">
+ <annotation>
+ <documentation>The name of the method to invoke.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="ejb-jndi-name" type="string">
+ <annotation>
+ <documentation>The jndi name of the ejb that needs to be invoked.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="class" type="string">
+ <annotation>
+ <documentation>The class to instantiate.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation>
+ <documentation>Expression that resolves to the target object
+ on which the method should be invoked.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation>
+ <documentation>The language in which attribute 'expr' is to be
+ resolved.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation>
+ <documentation>The variable name to store the return value.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="scriptType">
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="text" type="string" minOccurs="0">
+ <annotation>
+ <documentation>The text content of this element is the script to evaluate.
+ This element and the expression attribute are mutually exclusive.</documentation>
+ </annotation>
+ </element>
+ </sequence>
+ <attribute name="expr" type="string">
+ <annotation>
+ <documentation>The value of this attribute is the script to evaluate.
+ This attribute and the text element are mutually exclusive.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation>
+ <documentation>Identifies the scripting language in use.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation>
+ <documentation>Name of the variable in which the result
+ of the script evaluation will be stored.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="assignType">
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="from" minOccurs="0">
+ <annotation>
+ <documentation>Descriptor that constructs the source value.</documentation>
+ </annotation>
+ <complexType>
+ <group ref="tns:wireObjectGroup" />
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="from-expr" type="string">
+ <annotation>
+ <documentation>Expression that resolves the source value.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation>
+ <documentation>Language in which from-expr is written.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="from-var" type="string">
+ <annotation>
+ <documentation>Variable that provides the source value.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="to-expr" type="string">
+ <annotation>
+ <documentation>Expression that resolves the target location.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="to-var" type="string">
+ <annotation>
+ <documentation>Variable that provides the target location.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="qlType">
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <element name="query" type="string">
+ <annotation>
+ <documentation>Query text.</documentation>
+ </annotation>
+ </element>
+ <element name="parameters" minOccurs="0">
+ <annotation>
+ <documentation>Query parameters.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <group ref="tns:wireObjectGroup" maxOccurs="unbounded" />
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="var" type="string">
+ <annotation>
+ <documentation>Name of the variable in which the result
+ of the script evaluation will be stored.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="unique" type="string">
+ <annotation>
+ <documentation>Tells whether the query returns a unique result.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <attributeGroup name="activityAttributes">
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>Name of this activity. The name should be unique
+ in the complete scope of the process.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="g" type="string">
+ <annotation>
+ <documentation>Graphical information used by process designer tool.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="continue" default="sync" type="tns:continueType">
+ <annotation>
+ <documentation>Specifies async continuation.</documentation>
+ </annotation>
+ </attribute>
+ </attributeGroup>
+
+ <simpleType name="continueType">
+ <restriction base="string">
+ <enumeration value="async" />
+ <enumeration value="sync" />
+ <enumeration value="exclusive" />
+ </restriction>
+ </simpleType>
+
+ <attributeGroup name="assignmentAttributes">
+ <annotation>
+ <documentation>The assignment attributes are used in
+ tasks and swimlanes to specify who is the assignee.
+ </documentation>
+ </annotation>
+ <attribute name="assignee" type="string">
+ <annotation>
+ <documentation>Expression that resolves to a userId referencing
+ the person to whom the task or swimlane will be assigned.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="assignee-lang" type="string">
+ <annotation>
+ <documentation>Expression language for the assignee attribute.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="candidate-users" type="string">
+ <annotation>
+ <documentation>Expression that resolves to a comma separated
+ list of userIds. All the referred people will be candidates for
+ take the task or swimlane.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="candidate-users-lang" type="string">
+ <annotation>
+ <documentation>Expression language for the
+ candidate-users attribute.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="candidate-groups" type="string">
+ <annotation>
+ <documentation>Resolves to a comma separated list of groupIds.
+ All the referred people will be candidates to
+ take the task or swimlane.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="candidate-groups-lang" type="string">
+ <annotation>
+ <documentation>Expression language for the
+ candidate-groups attribute.</documentation>
+ </annotation>
+ </attribute>
+ </attributeGroup>
+
+ <element name="swimlane">
+ <annotation>
+ <documentation>Process role.</documentation>
+ </annotation>
+ <complexType>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ </sequence>
+ <attribute name="name" type="string" use="required" />
+ <attributeGroup ref="tns:assignmentAttributes" />
+ </complexType>
+ </element>
+
+ <complexType name="transitionType">
+ <annotation>
+ <documentation>The outgoing transitions. The first in the list
+ will be the default outgoing transition.</documentation>
+ </annotation>
+ <sequence>
+ <element name="description" minOccurs="0" type="string" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>Name of this outgoing transition</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="to" type="string">
+ <annotation>
+ <documentation>Name of the destination activity of this transition.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="g" type="string">
+ <annotation>
+ <documentation>Graphical information used by process designer tool.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <element name="transition" type="tns:transitionType">
+ <annotation>
+ <documentation>Link from one activity to another.</documentation>
+ </annotation>
+ </element>
+
+ <element name="on">
+ <complexType>
+ <sequence>
+ <element ref="tns:timer" minOccurs="0" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded">
+ <annotation>
+ <documentation>List of event listeners that will
+ be notified when the event is fired</documentation>
+ </annotation>
+ </group>
+ </sequence>
+ <attribute name="event" type="string">
+ <annotation>
+ <documentation>Event identification. start, end, take or
+ any other custom event.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="continue" type="tns:continueType" default="sync" />
+ </complexType>
+ </element>
+
+ <complexType name="parameterType">
+ <attribute name="subvar" type="string">
+ <annotation>
+ <documentation>Name of the sub process variable.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="expr" type="string">
+ <annotation>
+ <documentation>Expression that provides the variable value.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="lang" type="string">
+ <annotation>
+ <documentation>Language of the expression.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="var" type="string">
+ <annotation>
+ <documentation>Name of the process variable
+ in the super process.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <element name="timer">
+ <complexType>
+ <sequence>
+ <annotation>
+ <documentation>List of event listeners that will
+ be notified when the timer fires.</documentation>
+ </annotation>
+ <element name="description" minOccurs="0" type="string" />
+ <group ref="tns:eventListenerGroup" minOccurs="0" maxOccurs="unbounded" />
+ </sequence>
+ <attribute name="duedate" type="string">
+ <annotation>
+ <documentation>Timer duedate expression that defines the duedate of this
+ timer relative to the creation time of the timer.
+ E.g. '2 hours' or '4 business days'.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="repeat" type="string">
+ <annotation>
+ <documentation>Timer duedate expression that defines repeated scheduling
+ relative to the last timer fire event.
+ E.g. '2 hours' or '4 business days'</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="duedatetime" type="string">
+ <annotation>
+ <documentation>Absolute time in the format <code>HH:mm dd/MM/yyyy</code>.
+ The format can be customized in the configuration.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+
+ <element name="variable">
+ <complexType>
+ <annotation>
+ <documentation>Explicit variable declaration.</documentation>
+ </annotation>
+ <sequence>
+ <group ref="tns:wireObjectGroup" minOccurs="0" />
+ </sequence>
+ <attribute name="name" type="string">
+ <annotation>
+ <documentation>Name of the variable. Must differ from other variable
+ names.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="type" type="string">
+ <annotation>
+ <documentation>Type of the variable.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="init-expr" type="string">
+ <annotation>
+ <documentation></documentation>
+ </annotation>
+ </attribute>
+ <attribute name="history" type="tns:booleanValueType" />
+ </complexType>
+ </element>
+
+ <group name="eventListenerGroup">
+ <choice>
+ <element name="event-listener">
+ <complexType>
+ <complexContent>
+ <extension base="tns:wireObjectType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="hql">
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="sql">
+ <complexType>
+ <complexContent>
+ <extension base="tns:qlType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="java">
+ <complexType>
+ <complexContent>
+ <extension base="tns:javaType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="assign">
+ <complexType>
+ <complexContent>
+ <extension base="tns:assignType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="script">
+ <complexType>
+ <complexContent>
+ <extension base="tns:scriptType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ <element name="mail">
+ <complexType>
+ <complexContent>
+ <extension base="tns:mailType">
+ <attribute name="propagation" type="tns:booleanValueType" />
+ </extension>
+ </complexContent>
+ </complexType>
+ </element>
+ </choice>
+ </group>
+
+ <complexType name="mailType">
+ <complexContent>
+ <extension base="tns:wireObjectType">
+ <sequence>
+ <element name="from" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="to" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="cc" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="bcc" type="tns:mailRecipientType" minOccurs="0" />
+ <element name="subject" type="string" minOccurs="0" />
+ <element name="text" type="string" minOccurs="0" />
+ <element name="html" type="string" minOccurs="0" />
+ <element name="attachments" minOccurs="0">
+ <complexType>
+ <sequence>
+ <element name="attachment" maxOccurs="unbounded">
+ <complexType>
+ <attribute name="url" type="string">
+ <annotation>
+ <documentation>Resource in the web.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="resource" type="string">
+ <annotation>
+ <documentation>Resource in the classpath.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="file" type="string">
+ <annotation>
+ <documentation>Path in the file system.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ <attribute name="template" type="tns:templateType" />
+ </extension>
+ </complexContent>
+ </complexType>
+
+ <complexType name="jmsType">
+ <choice minOccurs="1" maxOccurs="1">
+ <element name="object" type="tns:wireObjectType" />
+ <element name="text" type="string" />
+ <element name="map" type="tns:mapType" />
+ </choice>
+ <attribute name="connection-factory" type="string">
+ <annotation>
+ <documentation>JNDI name of the connection factory.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="destination" type="string">
+ <annotation>
+ <documentation>JNDI name of the destination.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="transacted" type="tns:booleanValueType" default="false">
+ <annotation>
+ <documentation>Tells whether the message should be sent in a transaction.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="acknowledge" type="tns:acknowledgeType" default="auto">
+ <annotation>
+ <documentation>Indicates the acknowledgment mode.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <complexType name="mailRecipientType">
+ <attribute name="addresses" type="string">
+ <annotation>
+ <documentation>List of email addresses separated by ',' (comma)
+ or whitespace.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="users" type="string">
+ <annotation>
+ <documentation>List of users, resolved to email addresses thought
+ the configured identity component. Users are separated by ',' (comma)
+ ';' (semicolon) or whitespace.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="groups" type="string">
+ <annotation>
+ <documentation>List of groups, that are resolved to the email address against
+ configured identity component. Groups are separated by ',' (comma)
+ ';' (semicolon) or whitespace</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+
+ <simpleType name="booleanValueType">
+ <restriction base="string">
+ <enumeration value="true" />
+ <enumeration value="on" />
+ <enumeration value="enabled" />
+ <enumeration value="false" />
+ <enumeration value="off" />
+ <enumeration value="disabled" />
+ </restriction>
+ </simpleType>
+
+ <simpleType name="acknowledgeType">
+ <restriction base="string">
+ <enumeration value="auto" />
+ <enumeration value="client" />
+ <enumeration value="dups-ok" />
+ </restriction>
+ </simpleType>
+
+ <simpleType name="templateType">
+ <annotation>
+ <documentation>Reference to the email template.</documentation>
+ </annotation>
+ <restriction base="string" />
+ </simpleType>
+
+ <element name="migrate-instances">
+ <annotation>
+ <documentation>Information to migrate instances of previously deployed
+ process definitions to the new version.</documentation>
+ </annotation>
+ <complexType>
+ <choice minOccurs="0" maxOccurs="unbounded">
+ <element name="migration-handler">
+ <annotation>
+ <documentation>The migration handler specifies the name of a class to be executed
+ while migrating the process instance.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="class" />
+ </complexType>
+ </element>
+ <element name="activity-mapping">
+ <annotation>
+ <documentation>One activity mapping will be present for each activity of which the
+ name changed.</documentation>
+ </annotation>
+ <complexType>
+ <attribute name="old-name" type="string" use="required">
+ <annotation>
+ <documentation>Name of the activity in the previously deployed
+ process definition.</documentation>
+ </annotation>
+ </attribute>
+ <attribute name="new-name" type="string" use="required">
+ <annotation>
+ <documentation>Name of the activity in the newly deployed
+ process definition.</documentation>
+ </annotation>
+ </attribute>
+ </complexType>
+ </element>
+ </choice>
+ <attribute name="action" type="tns:migrationActionType" default="migrate" />
+ </complexType>
+ </element>
+
+ <simpleType name="migrationActionType">
+ <restriction base="string">
+ <enumeration value="end" />
+ <enumeration value="migrate" />
+ </restriction>
+ </simpleType>
+</schema>
Property changes on: projects/migration_tool/trunk/src/main/resources/Schemas/jPDL/jpdl-4.4.xsd
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/main/xslt/migrate.xslt
===================================================================
--- projects/migration_tool/trunk/src/main/xslt/migrate.xslt (rev 0)
+++ projects/migration_tool/trunk/src/main/xslt/migrate.xslt 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet version="2.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:jpdl="http://jbpm.org/4.3/jpdl">
+
+<!-- Converts a jPDL4.3 file to a BPMN2 file-->
+<xsl:output method="xml" indent="yes" />
+
+<xsl:template match="/">
+ <definitions id="Definition"
+ targetNamespace="http://www.jboss.org/drools"
+ typeLanguage="http://www.java.com/javaTypes"
+ expressionLanguage="http://www.mvel.org/2.0"
+ xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema-instance"
+ xs:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd"
+ xmlns:g="http://www.jboss.org/drools/flow/gpd"
+ xmlns:tns="http://www.jboss.org/drools">
+
+ <xsl:apply-templates select="jpdl:process"/>
+
+ </definitions>
+</xsl:template>
+
+
+
+</xsl:stylesheet>
\ No newline at end of file
Property changes on: projects/migration_tool/trunk/src/main/xslt/migrate.xslt
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/test/java/test/XSLTTest.java
===================================================================
--- projects/migration_tool/trunk/src/test/java/test/XSLTTest.java (rev 0)
+++ projects/migration_tool/trunk/src/test/java/test/XSLTTest.java 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,106 @@
+package test;
+
+import static java.lang.System.out;
+import static org.junit.Assert.*;
+import static org.junit.Assert.fail;
+
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URL;
+
+import javax.swing.Box.Filler;
+import javax.xml.transform.Templates;
+import javax.xml.transform.Transformer;
+import javax.xml.transform.TransformerConfigurationException;
+import javax.xml.transform.TransformerException;
+import javax.xml.transform.TransformerFactory;
+import javax.xml.transform.stream.StreamResult;
+import javax.xml.transform.stream.StreamSource;
+
+import org.junit.Before;
+import org.junit.Test;
+
+public class XSLTTest {
+
+ public static final String useCasesDir = "use_cases";
+
+ public static final String singleForkJoinJpdl = "single_fork_join_jpdl";
+ public static final String singleDecisionJpdl = "single_decision_jpdl";
+ public static final String singleNodeJpdl = "single_node_jpdl";
+ public static final String singleStateJpdl = "single_state_jpdl";
+ public static final String singleSubprocessJpdl = "single_subprocess_jpdl";
+ public static final String singleTaskJpdl = "single_task_jpdl";
+
+ public static final String procDefXML = "processdefinition.xml";
+ public static final String bpmnDefXML = "bpmnProcess.xml";
+
+ public static final String migrateXSLT = "migrate.xslt";
+
+ private TransformerFactory transformerFactory;
+ private Transformer transformer;
+
+ @Before
+ public void before() throws Exception {
+ InputStream xsltInputStream = getClass().getClassLoader().getResourceAsStream(migrateXSLT);
+
+ StreamSource source = new StreamSource(xsltInputStream);
+ assertTrue("XSLT source could not be instantiated.", source != null && source.getInputStream() != null );
+
+ transformerFactory = TransformerFactory.newInstance();
+ Templates templates = null;
+ try {
+ templates = transformerFactory.newTemplates(source);
+ }
+ catch( TransformerConfigurationException tce ) {
+ fail( "Could not instantiate transformer templates: " + tce.getMessageAndLocation());
+ }
+
+ assertTrue("Transformer template could not be instantiated.", templates != null);
+ try {
+ transformer = templates.newTransformer();
+ }
+ catch( TransformerConfigurationException tce ) {
+ tce.printStackTrace();
+ fail( "Could not instantiate transformer: " + tce.getMessageAndLocation());
+ }
+ }
+
+ @Test
+ public void happyTest() {
+ String process = "Single Task";
+ String dir = singleTaskJpdl;
+
+ File resultFile = transformJpdlXml(transformer, dir, process);
+
+
+ }
+
+ public static File transformJpdlXml(Transformer transformer, String dir, String process) {
+ URL startURL = XSLTTest.class.getClassLoader().getResource(dir + "/" + procDefXML);
+ assertTrue( process + " JPDL URL could not be retrieved.", startURL != null );
+ File startFile = new File(startURL.getFile());
+ assertTrue( process + " JPDL File could not be instantiated.", startFile != null && startFile.exists());
+
+ dir = startFile.getParentFile().getAbsolutePath();
+ String fileLoc = dir + "/" + bpmnDefXML;
+ File resultFile = new File(fileLoc);
+ try {
+ resultFile.createNewFile();
+ }
+ catch( IOException ioe ) {
+ fail( "Unable to create new file: " + ioe.getMessage() );
+ }
+ assertTrue( process + " BPMN File could not be retrieved.", resultFile != null );
+
+ try {
+ transformer.transform(new StreamSource(startFile), new StreamResult(resultFile));
+ }
+ catch(TransformerException te ) {
+ fail( "Could not transform " + process + " from JPDL to BPMN: " + te.getMessageAndLocation());
+ }
+
+ return resultFile;
+ }
+
+}
Property changes on: projects/migration_tool/trunk/src/test/java/test/XSLTTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/test/resources/bpmn/Test.bpmn.xml
===================================================================
--- projects/migration_tool/trunk/src/test/resources/bpmn/Test.bpmn.xml (rev 0)
+++ projects/migration_tool/trunk/src/test/resources/bpmn/Test.bpmn.xml 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,25 @@
+<definitions id="defId" typeLanguage="http://www.w3.org/2001/XMLSchema" expressionLanguage="http://www.w3.org/1999/XPath" targetNamespace="http://www.omg.org/bpmn20">
+ <process id="procesId">
+ <laneSet id="laneSetId">
+ <lane name="DefaultLane" id="laneId">
+ <flowElementRef>taskId</flowElementRef>
+ <flowElementRef>startEventId</flowElementRef>
+ <flowElementRef>endEventId</flowElementRef>
+ </lane>
+ </laneSet>
+ <task completionQuantity="1" startQuantity="1" isForCompensation="false" name="" id="taskId"/>
+ <startEvent name="" id="startEventId"/>
+ <endEvent name="" id="endEventId"/>
+ <sequenceFlow targetRef="taskId" sourceRef="startEventId" name="" id="fou"/>
+ <sequenceFlow targetRef="endEventId" sourceRef="taskId" name="" id="fiv"/>
+ </process>
+ <bpmndi:processDiagram processRef="procesId" id="procesId_gui">
+ <bpmndi:laneCompartment isVisible="false" height="0.0" width="0.0" y="0.0" x="0.0" name="DefaultLane" id="laneId_gui">
+ <bpmndi:activityShape activityRef="taskId" height="40.0" width="50.0" y="105.0" x="90.0" name="" id="taskId_gui"/>
+ <bpmndi:eventShape eventRef="startEventId" height="30.0" width="30.0" y="35.0" x="100.0" name="" id="startEventId_gui"/>
+ <bpmndi:eventShape eventRef="endEventId" height="28.0" width="28.0" y="182.0" x="101.0" name="" id="endEventId_gui"/>
+ </bpmndi:laneCompartment>
+ <bpmndi:sequenceFlowConnector sequenceFlowRef="fou" label="" targetRef="taskId_gui" sourceRef="startEventId_gui" id="fou_gui"/>
+ <bpmndi:sequenceFlowConnector sequenceFlowRef="fiv" label="" targetRef="endEventId_gui" sourceRef="taskId_gui" id="fiv_gui"/>
+ </bpmndi:processDiagram>
+</definitions>
\ No newline at end of file
Property changes on: projects/migration_tool/trunk/src/test/resources/bpmn/Test.bpmn.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/test/resources/bpmn/Test.bpmn_diagram
===================================================================
--- projects/migration_tool/trunk/src/test/resources/bpmn/Test.bpmn_diagram (rev 0)
+++ projects/migration_tool/trunk/src/test/resources/bpmn/Test.bpmn_diagram 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<notation:Diagram xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:bpmn="http://stp.eclipse.org/bpmn" xmlns:notation="http://www.eclipse.org/gmf/runtime/1.0.2/notation" xmi:id="_Pdrh8IhqEd-1RIOw4wJNOg" type="Bpmn" name="Test.bpmn_diagram" measurementUnit="Pixel">
+ <children xmi:type="notation:Node" xmi:id="_PeqZYIhqEd-1RIOw4wJNOg" type="1001">
+ <children xmi:type="notation:Node" xmi:id="_PfF3MIhqEd-1RIOw4wJNOg" type="4008"/>
+ <children xmi:type="notation:Node" xmi:id="_PfHsYIhqEd-1RIOw4wJNOg" type="5001">
+ <children xmi:type="notation:Node" xmi:id="_PfJhkIhqEd-1RIOw4wJNOg" type="2001">
+ <children xmi:type="notation:Node" xmi:id="_PfKIoIhqEd-1RIOw4wJNOg" type="4001"/>
+ <styles xmi:type="notation:FontStyle" xmi:id="_PfJhkYhqEd-1RIOw4wJNOg" fontName="Arial"/>
+ <styles xmi:type="notation:DescriptionStyle" xmi:id="_PfJhkohqEd-1RIOw4wJNOg"/>
+ <styles xmi:type="notation:FillStyle" xmi:id="_PfJhk4hqEd-1RIOw4wJNOg"/>
+ <styles xmi:type="notation:LineStyle" xmi:id="_PfJhlIhqEd-1RIOw4wJNOg" lineColor="0"/>
+ <element xmi:type="bpmn:Activity" href="Test.bpmn#_PehPcYhqEd-1RIOw4wJNOg"/>
+ <layoutConstraint xmi:type="notation:Bounds" xmi:id="_PfKIoYhqEd-1RIOw4wJNOg" x="55" y="70" width="111" height="61"/>
+ </children>
+ <styles xmi:type="notation:DrawerStyle" xmi:id="_PfHsYYhqEd-1RIOw4wJNOg"/>
+ <styles xmi:type="notation:SortingStyle" xmi:id="_PfHsYohqEd-1RIOw4wJNOg"/>
+ <styles xmi:type="notation:FilteringStyle" xmi:id="_PfHsY4hqEd-1RIOw4wJNOg"/>
+ </children>
+ <styles xmi:type="notation:FontStyle" xmi:id="_PeqZYYhqEd-1RIOw4wJNOg" fontName="Arial"/>
+ <styles xmi:type="notation:DescriptionStyle" xmi:id="_PeqZYohqEd-1RIOw4wJNOg"/>
+ <styles xmi:type="notation:FillStyle" xmi:id="_PeqZY4hqEd-1RIOw4wJNOg" fillColor="16771304"/>
+ <styles xmi:type="notation:LineStyle" xmi:id="_PeqZZIhqEd-1RIOw4wJNOg" lineColor="11119017"/>
+ <element xmi:type="bpmn:Pool" href="Test.bpmn#_PeBgMYhqEd-1RIOw4wJNOg"/>
+ <layoutConstraint xmi:type="notation:Bounds" xmi:id="_PfITcIhqEd-1RIOw4wJNOg" x="16" y="16" width="1500" height="200"/>
+ </children>
+ <styles xmi:type="notation:PageStyle" xmi:id="_Pdrh8YhqEd-1RIOw4wJNOg"/>
+ <styles xmi:type="notation:GuideStyle" xmi:id="_Pdrh8ohqEd-1RIOw4wJNOg"/>
+ <styles xmi:type="notation:DescriptionStyle" xmi:id="_Pdrh84hqEd-1RIOw4wJNOg"/>
+ <element xmi:type="bpmn:BpmnDiagram" href="Test.bpmn#_PZvdIIhqEd-1RIOw4wJNOg"/>
+</notation:Diagram>
Added: projects/migration_tool/trunk/src/test/resources/jbjPDL4ToBPMN2.xsl
===================================================================
--- projects/migration_tool/trunk/src/test/resources/jbjPDL4ToBPMN2.xsl (rev 0)
+++ projects/migration_tool/trunk/src/test/resources/jbjPDL4ToBPMN2.xsl 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,102 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsl:stylesheet version="2.0"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:jpdl="http://jbpm.org/4.3/jpdl">
+
+<!-- Converts a jPDL4.3 file to a BPMN2 file-->
+<xsl:output method="xml" indent="yes" />
+
+<xsl:template match="/">
+ <definitions id="Definition"
+ targetNamespace="http://www.jboss.org/drools"
+ typeLanguage="http://www.java.com/javaTypes"
+ expressionLanguage="http://www.mvel.org/2.0"
+ xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema-instance"
+ xs:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd"
+ xmlns:g="http://www.jboss.org/drools/flow/gpd"
+ xmlns:tns="http://www.jboss.org/drools">
+
+ <xsl:apply-templates select="jpdl:process"/>
+
+ </definitions>
+</xsl:template>
+
+<xsl:template match="jpdl:process">
+ <process>
+ <xsl:attribute name="id"><xsl:value-of select="@name"/></xsl:attribute>
+ <xsl:attribute name="name"><xsl:value-of select="@name"/></xsl:attribute>
+ <xsl:apply-templates/>
+ </process>
+</xsl:template>
+
+<xsl:template match="jpdl:start">
+ <xsl:variable name="id"><xsl:value-of select="@name"/></xsl:variable>
+ <startEvent>
+ <xsl:attribute name="id"><xsl:value-of select="$id"/></xsl:attribute>
+ <xsl:attribute name="name"><xsl:value-of select="$id"/></xsl:attribute>
+ <xsl:if test="@g">
+ <xsl:attribute name="g:x"><xsl:value-of select="substring-before(@g,',')"/></xsl:attribute>
+ <xsl:variable name="g2"><xsl:value-of select="substring-after(@g,',')"/></xsl:variable>
+ <xsl:attribute name="g:y"><xsl:value-of select="substring-before($g2,',')"/></xsl:attribute>
+ <xsl:variable name="g3"><xsl:value-of select="substring-after($g2,',')"/></xsl:variable>
+ <xsl:attribute name="g:width"><xsl:value-of select="substring-before($g3,',')"/></xsl:attribute>
+ <xsl:attribute name="g:height"><xsl:value-of select="substring-after($g3,',')"/></xsl:attribute>
+ </xsl:if>
+ </startEvent>
+ <xsl:for-each select="jpdl:transition">
+ <sequenceFlow>
+ <xsl:attribute name="sourceRef"><xsl:value-of select="$id"/></xsl:attribute>
+ <xsl:attribute name="targetRef"><xsl:value-of select="@to"/></xsl:attribute>
+ </sequenceFlow>
+ </xsl:for-each>
+</xsl:template>
+
+<xsl:template match="jpdl:end">
+ <xsl:variable name="id"><xsl:value-of select="@name"/></xsl:variable>
+ <endEvent>
+ <xsl:attribute name="id"><xsl:value-of select="$id"/></xsl:attribute>
+ <xsl:attribute name="name"><xsl:value-of select="$id"/></xsl:attribute>
+ <xsl:if test="@g">
+ <xsl:attribute name="g:x"><xsl:value-of select="substring-before(@g,',')"/></xsl:attribute>
+ <xsl:variable name="g2"><xsl:value-of select="substring-after(@g,',')"/></xsl:variable>
+ <xsl:attribute name="g:y"><xsl:value-of select="substring-before($g2,',')"/></xsl:attribute>
+ <xsl:variable name="g3"><xsl:value-of select="substring-after($g2,',')"/></xsl:variable>
+ <xsl:attribute name="g:width"><xsl:value-of select="substring-before($g3,',')"/></xsl:attribute>
+ <xsl:attribute name="g:height"><xsl:value-of select="substring-after($g3,',')"/></xsl:attribute>
+ </xsl:if>
+ <terminateEventDefinition/>
+ </endEvent>
+</xsl:template>
+
+<xsl:template match="jpdl:task">
+ <xsl:variable name="id"><xsl:value-of select="@name"/></xsl:variable>
+ <userTask>
+ <xsl:attribute name="id"><xsl:value-of select="$id"/></xsl:attribute>
+ <xsl:attribute name="name"><xsl:value-of select="$id"/></xsl:attribute>
+ <xsl:if test="@g">
+ <xsl:attribute name="g:x"><xsl:value-of select="substring-before(@g,',')"/></xsl:attribute>
+ <xsl:variable name="g2"><xsl:value-of select="substring-after(@g,',')"/></xsl:variable>
+ <xsl:attribute name="g:y"><xsl:value-of select="substring-before($g2,',')"/></xsl:attribute>
+ <xsl:variable name="g3"><xsl:value-of select="substring-after($g2,',')"/></xsl:variable>
+ <xsl:attribute name="g:width"><xsl:value-of select="substring-before($g3,',')"/></xsl:attribute>
+ <xsl:attribute name="g:height"><xsl:value-of select="substring-after($g3,',')"/></xsl:attribute>
+ </xsl:if>
+ <xsl:if test="@assignee">
+ <potentialOwner>
+ <resourceAssignmentExpression>
+ <formalExpression><xsl:value-of select="@assignee"/></formalExpression>
+ </resourceAssignmentExpression>
+ </potentialOwner>
+ </xsl:if>
+ </userTask>
+ <xsl:for-each select="jpdl:transition">
+ <sequenceFlow>
+ <xsl:attribute name="sourceRef"><xsl:value-of select="$id"/></xsl:attribute>
+ <xsl:attribute name="targetRef"><xsl:value-of select="@to"/></xsl:attribute>
+ </sequenceFlow>
+ </xsl:for-each>
+</xsl:template>
+
+</xsl:stylesheet>
\ No newline at end of file
Property changes on: projects/migration_tool/trunk/src/test/resources/jbjPDL4ToBPMN2.xsl
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/test/resources/jpdl/test/gpd.xml
===================================================================
--- projects/migration_tool/trunk/src/test/resources/jpdl/test/gpd.xml (rev 0)
+++ projects/migration_tool/trunk/src/test/resources/jpdl/test/gpd.xml 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<root-container name="Test" width="1111" height="594">
+ <node name="start-state1" x="468" y="75" width="132" height="36">
+ <edge>
+ <label x="5" y="-10"/>
+ </edge>
+ </node>
+ <node name="node1" x="473" y="206" width="132" height="36">
+ <edge>
+ <label x="5" y="-10"/>
+ </edge>
+ </node>
+ <node name="end-state1" x="476" y="328" width="132" height="36"/>
+</root-container>
Property changes on: projects/migration_tool/trunk/src/test/resources/jpdl/test/gpd.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/test/resources/jpdl/test/processdefinition.xml
===================================================================
--- projects/migration_tool/trunk/src/test/resources/jpdl/test/processdefinition.xml (rev 0)
+++ projects/migration_tool/trunk/src/test/resources/jpdl/test/processdefinition.xml 2010-09-27 15:32:02 UTC (rev 6685)
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<process-definition xmlns="" name="Test">
+
+
+ <start-state name="start-state1">
+ <transition to="node1"></transition>
+ </start-state>
+
+
+ <node name="node1">
+ <transition to="end-state1"></transition>
+ </node>
+
+
+ <end-state name="end-state1"></end-state>
+
+
+</process-definition>
\ No newline at end of file
Property changes on: projects/migration_tool/trunk/src/test/resources/jpdl/test/processdefinition.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: projects/migration_tool/trunk/src/test/resources/jpdl/test/processimage.jpg
===================================================================
(Binary files differ)
Property changes on: projects/migration_tool/trunk/src/test/resources/jpdl/test/processimage.jpg
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
13 years, 7 months
JBoss JBPM SVN: r6684 - jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise and 4 other directories.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2010-09-26 00:37:48 -0400 (Sun, 26 Sep 2010)
New Revision: 6684
Added:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/ExecuteJobCommand.java
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/.classpath
Removed:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java
Modified:
jbpm3/branches/jbpm-3.2-soa/core/src/test/java/org/jbpm/perf/PerformanceTest.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/AbstractEnterpriseTestCase.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/ejbtimer/EjbSchedulerTest.java
Log:
JBPM-2945 fix repetitive timers expiring only once;
re-enable testScheduleFork; increase testPerformance timeout
Modified: jbpm3/branches/jbpm-3.2-soa/core/src/test/java/org/jbpm/perf/PerformanceTest.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/core/src/test/java/org/jbpm/perf/PerformanceTest.java 2010-09-26 00:44:51 UTC (rev 6683)
+++ jbpm3/branches/jbpm-3.2-soa/core/src/test/java/org/jbpm/perf/PerformanceTest.java 2010-09-26 04:37:48 UTC (rev 6684)
@@ -56,24 +56,14 @@
deployProcessDefinition(processDefinition);
}
- public void testAsyncCall() {
- Runtime rt = Runtime.getRuntime();
- System.out.print("Free memory: ");
- System.out.println(rt.freeMemory());
- System.out.print("Total memory: ");
- System.out.println(rt.totalMemory());
- System.out.print("Max memory: ");
- System.out.println(rt.maxMemory());
- System.out.print("Processors: ");
- System.out.println(rt.availableProcessors());
-
+ public void testPerformance() {
long firstTime = System.currentTimeMillis();
launchProcessInstances(WARMUP_INSTANCES);
processJobs(TIMEOUT);
long secondTime = System.currentTimeMillis();
launchProcessInstances(MEASURED_INSTANCES);
- processJobs((secondTime - firstTime) * (MEASURED_INSTANCES / WARMUP_INSTANCES + 1));
+ processJobs((secondTime - firstTime) * (MEASURED_INSTANCES / WARMUP_INSTANCES) * 2);
long duration = System.currentTimeMillis() - secondTime;
System.out.println("### Processed "
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/AbstractEnterpriseTestCase.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/AbstractEnterpriseTestCase.java 2010-09-26 00:44:51 UTC (rev 6683)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/AbstractEnterpriseTestCase.java 2010-09-26 04:37:48 UTC (rev 6684)
@@ -58,10 +58,10 @@
private List processDefinitions = new ArrayList();
+ private final Log log = LogFactory.getLog(getClass());
+
private static Context environment;
- private static final Log log = LogFactory.getLog(AbstractEnterpriseTestCase.class);
-
protected AbstractEnterpriseTestCase() {
}
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/ejbtimer/EjbSchedulerTest.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/ejbtimer/EjbSchedulerTest.java 2010-09-26 00:44:51 UTC (rev 6683)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/ejbtimer/EjbSchedulerTest.java 2010-09-26 04:37:48 UTC (rev 6684)
@@ -199,9 +199,6 @@
}
public void testScheduleFork() throws Exception {
- // [JBPM-2916] temporarily exclude this test from the suite
- if (true) return;
-
deployProcessDefinition("<process-definition name='fork'>"
+ " <event type='process-end'>"
+ " <action expression='#{eventCallback.processEnd}'/>"
Deleted: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java 2010-09-26 00:44:51 UTC (rev 6683)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java 2010-09-26 04:37:48 UTC (rev 6684)
@@ -1,110 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jbpm.ejb.impl;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
-import org.jbpm.JbpmContext;
-import org.jbpm.command.Command;
-import org.jbpm.graph.exe.ProcessInstance;
-import org.jbpm.job.Job;
-import org.jbpm.job.Timer;
-import org.jbpm.scheduler.SchedulerService;
-
-/**
- * Individual job processing command.
- *
- * @author Alejandro Guizar
- */
-public class ExecuteJobCommand implements Command {
-
- private final long jobId;
-
- private static final long serialVersionUID = 1L;
- private static final Log log = LogFactory.getLog(ExecuteJobCommand.class.getName());
-
- public ExecuteJobCommand(long jobId) {
- this.jobId = jobId;
- }
-
- public Object execute(JbpmContext jbpmContext) throws Exception {
- Job job = acquireJob(jobId, jbpmContext);
- if (job != null) executeJob(job, jbpmContext);
- return job;
- }
-
- private static Job acquireJob(long jobId, JbpmContext jbpmContext) {
- boolean debug = log.isDebugEnabled();
- if (debug) log.debug("acquiring job: " + jobId);
- Job job = jbpmContext.getJobSession().getJob(jobId);
-
- // job could have been deleted manually
- // or by ending the process instance
- if (job != null) {
- // register process instance for automatic save
- // see https://jira.jboss.org/jira/browse/JBPM-1015
- ProcessInstance processInstance = job.getProcessInstance();
- jbpmContext.addAutoSaveProcessInstance(processInstance);
-
- // if job is exclusive, lock process instance
- if (job.isExclusive()) {
- jbpmContext.getGraphSession().lockProcessInstance(processInstance);
- }
-
- // mark job as locked to prevent it from being deleted
- job.setLockOwner(Thread.currentThread().getName());
- if (debug) log.debug("acquired " + job);
- }
- else {
- log.warn("job not found: " + jobId);
- }
-
- return job;
- }
-
- private static void executeJob(Job job, JbpmContext jbpmContext) throws Exception {
- if (log.isDebugEnabled()) log.debug("executing " + job);
- if (job.execute(jbpmContext)) {
- if (job instanceof Timer) {
- Timer timer = (Timer) job;
- SchedulerService schedulerService = jbpmContext.getServices().getSchedulerService();
- // if the timer has repeat
- if (timer.getRepeat() != null) {
- // create a new timer
- if (log.isDebugEnabled()) {
- log.debug("scheduling timer for repeat on " + timer.getDueDate());
- }
- schedulerService.createTimer(timer);
- }
- else {
- // clear timer
- schedulerService.deleteTimer((Timer) job);
- }
- }
- else {
- // clear job
- jbpmContext.getJobSession().deleteJob(job);
- }
- }
- }
-}
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java 2010-09-26 00:44:51 UTC (rev 6683)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java 2010-09-26 04:37:48 UTC (rev 6684)
@@ -10,6 +10,7 @@
import org.apache.commons.logging.LogFactory;
import org.jbpm.command.Command;
+import org.jbpm.jms.ExecuteJobCommand;
/**
* Message-driven bean that listens for {@link Message messages} containing a reference to a
Copied: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/ExecuteJobCommand.java (from rev 6683, jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java)
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/ExecuteJobCommand.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/ExecuteJobCommand.java 2010-09-26 04:37:48 UTC (rev 6684)
@@ -0,0 +1,97 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.jms;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.jbpm.JbpmContext;
+import org.jbpm.command.Command;
+import org.jbpm.graph.exe.ProcessInstance;
+import org.jbpm.job.Job;
+import org.jbpm.job.Timer;
+
+/**
+ * Individual job processing command.
+ *
+ * @author Alejandro Guizar
+ */
+public class ExecuteJobCommand implements Command {
+
+ private final long jobId;
+
+ private static final long serialVersionUID = 1L;
+ private static final Log log = LogFactory.getLog(ExecuteJobCommand.class);
+
+ public ExecuteJobCommand(long jobId) {
+ this.jobId = jobId;
+ }
+
+ public Object execute(JbpmContext jbpmContext) throws Exception {
+ Job job = acquireJob(jobId, jbpmContext);
+ if (job != null) executeJob(job, jbpmContext);
+ return job;
+ }
+
+ private static Job acquireJob(long jobId, JbpmContext jbpmContext) {
+ boolean debug = log.isDebugEnabled();
+ if (debug) log.debug("acquiring job: " + jobId);
+ Job job = jbpmContext.getJobSession().getJob(jobId);
+
+ // job could have been deleted manually
+ // or by ending the process instance
+ if (job != null) {
+ // register process instance for automatic save
+ // see https://jira.jboss.org/jira/browse/JBPM-1015
+ ProcessInstance processInstance = job.getProcessInstance();
+ jbpmContext.addAutoSaveProcessInstance(processInstance);
+
+ // if job is exclusive, lock process instance
+ if (job.isExclusive()) {
+ jbpmContext.getGraphSession().lockProcessInstance(processInstance);
+ }
+
+ // mark job as locked to prevent it from being deleted
+ job.setLockOwner(Thread.currentThread().getName());
+ if (debug) log.debug("acquired " + job);
+ }
+ else {
+ log.warn("job not found: " + jobId);
+ }
+
+ return job;
+ }
+
+ private static void executeJob(Job job, JbpmContext jbpmContext) throws Exception {
+ if (log.isDebugEnabled()) log.debug("executing " + job);
+ if (job.execute(jbpmContext)) {
+ // clear job
+ jbpmContext.getJobSession().deleteJob(job);
+ }
+ else {
+ // job is a repetitive timer
+ Timer timer = jbpmContext.getJobSession().loadTimer(job.getId());
+ JmsConnectorService schedulerService = (JmsConnectorService) jbpmContext.getServices().getSchedulerService();
+ schedulerService.sendWithoutSaving(timer);
+ }
+ }
+}
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java 2010-09-26 00:44:51 UTC (rev 6683)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java 2010-09-26 04:37:48 UTC (rev 6684)
@@ -73,7 +73,10 @@
public void send(Job job) {
jobSession.saveJob(job);
+ sendWithoutSaving(job);
+ }
+ void sendWithoutSaving(Job job) {
try {
Message message = session.createMessage();
populateMessage(message, job);
Added: projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/.classpath
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/.classpath (rev 0)
+++ projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/.classpath 2010-09-26 04:37:48 UTC (rev 6684)
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.4"/>
+ <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
13 years, 7 months
JBoss JBPM SVN: r6683 - in jbpm3/branches/jbpm-3.2-soa: ci and 29 other directories.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2010-09-25 20:44:51 -0400 (Sat, 25 Sep 2010)
New Revision: 6683
Added:
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/.classpath
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/.project
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/pom.xml
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/scripts/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/scripts/assembly-config.xml
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/hibernate.extra.hbm.xml
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.cfg.xml
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.jndi.properties
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/LocalCommandService.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorServiceFactory.java
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/ejb-jar.xml
jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/jboss.xml
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/DeploymentException.java
Removed:
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/resources/jndi.properties
Modified:
jbpm3/branches/jbpm-3.2-soa/ci/container.sh
jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/command/Command.java
jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/context/exe/matcher/HibernateLongIdMatcher.java
jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/context/exe/matcher/HibernateStringIdMatcher.java
jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/db/JobSession.java
jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/job/Job.java
jbpm3/branches/jbpm-3.2-soa/distribution/pom.xml
jbpm3/branches/jbpm-3.2-soa/distribution/scripts/assembly-modules.xml
jbpm3/branches/jbpm-3.2-soa/distribution/src/main/resources/installer/install-definition.xml
jbpm3/branches/jbpm-3.2-soa/enterprise/pom.xml
jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/etc/jbpm.cfg.xml
jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/resources/META-INF/ejb-jar.xml
jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/resources/META-INF/jboss.xml
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/AbstractEnterpriseTestCase.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/ArchiveDeployer.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/IntegrationTestHelper.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/IntegrationTestSetup.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/JBossArchiveDeployer.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/config/AppServerConfigurationsTest.java
jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/webapp/WEB-INF/jboss-web.xml
jbpm3/branches/jbpm-3.2-soa/pom.xml
jbpm3/branches/jbpm-3.2-soa/soa-distribution/pom.xml
Log:
JBPM-2945 derive job processor based on jee5 from existing enterprise module
Modified: jbpm3/branches/jbpm-3.2-soa/ci/container.sh
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/ci/container.sh 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/ci/container.sh 2010-09-26 00:44:51 UTC (rev 6683)
@@ -53,8 +53,8 @@
cp -u ci/profiles.redhat.qa.xml profiles.xml
# Determine jBPM version
-mvn -s /dev/null -Dexpression=project.version help:evaluate > $WORKSPACE/project-version.txt
-JBPM_VERSION=`grep '^3\.' $WORKSPACE/project-version.txt`
+mvn -s /dev/null -Dexpression=project.version help:evaluate > $WORKSPACE/version.txt
+JBPM_VERSION=`grep '^3\.' $WORKSPACE/version.txt`
# Build jBPM
mvn -s /dev/null -Pdistro -Djbpm.home=$WORKSPACE/jbpm-$JBPM_VERSION -Dcontainer=$CONTAINER \
@@ -147,7 +147,6 @@
# Run enterprise test suite
mvn -f enterprise/pom.xml -s /dev/null --fail-at-end -Djboss.bind.address=$MYTESTIP_1 \
-Dsurefire.jvm.args="-Xms64m -Xmx256m" integration-test | tee $WORKSPACE/tests.log
-grep -E 'FIXME\|FAILED' $WORKSPACE/tests.log | sort -u > $WORKSPACE/fixme.txt
# Stop JBoss AS
$JBOSS_HOME/bin/shutdown.sh -s jnp://$MYTESTIP_1:1099 -S
Modified: jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/command/Command.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/command/Command.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/command/Command.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -25,8 +25,7 @@
import org.jbpm.JbpmContext;
-public interface Command extends Serializable
-{
+public interface Command extends Serializable {
Object execute(JbpmContext jbpmContext) throws Exception;
}
Modified: jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/context/exe/matcher/HibernateLongIdMatcher.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/context/exe/matcher/HibernateLongIdMatcher.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/context/exe/matcher/HibernateLongIdMatcher.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -21,10 +21,10 @@
*/
package org.jbpm.context.exe.matcher;
+import org.hibernate.Hibernate;
import org.hibernate.SessionFactory;
import org.hibernate.metadata.ClassMetadata;
import org.hibernate.proxy.HibernateProxy;
-import org.hibernate.type.LongType;
import org.jbpm.JbpmContext;
import org.jbpm.context.exe.JbpmTypeMatcher;
@@ -44,7 +44,7 @@
if (sessionFactory != null) {
ClassMetadata classMetadata = sessionFactory.getClassMetadata(valueClass);
return classMetadata != null
- && classMetadata.getIdentifierType().getClass() == LongType.class;
+ && classMetadata.getIdentifierType() == Hibernate.LONG;
}
}
return false;
Modified: jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/context/exe/matcher/HibernateStringIdMatcher.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/context/exe/matcher/HibernateStringIdMatcher.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/context/exe/matcher/HibernateStringIdMatcher.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -21,10 +21,10 @@
*/
package org.jbpm.context.exe.matcher;
+import org.hibernate.Hibernate;
import org.hibernate.SessionFactory;
import org.hibernate.metadata.ClassMetadata;
import org.hibernate.proxy.HibernateProxy;
-import org.hibernate.type.StringType;
import org.jbpm.JbpmContext;
import org.jbpm.context.exe.JbpmTypeMatcher;
@@ -44,7 +44,7 @@
if (sessionFactory != null) {
ClassMetadata classMetadata = sessionFactory.getClassMetadata(valueClass);
return classMetadata != null
- && classMetadata.getIdentifierType().getClass() == StringType.class;
+ && classMetadata.getIdentifierType() == Hibernate.STRING;
}
}
return false;
Modified: jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/db/JobSession.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/db/JobSession.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/db/JobSession.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -69,10 +69,8 @@
.list();
}
catch (HibernateException e) {
- throw new JbpmPersistenceException("could not find exclusive jobs owned by '"
- + lockOwner
- + "' for "
- + processInstance, e);
+ throw new JbpmPersistenceException("could not find exclusive jobs owned by '" + lockOwner
+ + "' for " + processInstance, e);
}
}
@@ -100,10 +98,8 @@
return (Job) query.setString("lockOwner", lockOwner).setMaxResults(1).uniqueResult();
}
catch (HibernateException e) {
- throw new JbpmPersistenceException("could not get first due job owned by '"
- + lockOwner
- + "' ignoring jobs "
- + monitoredJobs, e);
+ throw new JbpmPersistenceException("could not get first due job owned by '" + lockOwner
+ + "' ignoring jobs " + monitoredJobs, e);
}
}
@@ -213,9 +209,7 @@
preventFurtherRepetitions(timers);
}
catch (HibernateException e) {
- throw new JbpmPersistenceException("could not delete timers by name '"
- + name
- + "' for "
+ throw new JbpmPersistenceException("could not delete timers by name '" + name + "' for "
+ token, e);
}
}
@@ -261,8 +255,8 @@
.list();
}
catch (HibernateException e) {
- throw new JbpmPersistenceException(
- "could not find jobs with lock time over " + threshold, e);
+ throw new JbpmPersistenceException("could not find jobs with lock time over " +
+ threshold, e);
}
}
Modified: jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/job/Job.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/job/Job.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/core/src/main/java/org/jbpm/job/Job.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -83,8 +83,8 @@
return lockTime;
}
- public void setLockTime(Date aqcuireDate) {
- this.lockTime = aqcuireDate;
+ public void setLockTime(Date lockTime) {
+ this.lockTime = lockTime;
}
/** @deprecated call {@link #getLockTime()} instead */
@@ -127,8 +127,8 @@
return lockOwner;
}
- public void setLockOwner(String jobExecutorName) {
- this.lockOwner = jobExecutorName;
+ public void setLockOwner(String lockOwner) {
+ this.lockOwner = lockOwner;
}
/** @deprecated call {@link #getLockOwner()} instead */
Modified: jbpm3/branches/jbpm-3.2-soa/distribution/pom.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/distribution/pom.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/distribution/pom.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -40,6 +40,18 @@
</dependency>
<dependency>
<groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jbpm-enterprise-jee5</artifactId>
+ <version>${project.version}</version>
+ <type>ejb</type>
+ </dependency>
+ <dependency>
+ <groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jbpm-enterprise-jee5</artifactId>
+ <classifier>config</classifier>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jbpm.jbpm3</groupId>
<artifactId>jbpm-enterprise</artifactId>
<version>${project.version}</version>
<type>ejb</type>
@@ -96,6 +108,11 @@
</dependency>
<dependency>
<groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jsf-console-jee5</artifactId>
+ <type>war</type>
+ </dependency>
+ <dependency>
+ <groupId>org.jbpm.jbpm3</groupId>
<artifactId>gpd-deployer</artifactId>
<type>war</type>
</dependency>
@@ -103,6 +120,12 @@
<!-- Sources -->
<dependency>
<groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jbpm-enterprise-jee5</artifactId>
+ <classifier>sources</classifier>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jbpm.jbpm3</groupId>
<artifactId>jbpm-enterprise</artifactId>
<classifier>sources</classifier>
<version>${project.version}</version>
@@ -123,6 +146,12 @@
<!-- Javadoc -->
<dependency>
<groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jbpm-enterprise-jee5</artifactId>
+ <classifier>javadoc</classifier>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jbpm.jbpm3</groupId>
<artifactId>jbpm-enterprise</artifactId>
<classifier>javadoc</classifier>
<version>${project.version}</version>
@@ -233,5 +262,4 @@
</plugin>
</plugins>
</build>
-
</project>
Modified: jbpm3/branches/jbpm-3.2-soa/distribution/scripts/assembly-modules.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/distribution/scripts/assembly-modules.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/distribution/scripts/assembly-modules.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -23,7 +23,6 @@
<outputDirectory>lib</outputDirectory>
<outputFileNameMapping>${artifact.artifactId}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
<useProjectArtifact>false</useProjectArtifact>
- <scope>test</scope>
</dependencySet>
<!-- config -->
Modified: jbpm3/branches/jbpm-3.2-soa/distribution/src/main/resources/installer/install-definition.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/distribution/src/main/resources/installer/install-definition.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/distribution/src/main/resources/installer/install-definition.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -213,7 +213,16 @@
<!-- jbpm/jbpm-service.sar -->
<file src="@{assemblyDirectory}/lib/jbpm-enterprise-config.jar"
targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar"
- unpack="true" />
+ unpack="true" condition="isJBoss405" />
+ <file src="@{assemblyDirectory}/lib/jbpm-enterprise-config.jar"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar"
+ unpack="true" condition="isJBoss423" />
+ <file src="@{assemblyDirectory}/lib/jbpm-enterprise-jee5-config.jar"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar"
+ unpack="true" condition="isJBoss501" />
+ <file src="@{assemblyDirectory}/lib/jbpm-enterprise-jee5-config.jar"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar"
+ unpack="true" condition="isJBoss510" />
<fileset dir="@{assemblyDirectory}/lib"
targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar">
<include name="jbpm-jpdl.jar" />
@@ -231,7 +240,16 @@
<!-- jbpm/jbpm-enterprise.jar -->
<file src="@{assemblyDirectory}/lib/jbpm-enterprise.jar"
targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-enterprise.jar"
- unpack="true" />
+ unpack="true" condition="isJBoss405" />
+ <file src="@{assemblyDirectory}/lib/jbpm-enterprise.jar"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-enterprise.jar"
+ unpack="true" condition="isJBoss423" />
+ <file src="@{assemblyDirectory}/lib/jbpm-enterprise-jee5.jar"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-enterprise.jar"
+ unpack="true" condition="isJBoss501" />
+ <file src="@{assemblyDirectory}/lib/jbpm-enterprise-jee5.jar"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-enterprise.jar"
+ unpack="true" condition="isJBoss510" />
<!-- jbpm-mq-service.xml -->
<file src="@{resourcesDirectory}/destination/jbpm-mq-service.xml"
@@ -352,7 +370,18 @@
<!-- jbpm/jsf-console.war -->
<file src="@{assemblyDirectory}/lib/jsf-console.war"
targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jsf-console.war"
- unpack="true" />
+ unpack="true" condition="isJBoss405" />
+ <file src="@{assemblyDirectory}/lib/jsf-console.war"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jsf-console.war"
+ unpack="true" condition="isJBoss423" />
+ <file src="@{assemblyDirectory}/lib/jsf-console-jee5.war"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jsf-console.war"
+ unpack="true" condition="isJBoss501" />
+ <file src="@{assemblyDirectory}/lib/jsf-console-jee5.war"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jsf-console.war"
+ unpack="true" condition="isJBoss510" />
+
+ <!-- jbpm/gpd-deployer.war -->
<file src="@{assemblyDirectory}/lib/gpd-deployer.war"
targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/gpd-deployer.war"
unpack="true" />
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/pom.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/pom.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/pom.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -54,13 +54,6 @@
<!-- Plugins -->
<build>
- <testResources>
- <testResource>
- <directory>src/test/resources</directory>
- <filtering>true</filtering>
- </testResource>
- </testResources>
-
<plugins>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
@@ -100,26 +93,15 @@
<configuration>
<skip>true</skip>
</configuration>
+ </plugin>
+
+ <plugin>
+ <artifactId>maven-jar-plugin</artifactId>
<executions>
<execution>
- <id>surefire-integration</id>
- <phase>integration-test</phase>
<goals>
- <goal>test</goal>
+ <goal>test-jar</goal>
</goals>
- <configuration>
- <skip>false</skip>
- <systemProperties>
- <property>
- <name>cactus.contextURL</name>
- <value>http://${jboss.bind.address}:8080/enterprise-test</value>
- </property>
- <property>
- <name>log4j.output.dir</name>
- <value>${project.build.directory}</value>
- </property>
- </systemProperties>
- </configuration>
</execution>
</executions>
</plugin>
@@ -129,14 +111,14 @@
<!-- Profiles -->
<profiles>
<!--
- Name: no-jboss-bind-address
- Desc: Skip tests if no bind address is given
+ Name: jboss-bind-address
+ Desc: Run integration tests if bind address is given
-->
<profile>
- <id>no-jboss-bind-address</id>
+ <id>jboss-bind-address</id>
<activation>
<property>
- <name>!jboss.bind.address</name>
+ <name>jboss.bind.address</name>
</property>
</activation>
<build>
@@ -146,8 +128,34 @@
<executions>
<execution>
<id>surefire-integration</id>
+ <phase>integration-test</phase>
+ <goals>
+ <goal>test</goal>
+ </goals>
<configuration>
- <skipTests>true</skipTests>
+ <skip>false</skip>
+ <systemProperties>
+ <property>
+ <name>log4j.output.dir</name>
+ <value>${project.build.directory}</value>
+ </property>
+ <property>
+ <name>cactus.contextURL</name>
+ <value>http://${jboss.bind.address}:8080/enterprise-test</value>
+ </property>
+ <property>
+ <name>java.naming.factory.initial</name>
+ <value>org.jnp.interfaces.NamingContextFactory</value>
+ </property>
+ <property>
+ <name>java.naming.factory.url.pkgs</name>
+ <value>org.jboss.naming:org.jnp.interfaces</value>
+ </property>
+ <property>
+ <name>java.naming.provider.url</name>
+ <value>jnp://${jboss.bind.address}:1099</value>
+ </property>
+ </systemProperties>
</configuration>
</execution>
</executions>
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/etc/jbpm.cfg.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/etc/jbpm.cfg.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/etc/jbpm.cfg.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -17,9 +17,8 @@
==== High-availability JNDI properties (end) -->
<!--
- The default job executor needs to be overwritten with a null value.
- There should be no job executor in the enterprise configuration.
- Async messaging is bound to JMS and scheduling, to EJB timers.
+ There should be no job executor in the enterprise configuration.
+ The message service is bound to JMS and the scheduler service, to EJB timers.
-->
<null name="jbpm.job.executor" />
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -24,7 +24,6 @@
import java.io.Serializable;
import javax.ejb.CreateException;
-import javax.ejb.EJBException;
import javax.ejb.MessageDrivenBean;
import javax.ejb.MessageDrivenContext;
import javax.jms.Connection;
@@ -42,6 +41,7 @@
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
+import org.jbpm.JbpmException;
import org.jbpm.command.Command;
import org.jbpm.ejb.LocalCommandService;
import org.jbpm.ejb.LocalCommandServiceHome;
@@ -81,12 +81,6 @@
* <td>Logical name of the factory that provides JMS connections for producing result messages.
* Required for command messages that indicate a reply destination.</td>
* </tr>
- * <tr>
- * <td><code>jms/DeadLetterQueue</code></td>
- * <td>Message Destination Reference</td>
- * <td>Messages which do not contain a command are sent to the queue referenced here. Optional;
- * if absent, such messages are rejected, which may cause the container to redeliver.</td>
- * </tr>
* </table>
*
* @author Jim Rigsbee
@@ -100,7 +94,6 @@
private MessageDrivenContext messageDrivenContext;
private LocalCommandService commandService;
- private Destination deadLetterQueue;
private ConnectionFactory jmsConnectionFactory;
private Connection jmsConnection;
@@ -110,10 +103,7 @@
try {
// extract command from message
Command command = extractCommand(message);
- if (command == null) {
- discard(message);
- return;
- }
+ if (command == null) return;
try {
// execute command via local command executor bean
Object result = commandService.execute(command);
@@ -159,25 +149,6 @@
return null;
}
- private void discard(Message message) throws JMSException {
- if (deadLetterQueue == null) {
- if (log.isDebugEnabled()) {
- log.debug("dead letter queue not available, rejecting: " + message);
- }
- messageDrivenContext.setRollbackOnly();
- }
- else {
- // send message to dead letter queue
- Session jmsSession = createSession();
- try {
- jmsSession.createProducer(deadLetterQueue).send(message);
- }
- finally {
- jmsSession.close();
- }
- }
- }
-
private void sendResult(Serializable result, Destination destination, String correlationId)
throws JMSException {
if (log.isDebugEnabled()) log.debug("sending " + result + " to " + destination);
@@ -220,7 +191,6 @@
jmsConnection = null;
}
jmsConnectionFactory = null;
- deadLetterQueue = null;
commandService = null;
messageDrivenContext = null;
}
@@ -233,19 +203,13 @@
LocalCommandServiceHome commandServiceHome = (LocalCommandServiceHome) jndiContext.lookup("java:comp/env/ejb/LocalCommandServiceBean");
commandService = commandServiceHome.create();
- try {
- deadLetterQueue = (Destination) jndiContext.lookup("java:comp/env/jms/DeadLetterQueue");
- }
- catch (NamingException e) {
- // dead letter queue will not be available
- }
jndiContext.close();
}
catch (NamingException e) {
- throw new EJBException("error retrieving command service home", e);
+ throw new JbpmException("error retrieving command service home", e);
}
catch (CreateException e) {
- throw new EJBException("error creating command service", e);
+ throw new JbpmException("error creating command service", e);
}
}
}
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -105,11 +105,10 @@
private SessionContext sessionContext;
/**
- * creates a command service that will be used to execute the commands that are passed in the
- * execute method. The command service will be build by creating a jbpm configuration. In case
- * the environment key JbpmCfgResource is specified for this bean, that value will be used to
- * resolve the jbpm configuration file as a resource. If that key is not configured, the
- * default jbpm configuration file will be used (jbpm.cfg.xml).
+ * Creates the {@link JbpmConfiguration} to be used by this command service. In case the
+ * environment key <code>JbpmCfgResource</code> is specified, that value is interpreted as the
+ * name of the configuration resource to load from the classpath. If that key is absent, the
+ * default configuration file will be used (jbpm.cfg.xml).
*/
public void ejbCreate() throws CreateException {
String jbpmCfgResource;
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/resources/META-INF/ejb-jar.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/resources/META-INF/ejb-jar.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/resources/META-INF/ejb-jar.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -4,15 +4,13 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd">
-
<description>Component set for Java EE integration.</description>
<display-name>JBoss jBPM Enterprise Beans</display-name>
<enterprise-beans>
-
<session>
<description>Executes commands in a separate context.</description>
- <display-name>jBPM Command Service Session Bean</display-name>
+ <display-name>jBPM Command Service</display-name>
<ejb-name>CommandServiceBean</ejb-name>
<home>org.jbpm.ejb.RemoteCommandServiceHome</home>
<remote>org.jbpm.ejb.RemoteCommandService</remote>
@@ -36,8 +34,8 @@
<ejb-local-ref>
<description>
- Link to the local entity bean that implements the scheduler service. Required for
- processes that contain timers.
+ Link to the local entity bean that implements the scheduler service.
+ Required for processes that contain timers.
</description>
<ejb-ref-name>ejb/TimerEntityBean</ejb-ref-name>
<ejb-ref-type>Entity</ejb-ref-type>
@@ -62,8 +60,8 @@
<resource-ref>
<description>
- Logical name of the data source that provides connections to the persistence service. Must
- match the hibernate.connection.datasource property in the Hibernate configuration file.
+ Data source that provides the persistence service with connections.
+ Must match property hibernate.connection.datasource in the Hibernate configuration.
</description>
<res-ref-name>jdbc/JbpmDataSource</res-ref-name>
<res-type>javax.sql.DataSource</res-type>
@@ -72,8 +70,8 @@
<resource-ref>
<description>
- Logical name of the factory that provides JMS connections to the message service. Required
- for processes that contain asynchronous continuations.
+ Connection factory that provides JMS connections to the message service.
+ Required for processes that contain asynchronous continuations.
</description>
<res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
<res-type>javax.jms.ConnnectionFactory</res-type>
@@ -103,7 +101,6 @@
<message-destination-usage>Produces</message-destination-usage>
<message-destination-link>CommandQueue</message-destination-link>
</message-destination-ref>
-
</session>
<!-- Timer service bean ==>
@@ -137,7 +134,7 @@
<description>
Listens for serialized commands and routes them to the command service session bean.
</description>
- <display-name>jBPM Command Listener Message Driven Bean</display-name>
+ <display-name>jBPM Command Listener</display-name>
<ejb-name>CommandListenerBean</ejb-name>
<ejb-class>org.jbpm.ejb.impl.CommandListenerBean</ejb-class>
<transaction-type>Container</transaction-type>
@@ -164,16 +161,6 @@
<res-type>javax.jms.ConnectionFactory</res-type>
<res-auth>Container</res-auth>
</resource-ref>
-
- <message-destination-ref>
- <description>
- Messages that do not contain a command are sent to the queue referenced here. Optional;
- if absent, such messages are rejected, which may cause the container to redeliver.
- </description>
- <message-destination-ref-name>jms/DeadLetterQueue</message-destination-ref-name>
- <message-destination-type>javax.jms.Queue</message-destination-type>
- <message-destination-usage>Produces</message-destination-usage>
- </message-destination-ref>
</message-driven>
<message-driven>
@@ -181,7 +168,7 @@
Listens for job references and delegates execution of the referenced Job to the command
service session bean.
</description>
- <display-name>jBPM Job Listener Message Driven Bean</display-name>
+ <display-name>jBPM Job Listener</display-name>
<ejb-name>JobListenerBean</ejb-name>
<ejb-class>org.jbpm.ejb.impl.JobListenerBean</ejb-class>
<transaction-type>Container</transaction-type>
@@ -208,21 +195,11 @@
<res-type>javax.jms.ConnectionFactory</res-type>
<res-auth>Container</res-auth>
</resource-ref>
-
- <message-destination-ref>
- <description>
- Messages that do not contain a job ID are sent to the queue referenced here. Optional; if
- absent, such messages are rejected, which may cause the container to redeliver.
- </description>
- <message-destination-ref-name>jms/DeadLetterQueue</message-destination-ref-name>
- <message-destination-type>javax.jms.Queue</message-destination-type>
- <message-destination-usage>Produces</message-destination-usage>
- </message-destination-ref>
</message-driven>
<entity>
<description>Interacts with the EJB timer service to schedule jBPM timers.</description>
- <display-name>jBPM Timer Entity Bean</display-name>
+ <display-name>jBPM Timer</display-name>
<ejb-name>TimerEntityBean</ejb-name>
<home>org.jbpm.ejb.TimerEntityHome</home>
<remote>org.jbpm.ejb.TimerEntity</remote>
@@ -263,7 +240,7 @@
</ejb-local-ref>
<query>
- <description>Retrieve all timers by name and token identifier</description>
+ <description>Retrieve all timers by name and token identifier.</description>
<query-method>
<method-name>findByNameAndTokenId</method-name>
<method-params>
@@ -279,7 +256,7 @@
</query>
<query>
- <description>Retrieve all timers by process instance identifier</description>
+ <description>Retrieve all timers by process instance identifier.</description>
<query-method>
<method-name>findByProcessInstanceId</method-name>
<method-params>
@@ -293,11 +270,9 @@
]]></ejb-ql>
</query>
</entity>
-
</enterprise-beans>
<assembly-descriptor>
-
<container-transaction>
<method>
<ejb-name>CommandServiceBean</ejb-name>
@@ -341,13 +316,13 @@
</container-transaction>
<message-destination>
+ <description>Receiver of job references.</description>
<message-destination-name>JobQueue</message-destination-name>
</message-destination>
<message-destination>
+ <description>Receiver of serialized commands.</description>
<message-destination-name>CommandQueue</message-destination-name>
</message-destination>
-
</assembly-descriptor>
-
</ejb-jar>
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/resources/META-INF/jboss.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/resources/META-INF/jboss.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/main/resources/META-INF/jboss.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -24,10 +24,6 @@
<res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
<jndi-name>java:JmsXA</jndi-name>
</resource-ref>
- <message-destination-ref>
- <message-destination-ref-name>jms/DeadLetterQueue</message-destination-ref-name>
- <jndi-name>jnp://${jboss.bind.address}:1100/queue/DLQ</jndi-name>
- </message-destination-ref>
</message-driven>
<message-driven>
@@ -36,10 +32,6 @@
<res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
<jndi-name>java:JmsXA</jndi-name>
</resource-ref>
- <message-destination-ref>
- <message-destination-ref-name>jms/DeadLetterQueue</message-destination-ref-name>
- <jndi-name>jnp://${jboss.bind.address}:1100/queue/DLQ</jndi-name>
- </message-destination-ref>
</message-driven>
<entity>
@@ -52,12 +44,12 @@
<assembly-descriptor>
<message-destination>
<message-destination-name>JobQueue</message-destination-name>
- <jndi-name>jnp://${jboss.bind.address}:1100/queue/JbpmJobQueue</jndi-name>
+ <jndi-name>queue/JbpmJobQueue</jndi-name>
</message-destination>
<message-destination>
<message-destination-name>CommandQueue</message-destination-name>
- <jndi-name>jnp://${jboss.bind.address}:1100/queue/JbpmCommandQueue</jndi-name>
+ <jndi-name>queue/JbpmCommandQueue</jndi-name>
</message-destination>
</assembly-descriptor>
</jboss>
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/AbstractEnterpriseTestCase.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/AbstractEnterpriseTestCase.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/AbstractEnterpriseTestCase.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -59,7 +59,6 @@
private List processDefinitions = new ArrayList();
private static Context environment;
- private static LocalCommandServiceHome commandServiceHome;
private static final Log log = LogFactory.getLog(AbstractEnterpriseTestCase.class);
@@ -82,10 +81,19 @@
}
protected CommandService createCommandService() throws Exception {
- if (commandServiceHome == null) {
- commandServiceHome = (LocalCommandServiceHome) getEnvironment().lookup("ejb/CommandServiceBean");
+ Object object = getEnvironment().lookup("ejb/CommandServiceBean");
+ CommandService commandService;
+
+ if (object instanceof CommandService) {
+ // compatibility with EJB3 homeless beans
+ commandService = (CommandService) object;
}
- return new RetryCommandService(commandServiceHome.create());
+ else {
+ LocalCommandServiceHome home = (LocalCommandServiceHome) object;
+ commandService = home.create();
+ }
+
+ return new RetryCommandService(commandService);
}
protected ProcessDefinition deployProcessDefinition(String xml) {
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/ArchiveDeployer.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/ArchiveDeployer.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/ArchiveDeployer.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -34,10 +34,10 @@
/**
* Deploy the given archive
*/
- void deploy(URL archive) throws Exception;
+ void deploy(URL archive) throws DeploymentException;
/**
* Undeploy the given archive
*/
- void undeploy(URL archive) throws Exception;
+ void undeploy(URL archive) throws DeploymentException;
}
Added: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/DeploymentException.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/DeploymentException.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/DeploymentException.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,42 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.enterprise;
+
+/**
+ * @author Alejandro Guizar
+ */
+public class DeploymentException extends Exception {
+
+ private static final long serialVersionUID = 1L;
+
+ public DeploymentException() {
+ }
+
+ public DeploymentException(String message) {
+ super(message);
+ }
+
+ public DeploymentException(String message, Throwable cause) {
+ super(message, cause);
+ }
+
+}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/DeploymentException.java
___________________________________________________________________
Name: svn:eol-style
+ native
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/IntegrationTestHelper.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/IntegrationTestHelper.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/IntegrationTestHelper.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -22,17 +22,17 @@
package org.jbpm.enterprise;
import java.io.File;
+import java.io.FileNotFoundException;
import java.io.IOException;
import java.net.URL;
-import java.util.Hashtable;
import javax.management.JMException;
import javax.management.MBeanServerConnection;
import javax.management.ObjectName;
-import javax.naming.InitialContext;
import javax.naming.NamingException;
import org.jbpm.JbpmException;
+import org.jbpm.util.JndiUtil;
/**
* An integration test helper that deals with test deployment/undeployment, etc.
@@ -53,24 +53,21 @@
public String getTestResourcesDir() {
if (testResourcesDir == null) {
- testResourcesDir = System.getProperty(SYSPROP_TEST_RESOURCES_DIRECTORY, "target/test-classes");
+ testResourcesDir = System.getProperty(SYSPROP_TEST_RESOURCES_DIRECTORY,
+ "target/test-classes");
}
return testResourcesDir;
}
/** Try to discover the File for the test resource */
- public File getResourceFile(String resource) {
+ public File getResourceFile(String resource) throws FileNotFoundException {
File file = new File(resource);
if (file.exists()) return file;
file = new File(getTestResourcesDir() + "/" + resource);
if (file.exists()) return file;
- throw new IllegalArgumentException("Cannot obtain '"
- + getTestResourcesDir()
- + "/"
- + resource
- + "'");
+ throw new FileNotFoundException("resource not found: " + resource);
}
public String getTestArchiveDir() {
@@ -81,39 +78,32 @@
}
/** Try to discover the File for the deployment archive */
- public File getTestArchiveFile(String archive) {
+ public File getTestArchiveFile(String archive) throws FileNotFoundException {
File file = new File(archive);
if (file.exists()) return file;
file = new File(getTestArchiveDir() + "/" + archive);
if (file.exists()) return file;
- String notSet = getTestArchiveDir() == null ? " System property '"
- + SYSPROP_TEST_ARCHIVE_DIRECTORY
- + "' not set." : "";
- throw new IllegalArgumentException("Cannot obtain '"
- + getTestArchiveDir()
- + "/"
- + archive
- + "'."
- + notSet);
+ throw new FileNotFoundException("test archive not found: " + getTestArchiveDir() + "/"
+ + archive);
}
- public void deploy(String archive) throws Exception {
+ public void deploy(String archive) throws IOException, DeploymentException {
URL url = getTestArchiveFile(archive).toURI().toURL();
deploy(url);
}
- public void deploy(URL archive) throws Exception {
+ public void deploy(URL archive) throws DeploymentException {
getDeployer().deploy(archive);
}
- public void undeploy(String archive) throws Exception {
+ public void undeploy(String archive) throws IOException, DeploymentException {
URL url = getTestArchiveFile(archive).toURI().toURL();
undeploy(url);
}
- public void undeploy(URL archive) throws Exception {
+ public void undeploy(URL archive) throws DeploymentException {
getDeployer().undeploy(archive);
}
@@ -125,10 +115,10 @@
jbossVersion = (String) getServer().getAttribute(oname, "Version");
}
catch (JMException e) {
- throw new JbpmException("cannot obtain jboss version", e);
+ throw new JbpmException("failed to determine jboss version", e);
}
catch (IOException e) {
- throw new JbpmException("cannot obtain jboss version", e);
+ throw new JbpmException("failed to determine jboss version", e);
}
if (jbossVersion.startsWith("5.1.0"))
@@ -147,15 +137,11 @@
public MBeanServerConnection getServer() {
if (server == null) {
- Hashtable jndiEnv = null;
try {
- InitialContext iniCtx = new InitialContext();
- jndiEnv = iniCtx.getEnvironment();
- server = (MBeanServerConnection) iniCtx.lookup("jmx/invoker/RMIAdaptor");
+ server = (MBeanServerConnection) JndiUtil.lookup("jmx/invoker/RMIAdaptor");
}
catch (NamingException ex) {
- throw new RuntimeException("Cannot obtain MBeanServerConnection using jndi props: "
- + jndiEnv, ex);
+ throw new JbpmException("failed to retrieve mbean server connection", ex);
}
}
return server;
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/IntegrationTestSetup.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/IntegrationTestSetup.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/IntegrationTestSetup.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -21,15 +21,6 @@
*/
package org.jbpm.enterprise;
-import java.io.File;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.net.URLClassLoader;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.management.MBeanServerConnection;
-
import junit.extensions.TestSetup;
import junit.framework.TestSuite;
@@ -41,73 +32,38 @@
*/
public class IntegrationTestSetup extends TestSetup {
- private IntegrationTestHelper delegate = new IntegrationTestHelper();
- private String[] archives;
- private ClassLoader originalClassLoader;
+ private final IntegrationTestHelper helper = new IntegrationTestHelper();
+ private final String[] archives;
public IntegrationTestSetup(Class testClass, String archiveList) {
super(new TestSuite(testClass));
- archives = getArchiveArray(archiveList);
+ archives = archiveList == null ? new String[0] : archiveList.split("[\\s,]+");
}
- public File getArchiveFile(String archive) {
- return delegate.getTestArchiveFile(archive);
+ public IntegrationTestHelper getHelper() {
+ return helper;
}
- public URL getArchiveURL(String archive) throws MalformedURLException {
- return delegate.getTestArchiveFile(archive).toURI().toURL();
- }
-
- public MBeanServerConnection getServer() {
- return delegate.getServer();
- }
-
- private String[] getArchiveArray(String archiveList) {
- return archiveList == null ? new String[0] : archiveList.split("[\\s,]+");
- }
-
protected void setUp() throws Exception {
super.setUp();
- List clientJars = new ArrayList();
for (int i = 0; i < archives.length; i++) {
String archive = archives[i];
try {
- delegate.deploy(archive);
+ helper.deploy(archive);
}
- catch (Exception ex) {
- ex.printStackTrace();
- delegate.undeploy(archive);
+ catch (DeploymentException ex) {
+ helper.undeploy(archive);
+ throw ex;
}
-
- if (archive.endsWith("-client.jar")) {
- URL archiveURL = getArchiveURL(archive);
- clientJars.add(archiveURL);
- }
}
-
- ClassLoader parent = Thread.currentThread().getContextClassLoader();
- originalClassLoader = parent;
-
- // add client jars to the class loader
- if (!clientJars.isEmpty()) {
- URL[] urls = new URL[clientJars.size()];
- clientJars.toArray(urls);
- URLClassLoader cl = new URLClassLoader(urls, parent);
- Thread.currentThread().setContextClassLoader(cl);
- }
}
protected void tearDown() throws Exception {
- try {
- for (int i = 0; i < archives.length; i++) {
- String archive = archives[archives.length - i - 1];
- delegate.undeploy(archive);
- }
+ for (int i = 0; i < archives.length; i++) {
+ String archive = archives[archives.length - i - 1];
+ helper.undeploy(archive);
}
- finally {
- Thread.currentThread().setContextClassLoader(originalClassLoader);
- }
super.tearDown();
}
}
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/JBossArchiveDeployer.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/JBossArchiveDeployer.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/JBossArchiveDeployer.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -21,8 +21,10 @@
*/
package org.jbpm.enterprise;
+import java.io.IOException;
import java.net.URL;
+import javax.management.JMException;
import javax.management.MBeanServerConnection;
import javax.management.ObjectName;
@@ -42,16 +44,24 @@
this.server = server;
}
- public void deploy(URL url) throws Exception {
+ public void deploy(URL url) throws DeploymentException {
invokeMainDeployer("deploy", url);
}
- public void undeploy(URL url) throws Exception {
+ public void undeploy(URL url) throws DeploymentException {
invokeMainDeployer("undeploy", url);
}
- private void invokeMainDeployer(String methodName, URL url) throws Exception {
- server.invoke(new ObjectName(MAIN_DEPLOYER), methodName, new Object[] { url },
+ private void invokeMainDeployer(String methodName, URL url) throws DeploymentException {
+ try {
+ server.invoke(new ObjectName(MAIN_DEPLOYER), methodName, new Object[] { url },
new String[] { "java.net.URL" });
+ }
+ catch (JMException e) {
+ throw new DeploymentException(methodName + " failed", e);
+ }
+ catch (IOException e) {
+ throw new DeploymentException(methodName + " failed", e);
+ }
}
}
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/config/AppServerConfigurationsTest.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/config/AppServerConfigurationsTest.java 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/java/org/jbpm/enterprise/config/AppServerConfigurationsTest.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -24,11 +24,11 @@
import junit.framework.Test;
import org.apache.cactus.ServletTestCase;
+
import org.jbpm.JbpmConfiguration;
import org.jbpm.enterprise.IntegrationTestSetup;
-import org.jbpm.msg.jms.JmsMessageServiceFactory;
import org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory;
-import org.jbpm.scheduler.ejbtimer.EntitySchedulerServiceFactory;
+import org.jbpm.svc.ServiceFactory;
import org.jbpm.svc.Services;
public class AppServerConfigurationsTest extends ServletTestCase {
@@ -48,30 +48,46 @@
}
public void testJtaDbPersistenceFactoryConfiguration() {
- String expService = JtaDbPersistenceServiceFactory.class.getName();
- String wasService = jbpmConfiguration.getServiceFactory(Services.SERVICENAME_PERSISTENCE)
- .getClass()
- .getName();
- assertEquals(expService, wasService);
+ ServiceFactory serviceFactory = jbpmConfiguration.getServiceFactory(Services.SERVICENAME_PERSISTENCE);
+ assertSame(JtaDbPersistenceServiceFactory.class, serviceFactory.getClass());
- JtaDbPersistenceServiceFactory persistenceServiceFactory = (JtaDbPersistenceServiceFactory) jbpmConfiguration.getServiceFactory(Services.SERVICENAME_PERSISTENCE);
+ JtaDbPersistenceServiceFactory persistenceServiceFactory = (JtaDbPersistenceServiceFactory) serviceFactory;
assertFalse(persistenceServiceFactory.isTransactionEnabled());
assertTrue(persistenceServiceFactory.isCurrentSessionEnabled());
}
public void testJmsMessageServiceFactoryConfiguration() {
- String expService = JmsMessageServiceFactory.class.getName();
- String wasService = jbpmConfiguration.getServiceFactory(Services.SERVICENAME_MESSAGE)
- .getClass()
- .getName();
- assertEquals(expService, wasService);
+ Class serviceClass;
+ try {
+ serviceClass = Class.forName("org.jbpm.msg.jms.JmsMessageServiceFactory");
+ }
+ catch (ClassNotFoundException e) {
+ try {
+ serviceClass = Class.forName("org.jbpm.jms.JmsConnectorServiceFactory");
+ }
+ catch (ClassNotFoundException e2) {
+ throw new AssertionError(e2);
+ }
+ }
+
+ assertSame(serviceClass, jbpmConfiguration.getServiceFactory(Services.SERVICENAME_MESSAGE)
+ .getClass());
}
public void testEjbSchedulerServiceFactoryConfiguration() {
- String expService = EntitySchedulerServiceFactory.class.getName();
- String wasService = jbpmConfiguration.getServiceFactory(Services.SERVICENAME_SCHEDULER)
- .getClass()
- .getName();
- assertEquals(expService, wasService);
+ Class serviceClass;
+ try {
+ serviceClass = Class.forName("org.jbpm.scheduler.ejbtimer.EntitySchedulerServiceFactory");
+ }
+ catch (ClassNotFoundException e) {
+ try {
+ serviceClass = Class.forName("org.jbpm.jms.JmsConnectorServiceFactory");
+ }
+ catch (ClassNotFoundException e2) {
+ throw new AssertionError(e2);
+ }
+ }
+ assertSame(serviceClass,
+ jbpmConfiguration.getServiceFactory(Services.SERVICENAME_SCHEDULER).getClass());
}
}
Deleted: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/resources/jndi.properties
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/resources/jndi.properties 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/resources/jndi.properties 2010-09-26 00:44:51 UTC (rev 6683)
@@ -1,3 +0,0 @@
-java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
-java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
-java.naming.provider.url=jnp://@jboss.bind.address@:1099
Modified: jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/webapp/WEB-INF/jboss-web.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/webapp/WEB-INF/jboss-web.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise/src/test/webapp/WEB-INF/jboss-web.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -20,6 +20,6 @@
<message-destination-ref>
<message-destination-ref-name>jms/JobQueue</message-destination-ref-name>
- <jndi-name>jnp://${jboss.bind.address}:1100/queue/JbpmJobQueue</jndi-name>
+ <jndi-name>queue/JbpmJobQueue</jndi-name>
</message-destination-ref>
</jboss-web>
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5
___________________________________________________________________
Name: svn:ignore
+ target
.settings
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/.classpath
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/.classpath (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/.classpath 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" output="target/classes" path="src/main/java"/>
+ <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
+ <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/.project
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/.project (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/.project 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>jbpm-ejb3</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.maven.ide.eclipse.maven2Builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.maven.ide.eclipse.maven2Nature</nature>
+ </natures>
+</projectDescription>
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/pom.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/pom.xml (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/pom.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,78 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <name>jBPM3 - EJB3</name>
+ <groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jbpm-enterprise-jee5</artifactId>
+ <packaging>ejb</packaging>
+
+ <parent>
+ <groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jbpm</artifactId>
+ <version>3.2.10-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
+
+ <plugin>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <configuration>
+ <source>1.5</source>
+ </configuration>
+ </plugin>
+
+ <plugin>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>assembly-config</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <descriptors>
+ <descriptor>scripts/assembly-config.xml</descriptor>
+ </descriptors>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jbpm-jpdl</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.jms</groupId>
+ <artifactId>jms</artifactId>
+ <version>1.1</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.ejb</groupId>
+ <artifactId>ejb-api</artifactId>
+ <version>3.0</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.annotation</groupId>
+ <artifactId>jsr250-api</artifactId>
+ <version>1.0</version>
+ <scope>provided</scope>
+ </dependency>
+ </dependencies>
+</project>
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/pom.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/scripts/assembly-config.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/scripts/assembly-config.xml (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/scripts/assembly-config.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+
+<!-- ====================================================================== -->
+<!-- jBPM: Workflow in Java -->
+<!-- -->
+<!-- Distributable under LGPL license. -->
+<!-- See terms of license at http://www.gnu.org. -->
+<!-- ====================================================================== -->
+
+<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
+ <id>config</id>
+ <formats>
+ <format>jar</format>
+ </formats>
+ <includeBaseDirectory>false</includeBaseDirectory>
+ <fileSets>
+ <fileSet>
+ <directory>${basedir}/src/main/etc</directory>
+ <outputDirectory>/</outputDirectory>
+ </fileSet>
+ </fileSets>
+</assembly>
\ No newline at end of file
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/scripts/assembly-config.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/hibernate.extra.hbm.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/hibernate.extra.hbm.xml (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/hibernate.extra.hbm.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,13 @@
+<?xml version="1.0"?>
+
+<!DOCTYPE hibernate-mapping PUBLIC
+ "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
+ "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
+
+<hibernate-mapping>
+
+ <!-- ################################################## -->
+ <!-- # Additional mappings defined per module go here # -->
+ <!-- ################################################## -->
+
+</hibernate-mapping>
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/hibernate.extra.hbm.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.cfg.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.cfg.xml (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.cfg.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,40 @@
+<jbpm-configuration>
+
+ <bean name="jbpm.jms.connector.service" class="org.jbpm.jms.JmsConnectorServiceFactory"
+ singleton="true">
+ <field name="jbpmConfiguration">
+ <ref bean="jbpm.configuration" />
+ </field>
+ </bean>
+
+ <jbpm-context>
+ <service name="persistence" factory="org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory" />
+ <service name="message">
+ <factory>
+ <ref bean="jbpm.jms.connector.service" />
+ </factory>
+ </service>
+ <service name="scheduler">
+ <factory>
+ <ref bean="jbpm.jms.connector.service" />
+ </factory>
+ </service>
+ <service name="tx" factory="org.jbpm.tx.TxServiceFactory" />
+ <service name="logging" factory="org.jbpm.logging.db.DbLoggingServiceFactory" />
+ <service name="authentication" factory="org.jbpm.security.authentication.DefaultAuthenticationServiceFactory" />
+ </jbpm-context>
+
+ <!-- employ the context class loader -->
+ <string name="jbpm.class.loader" value="context" />
+
+ <!-- High-availability JNDI properties (begin) ===
+ <string name="resource.jndi.properties" value="jbpm.jndi.properties" />
+ ==== High-availability JNDI properties (end) -->
+
+ <!--
+ There should be no job executor in the enterprise configuration.
+ The message and scheduler services are both bound to JMS.
+ -->
+ <null name="jbpm.job.executor" />
+
+</jbpm-configuration>
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.cfg.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.jndi.properties
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.jndi.properties (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.jndi.properties 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,2 @@
+java.naming.provider.url=jnp://${jboss.bind.address}:1100,jnp://${jboss.bind.address}
+jnp.partitionName=${jboss.partition.name}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/etc/jbpm.jndi.properties
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/LocalCommandService.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/LocalCommandService.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/LocalCommandService.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,30 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.ejb;
+
+import javax.ejb.Local;
+
+import org.jbpm.command.CommandService;
+
+@Local
+public interface LocalCommandService extends CommandService {
+}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/LocalCommandService.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,215 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.ejb.impl;
+
+import java.io.Serializable;
+
+import javax.annotation.PostConstruct;
+import javax.annotation.PreDestroy;
+import javax.annotation.Resource;
+import javax.ejb.ActivationConfigProperty;
+import javax.ejb.EJB;
+import javax.ejb.MessageDriven;
+import javax.ejb.MessageDrivenContext;
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.Destination;
+import javax.jms.JMSException;
+import javax.jms.Message;
+import javax.jms.MessageListener;
+import javax.jms.ObjectMessage;
+import javax.jms.Session;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.jbpm.JbpmException;
+import org.jbpm.command.Command;
+import org.jbpm.ejb.LocalCommandService;
+import org.jbpm.persistence.db.DbPersistenceService;
+import org.jbpm.persistence.db.StaleObjectLogConfigurer;
+
+/**
+ * This message-driven bean listens for {@link ObjectMessage object messages} containing a
+ * command instance. The received commands are executed by the {@link CommandServiceBean command
+ * service} bean, using the local interface.
+ *
+ * The body of the message must be a Java object that implements the {@link Command} interface.
+ * The message properties, if any, are ignored.
+ *
+ * <h3>Environment</h3>
+ *
+ * <p>
+ * The environment entries and resources available for customization are summarized in the table
+ * below.
+ * </p>
+ *
+ * <table border="1">
+ * <tr>
+ * <th>Name</th>
+ * <th>Type</th>
+ * <th>Description</th>
+ * </tr>
+ * <tr>
+ * <td><code>ejb/LocalCommandService</code></td>
+ * <td>EJB Reference</td>
+ * <td>Link to the local {@linkplain CommandServiceBean session bean} that executes commands on
+ * a separate jBPM context.</td>
+ * </tr>
+ * <tr>
+ * <td><code>jms/JbpmConnectionFactory</code></td>
+ * <td>Resource Manager Reference</td>
+ * <td>Logical name of the factory that provides JMS connections for producing result messages.
+ * Required for command messages that indicate a reply destination.</td>
+ * </tr>
+ * </table>
+ *
+ * @author Alejandro Guizar
+ */
+@MessageDriven(activationConfig = {
+ @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue")
+})
+public class CommandListenerBean implements MessageListener {
+
+ private static final long serialVersionUID = 1L;
+
+ @Resource
+ private MessageDrivenContext messageDrivenContext;
+ @EJB(name = "ejb/LocalCommandService")
+ private LocalCommandService commandService;
+ @Resource(name = "jms/JbpmConnectionFactory")
+ private ConnectionFactory jmsConnectionFactory;
+
+ private Connection jmsConnection;
+
+ private static final Log log = LogFactory.getLog(CommandListenerBean.class);
+
+ @PostConstruct
+ void createConnection() {
+ Object cs = messageDrivenContext.lookup("ejb/LocalCommandService");
+ if (!(cs instanceof LocalCommandService)) {
+ throw new AssertionError(cs);
+ }
+ try {
+ jmsConnection = jmsConnectionFactory.createConnection();
+ }
+ catch (JMSException e) {
+ throw new JbpmException("failed to create jms connection", e);
+ }
+ }
+
+ @PreDestroy
+ void closeConnection() {
+ if (jmsConnection != null) {
+ try {
+ jmsConnection.close();
+ }
+ catch (JMSException e) {
+ log.debug("failed to close jms connection", e);
+ }
+ }
+ }
+
+ public void onMessage(Message message) {
+ try {
+ // extract command from message
+ Command command = extractCommand(message);
+ if (command == null) return;
+ try {
+ // execute command via local command executor bean
+ Object result = commandService.execute(command);
+ // send a response back if a "reply to" destination is set
+ Destination replyTo = message.getJMSReplyTo();
+ if (replyTo != null && (result instanceof Serializable || result == null)) {
+ sendResult((Serializable) result, replyTo, message.getJMSMessageID());
+ }
+ }
+ catch (RuntimeException e) {
+ // MDBs are not supposed to throw exceptions
+ messageDrivenContext.setRollbackOnly();
+ // if this is a locking exception, keep it quiet
+ if (DbPersistenceService.isLockingException(e)) {
+ StaleObjectLogConfigurer.getStaleObjectExceptionsLog().error("failed to execute "
+ + command,
+ e);
+ }
+ else {
+ log.error("failed to execute " + command, e);
+ }
+ }
+ }
+ catch (JMSException e) {
+ messageDrivenContext.setRollbackOnly();
+ log.error("failed to process message " + message, e);
+ }
+ }
+
+ /**
+ * Retrieves a {@link Command} instance from the given message, which is assumed to be an
+ * {@link ObjectMessage}.
+ * <p>
+ * Subclasses may override this method to materialize the command in some other way.
+ * </p>
+ */
+ protected Command extractCommand(Message message) throws JMSException {
+ if (message instanceof ObjectMessage) {
+ ObjectMessage objectMessage = (ObjectMessage) message;
+ Serializable object = objectMessage.getObject();
+ if (object instanceof Command) {
+ return (Command) object;
+ }
+ else {
+ log.warn("not a command: " + object);
+ }
+ }
+ else {
+ log.warn("not an object message: " + message);
+ }
+ return null;
+ }
+
+ private void sendResult(Serializable result, Destination destination, String correlationId)
+ throws JMSException {
+ if (log.isDebugEnabled()) log.debug("sending " + result + " to " + destination);
+ Session jmsSession = createSession();
+ try {
+ Message resultMessage = jmsSession.createObjectMessage(result);
+ resultMessage.setJMSCorrelationID(correlationId);
+ jmsSession.createProducer(destination).send(resultMessage);
+ }
+ finally {
+ jmsSession.close();
+ }
+ }
+
+ private Session createSession() throws JMSException {
+ if (jmsConnection == null) {
+ jmsConnection = jmsConnectionFactory.createConnection();
+ }
+ /*
+ * if the connection supports xa, the session will be transacted, else the session will auto
+ * acknowledge; in either case no explicit transaction control must be performed - see ejb
+ * 2.1 - 17.3.5
+ */
+ return jmsConnection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+ }
+}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandListenerBean.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,140 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.ejb.impl;
+
+import javax.annotation.PostConstruct;
+import javax.annotation.Resource;
+import javax.annotation.Resources;
+import javax.ejb.SessionContext;
+import javax.ejb.Stateless;
+import javax.jms.ConnectionFactory;
+import javax.jms.Queue;
+import javax.sql.DataSource;
+
+import org.jbpm.JbpmConfiguration;
+import org.jbpm.JbpmContext;
+import org.jbpm.JbpmException;
+import org.jbpm.command.Command;
+import org.jbpm.ejb.LocalCommandService;
+import org.jbpm.jms.JmsConnectorServiceFactory;
+import org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory;
+
+/**
+ * Stateless session bean that executes {@linkplain Command commands} by calling their
+ * {@link Command#execute(JbpmContext) execute} method on a separate {@link JbpmContext jBPM
+ * context}.
+ *
+ * <h3>Environment</h3>
+ *
+ * <p>
+ * The environment entries and resources available for customization are summarized in the table
+ * below.
+ * </p>
+ *
+ * <table border="1">
+ * <tr>
+ * <th>Name</th>
+ * <th>Type</th>
+ * <th>Description</th>
+ * </tr>
+ * <tr>
+ * <td><code>JbpmCfgResource</code></td>
+ * <td>Environment Entry</td>
+ * <td>The classpath resource from which to read the {@linkplain JbpmConfiguration jBPM
+ * configuration}. Optional, defaults to <code>
+ * jbpm.cfg.xml</code>.</td>
+ * </tr>
+ * <tr>
+ * <td><code>jdbc/JbpmDataSource</code></td>
+ * <td>Resource Manager Reference</td>
+ * <td>Logical name of the data source that provides JDBC connections to the
+ * {@linkplain JtaDbPersistenceServiceFactory persistence service}. Must match the
+ * <code>hibernate.connection.datasource</code> property in the Hibernate configuration file.</td>
+ * </tr>
+ * <tr>
+ * <td><code>jms/JbpmConnectionFactory</code></td>
+ * <td>Resource Manager Reference</td>
+ * <td>Logical name of the factory that provides JMS connections to the
+ * {@linkplain JmsConnectorServiceFactory JMS connector service}. Required for processes that
+ * contain asynchronous continuations.</td>
+ * </tr>
+ * <tr>
+ * <td><code>jms/JobQueue</code></td>
+ * <td>Message Destination Reference</td>
+ * <td>The message service sends job messages to the queue referenced here. To ensure this is
+ * the same queue from which the {@linkplain JobListenerBean job listener bean} receives
+ * messages, the <code>message-destination-link</code> points to a common logical destination,
+ * <code>JobQueue</code>.</td>
+ * </tr>
+ * </table>
+ *
+ * @author Alejandro Guizar
+ */
+@Stateless
+@Resources(value = {
+ @Resource(name = "jdbc/JbpmDataSource", type = DataSource.class),
+ @Resource(name = "jms/JbpmConnectionFactory", type = ConnectionFactory.class),
+ @Resource(name = "jms/JobQueue", type = Queue.class)
+})
+public class CommandServiceBean implements LocalCommandService {
+
+ private static final long serialVersionUID = 1L;
+
+ @Resource
+ private SessionContext sessionContext;
+ @Resource(name = "JbpmCfgResource")
+ private String jbpmCfgResource;
+
+ private JbpmConfiguration jbpmConfiguration;
+
+ /**
+ * Creates the {@link JbpmConfiguration} to be used by this command service. In case the
+ * environment key <code>JbpmCfgResource</code> is specified, that value is interpreted as the
+ * name of the configuration resource to load from the classpath. If that key is absent, the
+ * default configuration file will be used (jbpm.cfg.xml).
+ */
+ @PostConstruct
+ void createConfiguration() {
+ jbpmConfiguration = JbpmConfiguration.getInstance(jbpmCfgResource);
+ }
+
+ public Object execute(Command command) {
+ JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
+ try {
+ Object result = command.execute(jbpmContext);
+ // check whether command requested a rollback
+ if (jbpmContext.getServices().getTxService().isRollbackOnly()) {
+ sessionContext.setRollbackOnly();
+ }
+ return result;
+ }
+ catch (RuntimeException e) {
+ throw e;
+ }
+ catch (Exception e) {
+ throw new JbpmException("failed to execute " + command, e);
+ }
+ finally {
+ jbpmContext.close();
+ }
+ }
+}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/CommandServiceBean.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,110 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.ejb.impl;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.jbpm.JbpmContext;
+import org.jbpm.command.Command;
+import org.jbpm.graph.exe.ProcessInstance;
+import org.jbpm.job.Job;
+import org.jbpm.job.Timer;
+import org.jbpm.scheduler.SchedulerService;
+
+/**
+ * Individual job processing command.
+ *
+ * @author Alejandro Guizar
+ */
+public class ExecuteJobCommand implements Command {
+
+ private final long jobId;
+
+ private static final long serialVersionUID = 1L;
+ private static final Log log = LogFactory.getLog(ExecuteJobCommand.class.getName());
+
+ public ExecuteJobCommand(long jobId) {
+ this.jobId = jobId;
+ }
+
+ public Object execute(JbpmContext jbpmContext) throws Exception {
+ Job job = acquireJob(jobId, jbpmContext);
+ if (job != null) executeJob(job, jbpmContext);
+ return job;
+ }
+
+ private static Job acquireJob(long jobId, JbpmContext jbpmContext) {
+ boolean debug = log.isDebugEnabled();
+ if (debug) log.debug("acquiring job: " + jobId);
+ Job job = jbpmContext.getJobSession().getJob(jobId);
+
+ // job could have been deleted manually
+ // or by ending the process instance
+ if (job != null) {
+ // register process instance for automatic save
+ // see https://jira.jboss.org/jira/browse/JBPM-1015
+ ProcessInstance processInstance = job.getProcessInstance();
+ jbpmContext.addAutoSaveProcessInstance(processInstance);
+
+ // if job is exclusive, lock process instance
+ if (job.isExclusive()) {
+ jbpmContext.getGraphSession().lockProcessInstance(processInstance);
+ }
+
+ // mark job as locked to prevent it from being deleted
+ job.setLockOwner(Thread.currentThread().getName());
+ if (debug) log.debug("acquired " + job);
+ }
+ else {
+ log.warn("job not found: " + jobId);
+ }
+
+ return job;
+ }
+
+ private static void executeJob(Job job, JbpmContext jbpmContext) throws Exception {
+ if (log.isDebugEnabled()) log.debug("executing " + job);
+ if (job.execute(jbpmContext)) {
+ if (job instanceof Timer) {
+ Timer timer = (Timer) job;
+ SchedulerService schedulerService = jbpmContext.getServices().getSchedulerService();
+ // if the timer has repeat
+ if (timer.getRepeat() != null) {
+ // create a new timer
+ if (log.isDebugEnabled()) {
+ log.debug("scheduling timer for repeat on " + timer.getDueDate());
+ }
+ schedulerService.createTimer(timer);
+ }
+ else {
+ // clear timer
+ schedulerService.deleteTimer((Timer) job);
+ }
+ }
+ else {
+ // clear job
+ jbpmContext.getJobSession().deleteJob(job);
+ }
+ }
+ }
+}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/ExecuteJobCommand.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,48 @@
+package org.jbpm.ejb.impl;
+
+import javax.ejb.ActivationConfigProperty;
+import javax.ejb.MessageDriven;
+import javax.jms.JMSException;
+import javax.jms.Message;
+import javax.jms.MessageListener;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.jbpm.command.Command;
+
+/**
+ * Message-driven bean that listens for {@link Message messages} containing a reference to a
+ * pending {@linkplain org.jbpm.job.Job job} for asynchronous continuations.
+ * <p>
+ * The message must have a <code>long</code> property called <code>jobId</code> which identifies
+ * a job in the database. The message body, if any, is ignored.
+ * </p>
+ * <h3>Environment</h3>
+ * <p>
+ * This bean inherits its environment entries and resources available for customization from
+ * {@link CommandListenerBean}.
+ * </p>
+ *
+ * @author Alejandro Guizar
+ */
+@MessageDriven(messageListenerInterface = MessageListener.class, activationConfig = {
+ @ActivationConfigProperty(propertyName = "destinationType", propertyValue = "javax.jms.Queue")
+})
+public class JobListenerBean extends CommandListenerBean {
+
+ private static final long serialVersionUID = 1L;
+ private static final Log log = LogFactory.getLog(JobListenerBean.class);
+
+ protected Command extractCommand(Message message) throws JMSException {
+ // checking for jobId property
+ if (message.propertyExists("jobId")) {
+ long jobId = message.getLongProperty("jobId");
+ return new ExecuteJobCommand(jobId);
+ }
+ else {
+ log.warn("property jobId not found");
+ }
+ return null;
+ }
+}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/ejb/impl/JobListenerBean.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,134 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.jms;
+
+import javax.jms.Connection;
+import javax.jms.JMSException;
+import javax.jms.Message;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+
+import org.jbpm.JbpmContext;
+import org.jbpm.JbpmException;
+import org.jbpm.db.JobSession;
+import org.jbpm.graph.exe.ProcessInstance;
+import org.jbpm.graph.exe.Token;
+import org.jbpm.job.Job;
+import org.jbpm.job.Timer;
+import org.jbpm.msg.MessageService;
+import org.jbpm.scheduler.SchedulerService;
+
+public class JmsConnectorService implements MessageService, SchedulerService {
+
+ private static final long serialVersionUID = 1L;
+
+ private static final Log log = LogFactory.getLog(JmsConnectorService.class);
+
+ private final JobSession jobSession;
+
+ private final Connection connection;
+ private final Session session;
+ private final MessageProducer messageProducer;
+
+ public JmsConnectorService(JmsConnectorServiceFactory factory) throws JMSException {
+ JbpmContext jbpmContext = factory.getJbpmConfiguration().getCurrentJbpmContext();
+ if (jbpmContext == null) throw new JbpmException("no active jbpm context");
+ jobSession = jbpmContext.getJobSession();
+
+ this.connection = factory.getConnectionFactory().createConnection();
+ /*
+ * if the connection supports xa, the session will be transacted, else the session will auto
+ * acknowledge; in either case no explicit transaction control must be performed - see ejb
+ * 2.1 - 17.3.5
+ */
+ session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+ messageProducer = session.createProducer(factory.getDestination());
+ }
+
+ public Session getSession() {
+ return session;
+ }
+
+ public void send(Job job) {
+ jobSession.saveJob(job);
+
+ try {
+ Message message = session.createMessage();
+ populateMessage(message, job);
+ messageProducer.send(message);
+ }
+ catch (JMSException e) {
+ throw new JbpmException("could not send jms message", e);
+ }
+ }
+
+ protected void populateMessage(Message message, Job job) throws JMSException {
+ message.setLongProperty("jobId", job.getId());
+
+ if (job instanceof Timer) {
+ Timer timer = (Timer) job;
+ message.setLongProperty("JMS_JBOSS_SCHEDULED_DELIVERY", timer.getDueDate().getTime());
+ }
+ }
+
+ public void createTimer(Timer timer) {
+ send(timer);
+ }
+
+ public void deleteTimer(Timer timer) {
+ jobSession.deleteJob(timer);
+ }
+
+ public void deleteTimersByName(String timerName, Token token) {
+ jobSession.deleteTimersByName(timerName, token);
+ }
+
+ public void deleteTimersByProcessInstance(ProcessInstance processInstance) {
+ jobSession.deleteJobsForProcessInstance(processInstance);
+ }
+
+ public void close() {
+ try {
+ messageProducer.close();
+ }
+ catch (JMSException e) {
+ log.warn("could not close message producer", e);
+ }
+
+ try {
+ session.close();
+ }
+ catch (JMSException e) {
+ log.warn("could not close jms session", e);
+ }
+
+ try {
+ connection.close();
+ }
+ catch (JMSException e) {
+ log.warn("could not close jms connection", e);
+ }
+ }
+}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorService.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorServiceFactory.java
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorServiceFactory.java (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorServiceFactory.java 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,104 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.jms;
+
+import javax.jms.ConnectionFactory;
+import javax.jms.Destination;
+import javax.jms.JMSException;
+
+import org.jbpm.JbpmConfiguration;
+import org.jbpm.JbpmContext;
+import org.jbpm.JbpmException;
+import org.jbpm.svc.Service;
+import org.jbpm.svc.ServiceFactory;
+import org.jbpm.util.JndiUtil;
+
+/**
+ * The JMS connector service leverages the reliable communication infrastructure available through
+ * JMS interfaces to deliver asynchronous continuation messages to the {@link JobListenerBean}.
+ *
+ * <h3>Configuration</h3>
+ *
+ * The JMS connector service factory exposes the following configurable fields.
+ *
+ * <ul>
+ * <li><code>connectionFactoryJndiName</code></li>
+ * <li><code>destinationJndiName</code></li>
+ * <li><code>isCommitEnabled</code></li>
+ * </ul>
+ *
+ * Refer to the jBPM manual for details.
+ *
+ * @author Tom Baeyens
+ * @author Alejandro Guizar
+ */
+public class JmsConnectorServiceFactory implements ServiceFactory {
+
+ private static final long serialVersionUID = 1L;
+
+ private String connectionFactoryJndiName = "java:comp/env/jms/JbpmConnectionFactory";
+ private String destinationJndiName = "java:comp/env/jms/JobQueue";
+
+ private JbpmConfiguration jbpmConfiguration;
+
+ private ConnectionFactory connectionFactory;
+ private Destination destination;
+
+ public synchronized ConnectionFactory getConnectionFactory() {
+ if (connectionFactory == null) {
+ connectionFactory = (ConnectionFactory) JndiUtil.lookup(connectionFactoryJndiName, ConnectionFactory.class);
+ }
+ return connectionFactory;
+ }
+
+ public synchronized Destination getDestination() {
+ if (destination == null) {
+ destination = (Destination) JndiUtil.lookup(destinationJndiName, Destination.class);
+ }
+ return destination;
+ }
+
+ public JbpmConfiguration getJbpmConfiguration() {
+ // in case this field is not initialized in jbpm configuration
+ if (jbpmConfiguration == null) {
+ JbpmContext jbpmContext = JbpmContext.getCurrentJbpmContext();
+ if (jbpmContext == null) throw new JbpmException("no active jbpm context");
+ jbpmConfiguration = jbpmContext.getJbpmConfiguration();
+ }
+ return jbpmConfiguration;
+ }
+
+ public Service openService() {
+ try {
+ return new JmsConnectorService(this);
+ }
+ catch (JMSException e) {
+ throw new JbpmException("could not open message service", e);
+ }
+ }
+
+ public void close() {
+ connectionFactory = null;
+ destination = null;
+ }
+
+}
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/java/org/jbpm/jms/JmsConnectorServiceFactory.java
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/ejb-jar.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/ejb-jar.xml (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/ejb-jar.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ejb-jar version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+ http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd">
+ <enterprise-beans>
+ <session>
+ <description>Executes commands in a separate context.</description>
+ <display-name>jBPM Command Service</display-name>
+ <ejb-name>CommandServiceBean</ejb-name>
+
+ <resource-ref>
+ <description>
+ Data source that provides the persistence service with connections.
+ Must match property hibernate.connection.datasource in the Hibernate configuration.
+ </description>
+ <res-ref-name>jdbc/JbpmDataSource</res-ref-name>
+ <mapped-name>java:JbpmDS</mapped-name>
+ </resource-ref>
+
+ <resource-ref>
+ <description>
+ Connection factory that provides JMS connections to the message service.
+ Required for processes that contain asynchronous continuations.
+ </description>
+ <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
+ <mapped-name>java:JmsXA</mapped-name>
+ </resource-ref>
+
+ <message-destination-ref>
+ <description>
+ The message service sends job messages to the queue referenced here. To ensure this is the
+ same queue from which the JobListenerBean receives messages, the message-destination-link
+ element points to a common logical destination, JobQueue.
+ </description>
+ <message-destination-ref-name>jms/JobQueue</message-destination-ref-name>
+ <message-destination-usage>Produces</message-destination-usage>
+ <mapped-name>queue/JbpmJobQueue</mapped-name>
+ </message-destination-ref>
+ </session>
+
+ <message-driven>
+ <description>
+ Listens for serialized commands and routes them to the command service session bean.
+ </description>
+ <display-name>jBPM Command Listener</display-name>
+ <ejb-name>CommandListenerBean</ejb-name>
+ <mapped-name>queue/JbpmCommandQueue</mapped-name>
+
+ <resource-ref>
+ <description>
+ Logical name of the factory that provides JMS connections for producing result messages.
+ Required for command messages that indicate a reply destination.
+ </description>
+ <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
+ <mapped-name>java:JmsXA</mapped-name>
+ </resource-ref>
+ </message-driven>
+
+ <message-driven>
+ <description>
+ Listens for job references and delegates execution of the referenced Job to the command
+ service session bean.
+ </description>
+ <display-name>jBPM Job Listener</display-name>
+ <ejb-name>JobListenerBean</ejb-name>
+ <mapped-name>queue/JbpmJobQueue</mapped-name>
+
+ <resource-ref>
+ <description>
+ Logical name of the factory that provides JMS connections for producing result messages.
+ Required for command messages that indicate a reply destination.
+ </description>
+ <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
+ <mapped-name>java:JmsXA</mapped-name>
+ </resource-ref>
+ </message-driven>
+ </enterprise-beans>
+</ejb-jar>
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/ejb-jar.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Added: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/jboss.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/jboss.xml (rev 0)
+++ jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/jboss.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 5.0//EN"
+ "http://www.jboss.org/j2ee/dtd/jboss_5_0.dtd">
+<jboss>
+ <enterprise-beans>
+ <session>
+ <ejb-name>CommandServiceBean</ejb-name>
+ <local-jndi-name>java:jbpm/CommandServiceBean</local-jndi-name>
+ </session>
+ </enterprise-beans>
+</jboss>
Property changes on: jbpm3/branches/jbpm-3.2-soa/enterprise-jee5/src/main/resources/META-INF/jboss.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Modified: jbpm3/branches/jbpm-3.2-soa/pom.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/pom.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/pom.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -35,6 +35,7 @@
<module>core</module>
<module>identity</module>
<module>enterprise</module>
+ <module>enterprise-jee5</module>
<module>examples</module>
<module>simulation</module>
</modules>
@@ -66,9 +67,8 @@
</dependency>
<dependency>
<groupId>org.jbpm.jbpm3</groupId>
- <artifactId>jsf-console</artifactId>
+ <artifactId>jsf-console-jee5</artifactId>
<version>${project.version}</version>
- <classifier>soa</classifier>
<type>war</type>
</dependency>
<dependency>
Modified: jbpm3/branches/jbpm-3.2-soa/soa-distribution/pom.xml
===================================================================
--- jbpm3/branches/jbpm-3.2-soa/soa-distribution/pom.xml 2010-09-26 00:38:17 UTC (rev 6682)
+++ jbpm3/branches/jbpm-3.2-soa/soa-distribution/pom.xml 2010-09-26 00:44:51 UTC (rev 6683)
@@ -10,7 +10,7 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
- <name>jBPM3- Build distribution for SOA-P </name>
+ <name>jBPM3 - SOA Distribution</name>
<groupId>org.jbpm.jbpm3</groupId>
<artifactId>jbpm-soa-distribution</artifactId>
<packaging>pom</packaging>
13 years, 7 months
JBoss JBPM SVN: r6682 - in projects/jsf-console/branches/jsf-console-3.2-soa: console and 7 other directories.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2010-09-25 20:38:17 -0400 (Sat, 25 Sep 2010)
New Revision: 6682
Added:
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/.project
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/pom.xml
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/jboss-web.xml
projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/web.xml
Modified:
projects/jsf-console/branches/jsf-console-3.2-soa/console/pom.xml
projects/jsf-console/branches/jsf-console-3.2-soa/jbpm4jsf/pom.xml
projects/jsf-console/branches/jsf-console-3.2-soa/pom.xml
projects/jsf-console/branches/jsf-console-3.2-soa/soa-distribution/pom.xml
Log:
JBPM-2945 produce web console overlay adapted to jee5 job processor
Modified: projects/jsf-console/branches/jsf-console-3.2-soa/console/pom.xml
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2-soa/console/pom.xml 2010-09-24 22:40:05 UTC (rev 6681)
+++ projects/jsf-console/branches/jsf-console-3.2-soa/console/pom.xml 2010-09-26 00:38:17 UTC (rev 6682)
@@ -30,12 +30,6 @@
<groupId>org.jbpm.jbpm3</groupId>
<artifactId>jsf-console-jbpm4jsf</artifactId>
<version>${project.version}</version>
- <exclusions>
- <exclusion>
- <groupId>javax.faces</groupId>
- <artifactId>jsf-impl</artifactId>
- </exclusion>
- </exclusions>
</dependency>
<!-- Provided Dependencies -->
@@ -50,5 +44,4 @@
<scope>provided</scope>
</dependency>
</dependencies>
-
</project>
Property changes on: projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5
___________________________________________________________________
Name: svn:ignore
+ target
.settings
Added: projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/.project
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/.project (rev 0)
+++ projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/.project 2010-09-26 00:38:17 UTC (rev 6682)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>jsf-console-jee5</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.maven.ide.eclipse.maven2Builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.maven.ide.eclipse.maven2Nature</nature>
+ </natures>
+</projectDescription>
Added: projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/pom.xml
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/pom.xml (rev 0)
+++ projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/pom.xml 2010-09-26 00:38:17 UTC (rev 6682)
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- ====================================================================== -->
+<!-- jBPM: Workflow in Java -->
+<!-- -->
+<!-- Distributable under LGPL license. -->
+<!-- See terms of license at http://www.gnu.org. -->
+<!-- ====================================================================== -->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <name>jBPM3 - JEE5 Console</name>
+ <groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jsf-console-jee5</artifactId>
+ <packaging>war</packaging>
+
+ <parent>
+ <artifactId>jsf-console-parent</artifactId>
+ <groupId>org.jbpm.jbpm3</groupId>
+ <version>3.2.10-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.jbpm.jbpm3</groupId>
+ <artifactId>jsf-console</artifactId>
+ <version>${project.version}</version>
+ <type>war</type>
+ </dependency>
+ </dependencies>
+</project>
\ No newline at end of file
Property changes on: projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/pom.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Added: projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/jboss-web.xml
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/jboss-web.xml (rev 0)
+++ projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/jboss-web.xml 2010-09-26 00:38:17 UTC (rev 6682)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE jboss-web PUBLIC "-//JBoss//DTD Web Application 2.4//EN"
+ "http://www.jboss.org/j2ee/dtd/jboss-web_4_0.dtd">
+
+<jboss-web>
+ <!--
+ Specify the security domain to use. This will be java:/jaas/<name> where
+ <name> is one of the names configured in your login-config.xml.
+ -->
+ <security-domain>java:/jaas/jbpm-console</security-domain>
+ <context-root>jbpm-console</context-root>
+
+ <resource-ref>
+ <res-ref-name>jdbc/JbpmDataSource</res-ref-name>
+ <jndi-name>java:JbpmDS</jndi-name>
+ </resource-ref>
+
+ <resource-ref>
+ <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
+ <jndi-name>java:JmsXA</jndi-name>
+ </resource-ref>
+
+ <message-destination-ref>
+ <message-destination-ref-name>jms/JobQueue</message-destination-ref-name>
+ <jndi-name>queue/JbpmJobQueue</jndi-name>
+ </message-destination-ref>
+</jboss-web>
Property changes on: projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/jboss-web.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Added: projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/web.xml
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/web.xml (rev 0)
+++ projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/web.xml 2010-09-26 00:38:17 UTC (rev 6682)
@@ -0,0 +1,133 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+ <servlet>
+ <description>Enable the JSF servlet. See faces-config.xml for Faces-specific configuration.</description>
+ <servlet-name>Faces Servlet</servlet-name>
+ <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
+ <load-on-startup>1</load-on-startup>
+ </servlet>
+
+ <!-- Mapping for all plain pages -->
+ <servlet-mapping>
+ <servlet-name>Faces Servlet</servlet-name>
+ <url-pattern>*.jsf</url-pattern>
+ </servlet-mapping>
+
+ <!-- This mapping is for the process images -->
+ <servlet-mapping>
+ <servlet-name>Faces Servlet</servlet-name>
+ <url-pattern>/app/pi/*</url-pattern>
+ </servlet-mapping>
+
+ <context-param>
+ <description>Use Documents Saved as *.xhtml</description>
+ <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
+ <param-value>.xhtml</param-value>
+ </context-param>
+
+ <context-param>
+ <description>Facelets debug output</description>
+ <param-name>facelets.DEVELOPMENT</param-name>
+ <param-value>false</param-value>
+ </context-param>
+
+ <!-- A simple JSP to redirect to the basic search page -->
+ <welcome-file-list>
+ <welcome-file>index.jsp</welcome-file>
+ </welcome-file-list>
+
+ <!--
+ This role list should be changed to include all the relevant roles for your
+ environment.
+ -->
+ <security-role>
+ <role-name>admin</role-name>
+ </security-role>
+ <security-role>
+ <role-name>user</role-name>
+ </security-role>
+
+ <!--
+ Security constraints - optionally customize the role name to require a login
+ before access is allowed. Also, be sure to edit jboss-web.xml to configure
+ the security domain if you are deploying inside JBoss AS.
+ -->
+ <security-constraint>
+ <web-resource-collection>
+ <web-resource-name>Secure Area</web-resource-name>
+ <url-pattern>/app/*</url-pattern>
+ </web-resource-collection>
+ <auth-constraint>
+ <role-name>user</role-name>
+ </auth-constraint>
+ </security-constraint>
+
+ <!-- Example Login page - lists sample users -->
+ <login-config>
+ <auth-method>FORM</auth-method>
+ <form-login-config>
+ <form-login-page>/ua/login-example.jsf</form-login-page>
+ <form-error-page>/ua/login-example.jsf?error=true</form-error-page>
+ </form-login-config>
+ </login-config>
+
+ <!-- Login configuration option #1 - use the login page ==>
+ <login-config>
+ <auth-method>FORM</auth-method>
+ <form-login-config>
+ <form-login-page>/ua/login.jsf</form-login-page>
+ <form-error-page>/ua/login.jsf?error=true</form-error-page>
+ </form-login-config>
+ </login-config>
+ <!== Login configuration option #1 -->
+
+ <!-- Login configuration option #2 - use basic auth ==>
+ <login-config>
+ <auth-method>BASIC</auth-method>
+ <realm-name>jBPM Administration Console</realm-name>
+ </login-config>
+ <!== Login configuration option #2 -->
+
+ <!-- Job executor launcher ==>
+ <listener>
+ <description>
+ Starts the job executor on initialization and stops it on destruction.
+ </description>
+ <listener-class>org.jbpm.web.JobExecutorLauncher</listener-class>
+ </listener>
+ <!== Job executor launcher -->
+
+ <listener>
+ <description>Closes the jBPM configuration on destruction, releasing resources.
+ This listener should appear after the job executor launcher,
+ to avoid reopening the configuration.</description>
+ <listener-class>org.jbpm.web.JbpmConfigurationCloser</listener-class>
+ </listener>
+
+ <resource-ref>
+ <description>Logical name of the data source that provides connections to the persistence service.
+ Must match the hibernate.connection.datasource property in the Hibernate
+ configuration file.</description>
+ <res-ref-name>jdbc/JbpmDataSource</res-ref-name>
+ <res-type>javax.sql.DataSource</res-type>
+ <res-auth>Container</res-auth>
+ </resource-ref>
+
+ <resource-ref>
+ <description>Logical name of the factory that provides JMS connections to the message service.
+ Required for processes that contain asynchronous continuations.</description>
+ <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
+ <res-type>javax.jms.ConnectionFactory</res-type>
+ <res-auth>Container</res-auth>
+ </resource-ref>
+
+ <message-destination-ref>
+ <description>The message service sends job messages to the queue referenced here.
+ This must be the same queue from which the JobListenerBean receives messages.</description>
+ <message-destination-ref-name>jms/JobQueue</message-destination-ref-name>
+ <message-destination-type>javax.jms.Queue</message-destination-type>
+ <message-destination-usage>Produces</message-destination-usage>
+ </message-destination-ref>
+</web-app>
Property changes on: projects/jsf-console/branches/jsf-console-3.2-soa/console-jee5/src/main/webapp/WEB-INF/web.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Modified: projects/jsf-console/branches/jsf-console-3.2-soa/jbpm4jsf/pom.xml
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2-soa/jbpm4jsf/pom.xml 2010-09-24 22:40:05 UTC (rev 6681)
+++ projects/jsf-console/branches/jsf-console-3.2-soa/jbpm4jsf/pom.xml 2010-09-26 00:38:17 UTC (rev 6682)
@@ -58,11 +58,6 @@
</dependency>
<!-- Runtime Dependencies -->
- <dependency>
- <groupId>javax.faces</groupId>
- <artifactId>jsf-impl</artifactId>
- <scope>runtime</scope>
- </dependency>
</dependencies>
<!-- Plugins -->
Modified: projects/jsf-console/branches/jsf-console-3.2-soa/pom.xml
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2-soa/pom.xml 2010-09-24 22:40:05 UTC (rev 6681)
+++ projects/jsf-console/branches/jsf-console-3.2-soa/pom.xml 2010-09-26 00:38:17 UTC (rev 6682)
@@ -10,7 +10,7 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
- <name>jBPM3</name>
+ <name>jBPM3 - Console Parent</name>
<groupId>org.jbpm.jbpm3</groupId>
<artifactId>jsf-console-parent</artifactId>
<packaging>pom</packaging>
@@ -33,6 +33,7 @@
<!-- Modules -->
<modules>
<module>console</module>
+ <module>console-jee5</module>
<module>jbpm4jsf</module>
<module>gpd-deployer</module>
</modules>
Modified: projects/jsf-console/branches/jsf-console-3.2-soa/soa-distribution/pom.xml
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2-soa/soa-distribution/pom.xml 2010-09-24 22:40:05 UTC (rev 6681)
+++ projects/jsf-console/branches/jsf-console-3.2-soa/soa-distribution/pom.xml 2010-09-26 00:38:17 UTC (rev 6682)
@@ -10,7 +10,7 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
- <name>jBPM3 - Build SOA-P distribution</name>
+ <name>jBPM3 - SOA Console</name>
<groupId>org.jbpm.jbpm3</groupId>
<artifactId>jsf-console-soa-distribution</artifactId>
<packaging>pom</packaging>
13 years, 7 months