JBoss JBPM SVN: r2174 - jbpm4/pvm/trunk/modules/core.
by do-not-reply@jboss.org
Author: porcherg
Date: 2008-09-11 04:17:40 -0400 (Thu, 11 Sep 2008)
New Revision: 2174
Modified:
jbpm4/pvm/trunk/modules/core/pom.xml
Log:
fix wirexsd generation
Modified: jbpm4/pvm/trunk/modules/core/pom.xml
===================================================================
--- jbpm4/pvm/trunk/modules/core/pom.xml 2008-09-11 08:07:13 UTC (rev 2173)
+++ jbpm4/pvm/trunk/modules/core/pom.xml 2008-09-11 08:17:40 UTC (rev 2174)
@@ -201,7 +201,7 @@
<configuration>
<tasks>
<taskdef name="xsddoc" classname="net.sf.xframe.xsddoc.Task" classpathref="maven.plugin.classpath" />
- <mkdir dir="${basedir}/target/doc/wirexsd" />
+ <mkdir dir="${basedir}/target/doc-wirexsd" />
<xsddoc file="${basedir}/src/main/resources/org/jbpm/pvm/wire.xsd"
out="${basedir}/target/doc-wirexsd"
title="Process Virtual Machine: Wiring Schema"
17 years, 7 months
JBoss JBPM SVN: r2173 - jbpm3/trunk/modules/enterprise/ear.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-11 04:07:13 -0400 (Thu, 11 Sep 2008)
New Revision: 2173
Modified:
jbpm3/trunk/modules/enterprise/ear/pom.xml
Log:
Use bundleFileName
Modified: jbpm3/trunk/modules/enterprise/ear/pom.xml
===================================================================
--- jbpm3/trunk/modules/enterprise/ear/pom.xml 2008-09-11 07:45:00 UTC (rev 2172)
+++ jbpm3/trunk/modules/enterprise/ear/pom.xml 2008-09-11 08:07:13 UTC (rev 2173)
@@ -97,26 +97,29 @@
<artifactId>maven-ear-plugin</artifactId>
<configuration>
<generateApplicationXml>true</generateApplicationXml>
- <version>1.4</version>
<modules>
<ejbModule>
<groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-enterprise-beans</artifactId>
+ <bundleFileName>jbpm-enterprise-beans.jar</bundleFileName>
<unpack>true</unpack>
</ejbModule>
<jarModule>
<groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-core</artifactId>
+ <bundleFileName>jbpm-core.jar</bundleFileName>
<includeInApplicationXml>true</includeInApplicationXml>
</jarModule>
<jarModule>
<groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-identity</artifactId>
+ <bundleFileName>jbpm-identity.jar</bundleFileName>
<includeInApplicationXml>true</includeInApplicationXml>
</jarModule>
<webModule>
<groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-console</artifactId>
+ <bundleFileName>jbpm-console.war</bundleFileName>
<contextRoot>/jbpm-console</contextRoot>
<unpack>true</unpack>
</webModule>
17 years, 7 months
JBoss JBPM SVN: r2172 - in jbpm3/trunk/modules: distribution/scripts and 6 other directories.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-11 03:45:00 -0400 (Thu, 11 Sep 2008)
New Revision: 2172
Added:
jbpm3/trunk/modules/enterprise/jar/src/main/etc/
jbpm3/trunk/modules/enterprise/jar/src/main/etc/jbpm.cfg.xml
Removed:
jbpm3/trunk/modules/enterprise/jar/src/main/resources/jbpm.cfg.xml
Modified:
jbpm3/trunk/modules/distribution/pom.xml
jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml
jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
jbpm3/trunk/modules/enterprise/ear/pom.xml
jbpm3/trunk/modules/enterprise/jar/scripts/assembly-config.xml
Log:
Unpack enterprise beans
Modified: jbpm3/trunk/modules/distribution/pom.xml
===================================================================
--- jbpm3/trunk/modules/distribution/pom.xml 2008-09-11 06:47:07 UTC (rev 2171)
+++ jbpm3/trunk/modules/distribution/pom.xml 2008-09-11 07:45:00 UTC (rev 2172)
@@ -52,7 +52,7 @@
</dependency>
<dependency>
<groupId>org.jboss.jbpm</groupId>
- <artifactId>jbpm-enterprise-archive</artifactId>
+ <artifactId>jbpm-enterprise-bundle</artifactId>
<version>${version}</version>
<type>ear</type>
</dependency>
Modified: jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml
===================================================================
--- jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml 2008-09-11 06:47:07 UTC (rev 2171)
+++ jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml 2008-09-11 07:45:00 UTC (rev 2172)
@@ -122,7 +122,7 @@
<mkdir dir="${izpack.temp.dir}" />
<!-- http://jira.codehaus.org/browse/IZPACK-151 -->
- <copy file="${deploy.artifacts.lib}/jbpm-enterprise-archive.ear" tofile="${deploy.artifacts.lib}/jbpm-enterprise-archive.zip" />
+ <copy file="${deploy.artifacts.lib}/jbpm-enterprise-bundle.ear" tofile="${deploy.artifacts.lib}/jbpm-enterprise-bundle.zip" />
<copy file="${deploy.artifacts.lib}/jbpm-core-config.jar" tofile="${deploy.artifacts.lib}/jbpm-core-config.zip" />
<copy file="${deploy.artifacts.lib}/jbpm-userguide.jdocbook" tofile="${deploy.artifacts.lib}/jbpm-userguide.zip" />
Modified: jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
===================================================================
--- jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-11 06:47:07 UTC (rev 2171)
+++ jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-11 07:45:00 UTC (rev 2172)
@@ -109,7 +109,7 @@
<!-- jbpm3/lib -->
<fileset dir="@{deploy.artifacts.dir}/lib" targetdir="$INSTALL_PATH/jbpm3/lib" override="true">
- <include name="jbpm-enterprise-archive.ear" />
+ <include name="jbpm-enterprise-bundle.ear" />
<include name="jbpm-core.jar" />
<include name="jbpm-identity.jar" />
<include name="activation.jar" />
@@ -167,7 +167,7 @@
unpack="true" override="true" />
<!-- jbpm/jbpm-enterprise.ear -->
- <file src="@{deploy.artifacts.dir}/lib/jbpm-enterprise-archive.zip" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-enterprise-archive.ear"
+ <file src="@{deploy.artifacts.dir}/lib/jbpm-enterprise-bundle.zip" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-enterprise-bundle.ear"
unpack="true" override="true" />
<!-- jbpm/jbpm-userguide.war -->
Modified: jbpm3/trunk/modules/enterprise/ear/pom.xml
===================================================================
--- jbpm3/trunk/modules/enterprise/ear/pom.xml 2008-09-11 06:47:07 UTC (rev 2171)
+++ jbpm3/trunk/modules/enterprise/ear/pom.xml 2008-09-11 07:45:00 UTC (rev 2172)
@@ -15,7 +15,7 @@
<modelVersion>4.0.0</modelVersion>
<name>JBoss jBPM - Enterprise Bundle</name>
<groupId>org.jboss.jbpm</groupId>
- <artifactId>jbpm-enterprise-archive</artifactId>
+ <artifactId>jbpm-enterprise-bundle</artifactId>
<packaging>ear</packaging>
<!-- Parent -->
@@ -102,6 +102,7 @@
<ejbModule>
<groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-enterprise-beans</artifactId>
+ <unpack>true</unpack>
</ejbModule>
<jarModule>
<groupId>org.jboss.jbpm</groupId>
Modified: jbpm3/trunk/modules/enterprise/jar/scripts/assembly-config.xml
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/scripts/assembly-config.xml 2008-09-11 06:47:07 UTC (rev 2171)
+++ jbpm3/trunk/modules/enterprise/jar/scripts/assembly-config.xml 2008-09-11 07:45:00 UTC (rev 2172)
@@ -7,7 +7,7 @@
<includeBaseDirectory>false</includeBaseDirectory>
<fileSets>
<fileSet>
- <directory>${project.build.outputDirectory}</directory>
+ <directory>${basedir}/src/main/etc</directory>
<outputDirectory>/</outputDirectory>
<includes>
<include>jbpm.cfg.xml</include>
Copied: jbpm3/trunk/modules/enterprise/jar/src/main/etc/jbpm.cfg.xml (from rev 2169, jbpm3/trunk/modules/enterprise/jar/src/main/resources/jbpm.cfg.xml)
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/src/main/etc/jbpm.cfg.xml (rev 0)
+++ jbpm3/trunk/modules/enterprise/jar/src/main/etc/jbpm.cfg.xml 2008-09-11 07:45:00 UTC (rev 2172)
@@ -0,0 +1,19 @@
+<jbpm-configuration>
+
+ <jbpm-context>
+ <service name="persistence" factory="org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory" />
+ <service name="message" factory="org.jbpm.msg.jms.JmsMessageServiceFactoryImpl" />
+ <service name="scheduler" factory="org.jbpm.scheduler.ejbtimer.EntitySchedulerServiceFactory" />
+ <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>
+
+ <!--
+ Note, that the default job executor needs to be overwritten with a null value.
+ In the enterprise configuration there should be no job executor.
+ Async messaging is there bound to jms and timers to ejb timers.
+ -->
+ <null name="jbpm.job.executor" />
+
+</jbpm-configuration>
Deleted: jbpm3/trunk/modules/enterprise/jar/src/main/resources/jbpm.cfg.xml
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/src/main/resources/jbpm.cfg.xml 2008-09-11 06:47:07 UTC (rev 2171)
+++ jbpm3/trunk/modules/enterprise/jar/src/main/resources/jbpm.cfg.xml 2008-09-11 07:45:00 UTC (rev 2172)
@@ -1,19 +0,0 @@
-<jbpm-configuration>
-
- <jbpm-context>
- <service name="persistence" factory="org.jbpm.persistence.jta.JtaDbPersistenceServiceFactory" />
- <service name="message" factory="org.jbpm.msg.jms.JmsMessageServiceFactoryImpl" />
- <service name="scheduler" factory="org.jbpm.scheduler.ejbtimer.EntitySchedulerServiceFactory" />
- <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>
-
- <!--
- Note, that the default job executor needs to be overwritten with a null value.
- In the enterprise configuration there should be no job executor.
- Async messaging is there bound to jms and timers to ejb timers.
- -->
- <null name="jbpm.job.executor" />
-
-</jbpm-configuration>
17 years, 7 months
JBoss JBPM SVN: r2171 - in jbpm3/trunk/modules/core/src/test: java/org/jbpm/command and 12 other directories.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-11 02:47:07 -0400 (Thu, 11 Sep 2008)
New Revision: 2171
Added:
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1024/
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1024/JBPM1024Test.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1072/
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1072/JBPM1072Test.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1106/
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1106/JBPM1106Test.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1135/
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1135/JBPM1135Test.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1452/
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1452/JBPM1452Test.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm522/
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm522/JBPM522Test.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm983/
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm983/JBPM983Test.java
jbpm3/trunk/modules/core/src/test/resources/org/jbpm/jbpm1135/
jbpm3/trunk/modules/core/src/test/resources/org/jbpm/jbpm1135/timerprocess.xml
jbpm3/trunk/modules/core/src/test/resources/org/jbpm/jbpm522/
Removed:
jbpm3/trunk/modules/core/src/test/java/org/jbpm/ant/
jbpm3/trunk/modules/core/src/test/java/org/jbpm/command/GetProcessInstancesCommandTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/exe/CustomSerializableVariableDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/JobConcurrencyDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/MultiJobExecutorDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/NoJobExecutorDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/TimerOnTimerDbTest.java
jbpm3/trunk/modules/core/src/test/resources/org/jbpm/ant/
jbpm3/trunk/modules/core/src/test/resources/org/jbpm/job/executor/.gpd.timerprocess.xml
jbpm3/trunk/modules/core/src/test/resources/org/jbpm/job/executor/timerprocess.xml
Log:
Move JIRA tests to their respective folders
Deleted: jbpm3/trunk/modules/core/src/test/java/org/jbpm/command/GetProcessInstancesCommandTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/command/GetProcessInstancesCommandTest.java 2008-09-11 05:59:58 UTC (rev 2170)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/command/GetProcessInstancesCommandTest.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -1,94 +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.command;
-
-import java.util.Calendar;
-import java.util.List;
-
-import org.jbpm.command.impl.CommandServiceImpl;
-import org.jbpm.db.AbstractDbTestCase;
-import org.jbpm.graph.def.ProcessDefinition;
-import org.jbpm.graph.exe.ProcessInstance;
-
-/**
- * Test case for JBPM-1106.
- * @author Alejandro Guizar
- */
-public class GetProcessInstancesCommandTest extends AbstractDbTestCase {
-
- private static CommandService commandService = new CommandServiceImpl(jbpmConfiguration);
- private ProcessDefinition processDefinition;
-
- public void setUp() throws Exception {
- super.setUp();
- processDefinition = new ProcessDefinition("Audit");
- jbpmContext.deployProcessDefinition(processDefinition);
-
- ProcessInstance processInstance = new ProcessInstance(processDefinition);
- Calendar calendar = Calendar.getInstance();
- calendar.set(2008, 8, 10, 9, 30);
- processInstance.setStart(calendar.getTime());
- jbpmContext.save(processInstance);
-
- processInstance = new ProcessInstance(processDefinition);
- calendar.set(Calendar.HOUR_OF_DAY, 16);
- processInstance.setStart(calendar.getTime());
- jbpmContext.save(processInstance);
-
- processInstance = new ProcessInstance(processDefinition);
- calendar.add(Calendar.DAY_OF_MONTH, 1);
- processInstance.setStart(calendar.getTime());
- jbpmContext.save(processInstance);
-
- processInstance = new ProcessInstance(processDefinition);
- calendar.set(Calendar.HOUR_OF_DAY, 9);
- processInstance.setStart(calendar.getTime());
- jbpmContext.save(processInstance);
-
- newTransaction();
- }
-
- public void testStartDate() {
- GetProcessInstancesCommand command = new GetProcessInstancesCommand();
- Calendar calendar = Calendar.getInstance();
- calendar.set(2008, 8, 10, 9, 0);
- command.setFromStartDate(calendar.getTime());
- calendar.add(Calendar.DAY_OF_MONTH, 1);
- command.setUntilStartDate(calendar.getTime());
-
- List processInstances = (List) commandService.execute(command);
- assertEquals(2, processInstances.size());
- }
-
- public void testStartTime() {
- GetProcessInstancesCommand command = new GetProcessInstancesCommand();
- Calendar calendar = Calendar.getInstance();
- calendar.set(2008, 8, 10, 9, 0);
- command.setFromStartDate(calendar.getTime());
- calendar.set(Calendar.HOUR_OF_DAY, 12);
- command.setUntilStartDate(calendar.getTime());
-
- List processInstances = (List) commandService.execute(command);
- assertEquals(1, processInstances.size());
- }
-
-}
Deleted: jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/exe/CustomSerializableVariableDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/exe/CustomSerializableVariableDbTest.java 2008-09-11 05:59:58 UTC (rev 2170)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/exe/CustomSerializableVariableDbTest.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -1,54 +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.context.exe;
-
-import java.io.IOException;
-import java.io.Serializable;
-
-import org.jbpm.db.AbstractDbTestCase;
-import org.jbpm.graph.def.ProcessDefinition;
-import org.jbpm.graph.exe.ProcessInstance;
-import org.jbpm.instantiation.ProcessClassLoader;
-
-/**
- * Tests a serializable variable whose class file is stored in the process definition.
- * @author Alejandro Guizar
- * @see <a href="http://jira.jboss.com/jira/browse/JBPM-1024">JBPM-1024</a>
- */
-public class CustomSerializableVariableDbTest extends AbstractDbTestCase {
-
- public void testCustomSerializableVariableClass() throws IOException {
- // create and save the process definition
- ProcessDefinition processDefinition = ProcessDefinition.parseParResource("org/jbpm/context/exe/CustomSerializable.zip");
- graphSession.saveProcessDefinition(processDefinition);
-
- // create the process instance
- ProcessInstance processInstance = new ProcessInstance(processDefinition);
- processInstance = saveAndReload(processInstance);
-
- // get the custom object from the context instance
- Object customSerializable = processInstance.getContextInstance().getVariable("custom serializable");
- assertTrue(customSerializable instanceof Serializable);
- assertSame(ProcessClassLoader.class, customSerializable.getClass().getClassLoader().getClass());
- assertEquals("1984", customSerializable.toString());
- }
-}
Added: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1024/JBPM1024Test.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1024/JBPM1024Test.java (rev 0)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1024/JBPM1024Test.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -0,0 +1,60 @@
+/*
+ * 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.jbpm1024;
+
+import java.io.IOException;
+import java.io.Serializable;
+
+import org.jbpm.db.AbstractDbTestCase;
+import org.jbpm.graph.def.ProcessDefinition;
+import org.jbpm.graph.exe.ProcessInstance;
+import org.jbpm.instantiation.ProcessClassLoader;
+
+/**
+ * Serializable variables are not being deserialized when retrieved from process
+ *
+ * https://jira.jboss.org/jira/browse/JBPM-1024
+ *
+ * Tests a serializable variable whose class file is stored in the process definition.
+ *
+ * @author Alejandro Guizar
+ */
+public class JBPM1024Test extends AbstractDbTestCase
+{
+
+ public void testCustomSerializableVariableClass() throws IOException
+ {
+ // create and save the process definition
+ ProcessDefinition processDefinition = ProcessDefinition.parseParResource("org/jbpm/context/exe/CustomSerializable.zip");
+ graphSession.saveProcessDefinition(processDefinition);
+
+ // create the process instance
+ ProcessInstance processInstance = new ProcessInstance(processDefinition);
+ processInstance = saveAndReload(processInstance);
+
+ // get the custom object from the context instance
+ Object customSerializable = processInstance.getContextInstance().getVariable("custom serializable");
+ assertTrue(customSerializable instanceof Serializable);
+ assertSame(ProcessClassLoader.class, customSerializable.getClass().getClassLoader().getClass());
+ assertEquals("1984", customSerializable.toString());
+ }
+}
Property changes on: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1024/JBPM1024Test.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1072/JBPM1072Test.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1072/JBPM1072Test.java (rev 0)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1072/JBPM1072Test.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -0,0 +1,155 @@
+package org.jbpm.jbpm1072;
+
+import java.sql.SQLException;
+
+import junit.framework.TestCase;
+
+import org.jbpm.JbpmConfiguration;
+import org.jbpm.JbpmContext;
+import org.jbpm.graph.def.ActionHandler;
+import org.jbpm.graph.def.Event;
+import org.jbpm.graph.def.ProcessDefinition;
+import org.jbpm.graph.exe.ExecutionContext;
+import org.jbpm.graph.exe.ProcessInstance;
+import org.jbpm.job.executor.EventCallback;
+import org.jbpm.job.executor.JobExecutor;
+
+/**
+ * Concurrent JobExecutors can process the same job in parallel
+ *
+ * https://jira.jboss.org/jira/browse/JBPM-1072
+ *
+ * @author Jiri Pechanec
+ * @author Alejandro Guizar
+ */
+public class JBPM1072Test extends TestCase {
+
+ private static final int EXECUTOR_COUNT = 20;
+ public static final String PROCESS_NAME = "TestProcess";
+
+ private JobExecutor[] executors = new JobExecutor[EXECUTOR_COUNT];
+
+ private static JbpmConfiguration jbpmConfiguration = JbpmConfiguration.getInstance();
+
+ public static final String PROCESS_DEFINITION = "<?xml version='1.0' encoding='UTF-8'?>"
+ + "<process-definition name='" + PROCESS_NAME + "'>"
+ + "<event type='process-end'>"
+ + "<action expression='#{eventCallback.processEnd}' />"
+ + "</event>"
+ + "<start-state name='start-state1'>"
+ + "<transition to='Service 1'></transition>"
+ + "</start-state>"
+ + "<node name='Service 1'>"
+ + "<action class='"
+ + SimpleAction.class.getName()
+ + "' />"
+ + "<transition to='Service 2' />"
+ + "</node>"
+ + "<node name='Service 2' async='true'>"
+ + "<action class='"
+ + SimpleAction2.class.getName()
+ + "' />"
+ + "<transition to='end-state1' />"
+ + "</node>"
+ + "<end-state name='end-state1' />"
+ + "</process-definition>";
+
+ protected void setUp() throws SQLException
+ {
+ jbpmConfiguration.createSchema();
+
+ // deploy process definition
+ JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
+ try
+ {
+ jbpmContext.deployProcessDefinition(ProcessDefinition.parseXmlString(PROCESS_DEFINITION));
+ }
+ finally
+ {
+ jbpmContext.close();
+ }
+ }
+
+ public void testMultipleJobExecutors()
+ {
+ // start job executors
+ for (int i = 0; i < executors.length; i++)
+ {
+ executors[i] = (JobExecutor)JbpmConfiguration.Configs.getObjectFactory().createObject("jbpm.job.executor");
+ executors[i].setName("JbpmJobExecutor/" + (i + 1));
+ executors[i].start();
+ }
+
+ // kick off process instance
+ JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
+ try
+ {
+ ProcessInstance processInstance = jbpmContext.newProcessInstanceForUpdate(PROCESS_NAME);
+ processInstance.getContextInstance().setVariable("eventCallback", new EventCallback());
+ processInstance.signal();
+ }
+ finally
+ {
+ jbpmContext.close();
+ }
+
+ // wait for process end
+ EventCallback.waitForEvent(Event.EVENTTYPE_PROCESS_END);
+
+ // stop job executors
+ for (int i = executors.length - 1; i >= 0; i--)
+ {
+ try
+ {
+ executors[i].stopAndJoin();
+ }
+ catch (InterruptedException e)
+ {
+ // continue to next executor
+ }
+ }
+
+ assertEquals(1, SimpleAction2.getExecutionCount());
+ }
+
+ protected void tearDown()
+ {
+ jbpmConfiguration.dropSchema();
+ }
+
+ public static class SimpleAction implements ActionHandler
+ {
+
+ private static final long serialVersionUID = 1L;
+
+ public void execute(ExecutionContext exeContext) throws Exception
+ {
+ exeContext.leaveNode();
+ }
+
+ }
+
+ public static class SimpleAction2 implements ActionHandler
+ {
+
+ private static int executionCount = 0;
+
+ private static final long serialVersionUID = 1L;
+
+ public void execute(ExecutionContext exeContext) throws Exception
+ {
+ incrementCount();
+ exeContext.leaveNode();
+ }
+
+ private static synchronized int incrementCount()
+ {
+ return ++executionCount;
+ }
+
+ public static synchronized int getExecutionCount()
+ {
+ return executionCount;
+ }
+ }
+}
Property changes on: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1072/JBPM1072Test.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1106/JBPM1106Test.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1106/JBPM1106Test.java (rev 0)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1106/JBPM1106Test.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -0,0 +1,103 @@
+/*
+ * 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.jbpm1106;
+
+import java.util.Calendar;
+import java.util.List;
+
+import org.jbpm.command.CommandService;
+import org.jbpm.command.GetProcessInstancesCommand;
+import org.jbpm.command.impl.CommandServiceImpl;
+import org.jbpm.db.AbstractDbTestCase;
+import org.jbpm.graph.def.ProcessDefinition;
+import org.jbpm.graph.exe.ProcessInstance;
+
+/**
+ * GetProcessInstancesCommand should use Query.setTimestamp instead of Query.setDate
+ *
+ * https://jira.jboss.org/jira/browse/JBPM-1106
+ *
+ * @author Alejandro Guizar
+ */
+public class JBPM1106Test extends AbstractDbTestCase
+{
+
+ private static CommandService commandService = new CommandServiceImpl(jbpmConfiguration);
+ private ProcessDefinition processDefinition;
+
+ public void setUp() throws Exception
+ {
+ super.setUp();
+ processDefinition = new ProcessDefinition("Audit");
+ jbpmContext.deployProcessDefinition(processDefinition);
+
+ ProcessInstance processInstance = new ProcessInstance(processDefinition);
+ Calendar calendar = Calendar.getInstance();
+ calendar.set(2008, 8, 10, 9, 30);
+ processInstance.setStart(calendar.getTime());
+ jbpmContext.save(processInstance);
+
+ processInstance = new ProcessInstance(processDefinition);
+ calendar.set(Calendar.HOUR_OF_DAY, 16);
+ processInstance.setStart(calendar.getTime());
+ jbpmContext.save(processInstance);
+
+ processInstance = new ProcessInstance(processDefinition);
+ calendar.add(Calendar.DAY_OF_MONTH, 1);
+ processInstance.setStart(calendar.getTime());
+ jbpmContext.save(processInstance);
+
+ processInstance = new ProcessInstance(processDefinition);
+ calendar.set(Calendar.HOUR_OF_DAY, 9);
+ processInstance.setStart(calendar.getTime());
+ jbpmContext.save(processInstance);
+
+ newTransaction();
+ }
+
+ public void testStartDate()
+ {
+ GetProcessInstancesCommand command = new GetProcessInstancesCommand();
+ Calendar calendar = Calendar.getInstance();
+ calendar.set(2008, 8, 10, 9, 0);
+ command.setFromStartDate(calendar.getTime());
+ calendar.add(Calendar.DAY_OF_MONTH, 1);
+ command.setUntilStartDate(calendar.getTime());
+
+ List processInstances = (List)commandService.execute(command);
+ assertEquals(2, processInstances.size());
+ }
+
+ public void testStartTime()
+ {
+ GetProcessInstancesCommand command = new GetProcessInstancesCommand();
+ Calendar calendar = Calendar.getInstance();
+ calendar.set(2008, 8, 10, 9, 0);
+ command.setFromStartDate(calendar.getTime());
+ calendar.set(Calendar.HOUR_OF_DAY, 12);
+ command.setUntilStartDate(calendar.getTime());
+
+ List processInstances = (List)commandService.execute(command);
+ assertEquals(1, processInstances.size());
+ }
+
+}
Property changes on: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1106/JBPM1106Test.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1135/JBPM1135Test.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1135/JBPM1135Test.java (rev 0)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1135/JBPM1135Test.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -0,0 +1,69 @@
+/*
+ * 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.jbpm1135;
+
+import org.jbpm.db.AbstractDbTestCase;
+import org.jbpm.graph.def.Event;
+import org.jbpm.graph.def.ProcessDefinition;
+import org.jbpm.graph.exe.ProcessInstance;
+import org.jbpm.job.executor.EventCallback;
+
+/**
+ * JobSession.deleteJobsForProcessInstance doesn't work if jbpm isn't the transaction manager
+ *
+ * https://jira.jboss.org/jira/browse/JBPM-1135
+ *
+ * @author Alejandro Guizar
+ */
+public class JBPM1135Test extends AbstractDbTestCase
+{
+
+ public void testTimerOnTimer()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlResource("org/jbpm/jbpm1135/timerprocess.xml");
+ jbpmContext.deployProcessDefinition(processDefinition);
+
+ ProcessInstance processInstance = jbpmContext.newProcessInstanceForUpdate("timerProcess");
+ processInstance.getContextInstance().setVariable("eventCallback", new EventCallback());
+ processInstance.signal();
+ assertEquals("firstNode", processInstance.getRootToken().getNode().getName());
+ commitAndCloseSession();
+
+ startJobExecutor();
+ try
+ {
+ EventCallback.waitForEvent(Event.EVENTTYPE_NODE_ENTER);
+ beginSessionTransaction();
+ long processInstanceId = processInstance.getId();
+ assertEquals("secondNode", jbpmContext.loadProcessInstance(processInstanceId).getRootToken().getNode().getName());
+ commitAndCloseSession();
+
+ EventCallback.waitForEvent(Event.EVENTTYPE_PROCESS_END);
+ beginSessionTransaction();
+ assertTrue(jbpmContext.loadProcessInstance(processInstanceId).hasEnded());
+ }
+ finally
+ {
+ stopJobExecutor();
+ }
+ }
+}
Property changes on: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1135/JBPM1135Test.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1452/JBPM1452Test.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1452/JBPM1452Test.java (rev 0)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1452/JBPM1452Test.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -0,0 +1,72 @@
+/*
+ * 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.jbpm1452;
+
+import junit.framework.TestCase;
+
+import org.jbpm.JbpmConfiguration;
+import org.jbpm.JbpmContext;
+import org.jbpm.configuration.ObjectFactory;
+import org.jbpm.graph.def.ProcessDefinition;
+import org.jbpm.graph.exe.ProcessInstance;
+
+/**
+ * JbpmConfiguration assumes the object factory has a jbpm.job.executor entry
+ *
+ * https://jira.jboss.org/jira/browse/JBPM-1452
+ *
+ * @author Alejandro Guizar
+ */
+public class JBPM1452Test extends TestCase
+{
+
+ private JbpmContext jbpmContext;
+
+ private static JbpmConfiguration jbpmConfiguration = JbpmConfiguration.parseXmlString(
+ "<jbpm-configuration>" +
+ " <null name='jbpm.job.executor' />" +
+ "</jbpm-configuration>");
+
+ public void setUp() throws Exception
+ {
+ jbpmConfiguration.createSchema();
+ jbpmContext = jbpmConfiguration.createJbpmContext();
+ }
+
+ public void tearDown() throws Exception
+ {
+ jbpmContext.close();
+ jbpmConfiguration.dropSchema();
+ }
+
+ public void testNoJobExecutor()
+ {
+ // check the job executor is properly nullified
+ ObjectFactory objectFactory = jbpmContext.getObjectFactory();
+ assertTrue("expected object factory to have object jbpm.job.executor", objectFactory.hasObject("jbpm.job.executor"));
+ assertNull(objectFactory.createObject("jbpm.job.executor"));
+ // start and end a process instance, no exception should be thrown
+ jbpmContext.deployProcessDefinition(new ProcessDefinition("Audit"));
+ ProcessInstance processInstance = jbpmContext.newProcessInstanceForUpdate("Audit");
+ processInstance.end();
+ }
+}
Property changes on: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm1452/JBPM1452Test.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm522/JBPM522Test.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm522/JBPM522Test.java (rev 0)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm522/JBPM522Test.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -0,0 +1,80 @@
+/*
+ * 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.jbpm522;
+
+import java.util.List;
+
+import org.apache.tools.ant.Main;
+
+import org.jbpm.db.AbstractDbTestCase;
+import org.jbpm.graph.def.ProcessDefinition;
+
+/**
+ * Failed attempts to deploy a process leave a process definition record
+ *
+ * https://jira.jboss.org/jira/browse/JBPM-522
+ *
+ * @author Alejandro Guizar
+ */
+public class JBPM522Test extends AbstractDbTestCase {
+
+ public void testDeployProcess() {
+ runTarget("deploy.process");
+ List processDefinitions = graphSession.findAllProcessDefinitions();
+ assertEquals(1, processDefinitions.size());
+ ProcessDefinition processDefinition = (ProcessDefinition) processDefinitions.get(0);
+ assertEquals("timerProcess", processDefinition.getName());
+ }
+
+ public void testDeployBadProcess() {
+ runTarget("deploy.bad.process");
+ List processDefinitions = graphSession.findAllProcessDefinitions();
+ assertEquals(0, processDefinitions.size());
+ }
+
+ public void testDeployProcesses() {
+ runTarget("deploy.processes");
+ List processDefinitions = graphSession.findAllProcessDefinitions();
+ assertEquals(2, processDefinitions.size());
+ ProcessDefinition processDefinition = (ProcessDefinition) processDefinitions.get(0);
+ assertEquals("classLoadingProcess", processDefinition.getName());
+ processDefinition = (ProcessDefinition) processDefinitions.get(1);
+ assertEquals("timerProcess", processDefinition.getName());
+ }
+
+ public void testDeployProcessesIncludingBad() {
+ runTarget("deploy.processes.including.bad");
+ List processDefinitions = graphSession.findAllProcessDefinitions();
+ assertEquals(0, processDefinitions.size());
+ }
+
+ private static void runTarget(String target) {
+ String[] args = {
+ "-buildfile", JBPM522Test.class.getResource("build.xml").getPath(), target
+ };
+ new Main() {
+ protected void exit(int exitCode) {
+ // prevent ant from terminating the VM
+ }
+ }.startAnt(args, System.getProperties(), Thread.currentThread().getContextClassLoader());
+ }
+}
Property changes on: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm522/JBPM522Test.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm983/JBPM983Test.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm983/JBPM983Test.java (rev 0)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm983/JBPM983Test.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -0,0 +1,244 @@
+package org.jbpm.jbpm983;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import junit.framework.TestCase;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.jbpm.JbpmConfiguration;
+import org.jbpm.JbpmContext;
+import org.jbpm.graph.def.ActionHandler;
+import org.jbpm.graph.def.ProcessDefinition;
+import org.jbpm.graph.exe.ExecutionContext;
+import org.jbpm.graph.exe.ProcessInstance;
+import org.jbpm.job.executor.JobExecutor;
+
+/**
+ * Concurrent process execution fails
+ *
+ * https://jira.jboss.org/jira/browse/JBPM-983
+ *
+ * @author Tom Baeyens
+ */
+public class JBPM983Test extends TestCase
+{
+ private static Log log = LogFactory.getLog(JBPM983Test.class);
+
+ protected static JbpmConfiguration jbpmConfiguration = JbpmConfiguration.getInstance("org/jbpm/jbpm.test.cfg.xml");
+
+ protected void setUp() throws Exception
+ {
+ jbpmConfiguration.createSchema();
+
+ JobExecutor jobExecutor = jbpmConfiguration.getJobExecutor();
+ jobExecutor.setNbrOfThreads(5);
+ jobExecutor.start();
+
+ log.debug("");
+ log.debug("### starting " + getName() + " ####################################################");
+ }
+
+ protected void tearDown() throws Exception
+ {
+ log.debug("### " + getName() + " done ####################################################");
+ log.debug("");
+
+ jbpmConfiguration.getJobExecutor().stop();
+
+ jbpmConfiguration.dropSchema();
+ }
+
+ static String SUBPROCESS_XML = "<?xml version='1.0' encoding='UTF-8'?>"
+ + "<process-definition xmlns='urn:jbpm.org:jpdl-3.2' name='subprocess'>"
+ + "<start-state name='start-state1'>"
+ + " <description>start of the process</description>"
+ + " <transition name='start-to-check' to='fileCheck' />"
+ + "</start-state>"
+ + ""
+ + "<node name='fileCheck' async='exclusive'>"
+ + " <action name='action_filecheck' class='"
+ + TestAction.class.getName()
+ + "'>"
+ + " </action>"
+ + " <transition name='check-to-do' to='doWhatever'></transition>"
+ + "</node>"
+ + ""
+ + "<node name='doWhatever' async='exclusive'>"
+ + " <action name='action_do' class='"
+ + TestAction.class.getName()
+ + "'>"
+ + " </action>"
+ + " <transition name='check-to-end' to='end-state-success'></transition>"
+ + "</node>"
+ + ""
+ + "<end-state name='end-state-success'>"
+ + " <description>process finished normally</description>"
+ + "</end-state>"
+ + "</process-definition>";
+
+ static String PROCESS_XML = "<?xml version='1.0' encoding='UTF-8'?>"
+ + "<process-definition xmlns='urn:jbpm.org:jpdl-3.2' name='superprocess'>"
+ + "<start-state name='start-state1'>"
+ + " <description>start of the process</description>"
+ + " <transition name='start-to-check' to='fileCheck' />"
+ + "</start-state>"
+ + ""
+ + "<node name='fileCheck' async='true'>"
+ + " <action name='action_check' class='"
+ + TestAction.class.getName()
+ + "'>"
+ + " </action>"
+ + " <transition name='check-to-fork' to='fork1'></transition>"
+ + "</node>"
+ + ""
+ + "<fork name='fork1'>"
+ + " <transition name='toNode1' to='node1'></transition>"
+ + " <transition name='toNode2' to='node2'></transition>"
+ + "</fork>"
+ + ""
+ + "<process-state name='node1' async='exclusive'>"
+ + " <sub-process name='subprocess' />"
+ + " <transition name='node1toJoin1' to='join1'></transition>"
+ + "</process-state>"
+ + ""
+ + "<process-state name='node2' async='exclusive'>"
+ + " <sub-process name='subprocess' />"
+ + " <transition name='node2toJoin1' to='join1'></transition>"
+ + "</process-state>"
+ + ""
+ + "<join name='join1'>"
+ + " <transition name='joinToEnd' to='end-state-success'></transition>"
+ + "</join>"
+ + ""
+ + "<end-state name='end-state-success'>"
+ + " <description>process finished normally</description>"
+ + "</end-state>"
+ + "</process-definition>";
+
+ public void testConcurrentJobs() throws Exception
+ {
+ assertTrue(jbpmConfiguration.getJobExecutor().getNbrOfThreads() > 1);
+
+ log.info("### TEST: deploy + start processes ###");
+
+ JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
+ try
+ {
+ jbpmContext.deployProcessDefinition(ProcessDefinition.parseXmlString(SUBPROCESS_XML));
+ jbpmContext.deployProcessDefinition(ProcessDefinition.parseXmlString(PROCESS_XML));
+ }
+ finally
+ {
+ jbpmContext.close();
+ }
+
+ // create test properties
+ Map testVariables = new HashMap();
+ testVariables.put("test", "true");
+
+ final int processCount = 10;
+ long[] piIds = new long[processCount];
+ for (int i = 0; i < processCount; i++)
+ {
+ log.info("#################### TEST: starting process " + i + " ####################");
+
+ jbpmContext = jbpmConfiguration.createJbpmContext();
+ try
+ {
+ ProcessInstance pi = jbpmContext.newProcessInstanceForUpdate("superprocess");
+ pi.getContextInstance().addVariables(testVariables);
+ pi.signal();
+ piIds[i] = pi.getId();
+ }
+ finally
+ {
+ jbpmContext.close();
+ }
+ }
+
+ for (int i = 0; i < processCount; i++)
+ {
+ log.info("### TEST: wait for process completion ###");
+
+ long piId = piIds[i];
+ waitFor(piId);
+
+ jbpmContext = jbpmConfiguration.createJbpmContext();
+ try
+ {
+ ProcessInstance pi = jbpmContext.loadProcessInstance(piId);
+ assertEquals("end-state-success", pi.getRootToken().getNode().getName());
+ }
+ finally
+ {
+ jbpmContext.close();
+ }
+
+ log.info("#################### TEST: finished ####################");
+ }
+ }
+
+ protected void waitFor(long piId) throws Exception
+ {
+ final int endTimeout = 30;
+ long startTime = System.currentTimeMillis();
+
+ while (true)
+ {
+ if (System.currentTimeMillis() - startTime > endTimeout * 1000)
+ {
+ fail("Aborting after " + endTimeout + " seconds.");
+ return;
+ }
+
+ log.info("waiting for workflow completion....");
+ try
+ {
+ Thread.sleep(1000);
+ }
+ catch (InterruptedException e)
+ {
+ log.error("wait for workflow was interruputed", e);
+ fail();
+ }
+
+ JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
+ try
+ {
+ if (jbpmContext.loadProcessInstance(piId).hasEnded())
+ break;
+ }
+ finally
+ {
+ jbpmContext.close();
+ }
+ }
+ }
+
+ public static class TestAction implements ActionHandler
+ {
+
+ private static final long serialVersionUID = 1L;
+
+ public void execute(ExecutionContext executionContext) throws Exception
+ {
+ String processName = executionContext.getProcessDefinition().getName() + ":" + executionContext.getProcessInstance().getId();
+ String nodeName = executionContext.getToken().getNode().getName();
+ String tokenName = executionContext.getToken().toString();
+
+ log.info("ACTION (process=" + processName + ",node=" + nodeName + ",token=" + tokenName + "): begin");
+
+ for (int i = 0; i < 5; i++)
+ {
+ log.info("ACTION (process=" + processName + ",node=" + nodeName + ",token=" + tokenName + "): working...");
+ Thread.sleep(100);
+ }
+
+ log.info("ACTION (process=" + processName + ",node=" + nodeName + ",token=" + tokenName + "): end");
+
+ executionContext.leaveNode();
+ }
+ }
+}
Property changes on: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jbpm983/JBPM983Test.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Deleted: jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/JobConcurrencyDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/JobConcurrencyDbTest.java 2008-09-11 05:59:58 UTC (rev 2170)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/JobConcurrencyDbTest.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -1,238 +0,0 @@
-package org.jbpm.job.executor;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import junit.framework.TestCase;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.jbpm.JbpmConfiguration;
-import org.jbpm.JbpmContext;
-import org.jbpm.graph.def.ActionHandler;
-import org.jbpm.graph.def.ProcessDefinition;
-import org.jbpm.graph.exe.ExecutionContext;
-import org.jbpm.graph.exe.ProcessInstance;
-
-/**
- * test case for http://jira.jboss.com/jira/browse/JBPM-983
- */
-public class JobConcurrencyDbTest extends TestCase {
-
- private static Log log = LogFactory.getLog(JobConcurrencyDbTest.class);
-
- protected static JbpmConfiguration jbpmConfiguration = JbpmConfiguration.getInstance("org/jbpm/jbpm.test.cfg.xml");
-
- protected void setUp() throws Exception {
- jbpmConfiguration.createSchema();
-
- JobExecutor jobExecutor = jbpmConfiguration.getJobExecutor();
- jobExecutor.setNbrOfThreads(5);
- jobExecutor.start();
-
- log.debug("");
- log.debug("### starting " + getName() + " ####################################################");
- }
-
- protected void tearDown() throws Exception {
- log.debug("### " + getName() + " done ####################################################");
- log.debug("");
-
- jbpmConfiguration.getJobExecutor().stop();
-
- jbpmConfiguration.dropSchema();
- }
-
- static String SUBPROCESS_XML = "<?xml version='1.0' encoding='UTF-8'?>"
- + "<process-definition xmlns='urn:jbpm.org:jpdl-3.2' name='subprocess'>"
- + "<start-state name='start-state1'>"
- + " <description>start of the process</description>"
- + " <transition name='start-to-check' to='fileCheck' />"
- + "</start-state>"
- + ""
- + "<node name='fileCheck' async='exclusive'>"
- + " <action name='action_filecheck' class='"
- + TestAction.class.getName()
- + "'>"
- + " </action>"
- + " <transition name='check-to-do' to='doWhatever'></transition>"
- + "</node>"
- + ""
- + "<node name='doWhatever' async='exclusive'>"
- + " <action name='action_do' class='"
- + TestAction.class.getName()
- + "'>"
- + " </action>"
- + " <transition name='check-to-end' to='end-state-success'></transition>"
- + "</node>"
- + ""
- + "<end-state name='end-state-success'>"
- + " <description>process finished normally</description>"
- + "</end-state>"
- + "</process-definition>";
-
- static String PROCESS_XML = "<?xml version='1.0' encoding='UTF-8'?>"
- + "<process-definition xmlns='urn:jbpm.org:jpdl-3.2' name='superprocess'>"
- + "<start-state name='start-state1'>"
- + " <description>start of the process</description>"
- + " <transition name='start-to-check' to='fileCheck' />"
- + "</start-state>"
- + ""
- + "<node name='fileCheck' async='true'>"
- + " <action name='action_check' class='"
- + TestAction.class.getName()
- + "'>"
- + " </action>"
- + " <transition name='check-to-fork' to='fork1'></transition>"
- + "</node>"
- + ""
- + "<fork name='fork1'>"
- + " <transition name='toNode1' to='node1'></transition>"
- + " <transition name='toNode2' to='node2'></transition>"
- + "</fork>"
- + ""
- + "<process-state name='node1' async='exclusive'>"
- + " <sub-process name='subprocess' />"
- + " <transition name='node1toJoin1' to='join1'></transition>"
- + "</process-state>"
- + ""
- + "<process-state name='node2' async='exclusive'>"
- + " <sub-process name='subprocess' />"
- + " <transition name='node2toJoin1' to='join1'></transition>"
- + "</process-state>"
- + ""
- + "<join name='join1'>"
- + " <transition name='joinToEnd' to='end-state-success'></transition>"
- + "</join>"
- + ""
- + "<end-state name='end-state-success'>"
- + " <description>process finished normally</description>"
- + "</end-state>"
- + "</process-definition>";
-
- public void testConcurrentJobs() throws Exception {
- assertTrue(jbpmConfiguration.getJobExecutor().getNbrOfThreads() > 1);
-
- log.info("### TEST: deploy + start processes ###");
-
- JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
- jbpmContext.deployProcessDefinition(ProcessDefinition.parseXmlString(SUBPROCESS_XML));
- jbpmContext.deployProcessDefinition(ProcessDefinition.parseXmlString(PROCESS_XML));
- }
- finally {
- jbpmContext.close();
- }
-
- // create test properties
- Map testVariables = new HashMap();
- testVariables.put("test", "true");
-
- final int processCount = 10;
- long[] piIds = new long[processCount];
- for (int i = 0; i < processCount; i++) {
- log.info("#################### TEST: starting process " + i + " ####################");
-
- jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
- ProcessInstance pi = jbpmContext.newProcessInstanceForUpdate("superprocess");
- pi.getContextInstance().addVariables(testVariables);
- pi.signal();
- piIds[i] = pi.getId();
- }
- finally {
- jbpmContext.close();
- }
- }
-
- for (int i = 0; i < processCount; i++) {
- log.info("### TEST: wait for process completion ###");
-
- long piId = piIds[i];
- waitFor(piId);
-
- jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
- ProcessInstance pi = jbpmContext.loadProcessInstance(piId);
- assertEquals("end-state-success", pi.getRootToken().getNode().getName());
- }
- finally {
- jbpmContext.close();
- }
-
- log.info("#################### TEST: finished ####################");
- }
- }
-
- protected void waitFor(long piId) throws Exception {
- final int endTimeout = 30;
- long startTime = System.currentTimeMillis();
-
- while (true) {
- if (System.currentTimeMillis() - startTime > endTimeout * 1000) {
- fail("Aborting after " + endTimeout + " seconds.");
- return;
- }
-
- log.info("waiting for workflow completion....");
- try {
- Thread.sleep(1000);
- }
- catch (InterruptedException e) {
- log.error("wait for workflow was interruputed", e);
- fail();
- }
-
- JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
- if (jbpmContext.loadProcessInstance(piId).hasEnded())
- break;
- }
- finally {
- jbpmContext.close();
- }
- }
- }
-
- public static class TestAction implements ActionHandler {
-
- private static final long serialVersionUID = 1L;
-
- public void execute(ExecutionContext executionContext) throws Exception {
- String processName = executionContext.getProcessDefinition().getName()
- + ":"
- + executionContext.getProcessInstance().getId();
- String nodeName = executionContext.getToken().getNode().getName();
- String tokenName = executionContext.getToken().toString();
-
- log.info("ACTION (process="
- + processName
- + ",node="
- + nodeName
- + ",token="
- + tokenName
- + "): begin");
-
- for (int i = 0; i < 5; i++) {
- log.info("ACTION (process="
- + processName
- + ",node="
- + nodeName
- + ",token="
- + tokenName
- + "): working...");
- Thread.sleep(100);
- }
-
- log.info("ACTION (process="
- + processName
- + ",node="
- + nodeName
- + ",token="
- + tokenName
- + "): end");
-
- executionContext.leaveNode();
- }
- }
-}
Deleted: jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/MultiJobExecutorDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/MultiJobExecutorDbTest.java 2008-09-11 05:59:58 UTC (rev 2170)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/MultiJobExecutorDbTest.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -1,150 +0,0 @@
-package org.jbpm.job.executor;
-
-import java.sql.SQLException;
-
-import junit.framework.TestCase;
-
-import org.jbpm.JbpmConfiguration;
-import org.jbpm.JbpmContext;
-import org.jbpm.graph.def.ActionHandler;
-import org.jbpm.graph.def.Event;
-import org.jbpm.graph.def.ProcessDefinition;
-import org.jbpm.graph.exe.ExecutionContext;
-import org.jbpm.graph.exe.ProcessInstance;
-
-/**
- * Test case for JBPM-1072.
- * @author Jiri Pechanec
- * @author Alejandro Guizar
- */
-public class MultiJobExecutorDbTest extends TestCase {
-
- private static final int EXECUTOR_COUNT = 20;
- public static final String PROCESS_NAME = "TestProcess";
-
- private JobExecutor[] executors = new JobExecutor[EXECUTOR_COUNT];
-
- private static JbpmConfiguration jbpmConfiguration = JbpmConfiguration.getInstance();
-
- public static final String PROCESS_DEFINITION = "<?xml version='1.0' encoding='UTF-8'?>"
- + "<process-definition name='" + PROCESS_NAME + "'>"
- + "<event type='process-end'>"
- + "<action expression='#{eventCallback.processEnd}' />"
- + "</event>"
- + "<start-state name='start-state1'>"
- + "<transition to='Service 1'></transition>"
- + "</start-state>"
- + "<node name='Service 1'>"
- + "<action class='"
- + SimpleAction.class.getName()
- + "' />"
- + "<transition to='Service 2' />"
- + "</node>"
- + "<node name='Service 2' async='true'>"
- + "<action class='"
- + SimpleAction2.class.getName()
- + "' />"
- + "<transition to='end-state1' />"
- + "</node>"
- + "<end-state name='end-state1' />"
- + "</process-definition>";
-
- protected void setUp() throws SQLException
- {
- jbpmConfiguration.createSchema();
-
- // deploy process definition
- JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try
- {
- jbpmContext.deployProcessDefinition(ProcessDefinition.parseXmlString(PROCESS_DEFINITION));
- }
- finally
- {
- jbpmContext.close();
- }
- }
-
- public void testMultipleJobExecutors()
- {
- // start job executors
- for (int i = 0; i < executors.length; i++)
- {
- executors[i] = (JobExecutor)JbpmConfiguration.Configs.getObjectFactory().createObject("jbpm.job.executor");
- executors[i].setName("JbpmJobExecutor/" + (i + 1));
- executors[i].start();
- }
-
- // kick off process instance
- JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try
- {
- ProcessInstance processInstance = jbpmContext.newProcessInstanceForUpdate(PROCESS_NAME);
- processInstance.getContextInstance().setVariable("eventCallback", new EventCallback());
- processInstance.signal();
- }
- finally
- {
- jbpmContext.close();
- }
-
- // wait for process end
- EventCallback.waitForEvent(Event.EVENTTYPE_PROCESS_END);
-
- // stop job executors
- for (int i = executors.length - 1; i >= 0; i--)
- {
- try
- {
- executors[i].stopAndJoin();
- }
- catch (InterruptedException e)
- {
- // continue to next executor
- }
- }
-
- assertEquals(1, SimpleAction2.getExecutionCount());
- }
-
- protected void tearDown()
- {
- jbpmConfiguration.dropSchema();
- }
-
- public static class SimpleAction implements ActionHandler
- {
-
- private static final long serialVersionUID = 1L;
-
- public void execute(ExecutionContext exeContext) throws Exception
- {
- exeContext.leaveNode();
- }
-
- }
-
- public static class SimpleAction2 implements ActionHandler
- {
-
- private static int executionCount = 0;
-
- private static final long serialVersionUID = 1L;
-
- public void execute(ExecutionContext exeContext) throws Exception
- {
- incrementCount();
- exeContext.leaveNode();
- }
-
- private static synchronized int incrementCount()
- {
- return ++executionCount;
- }
-
- public static synchronized int getExecutionCount()
- {
- return executionCount;
- }
- }
-}
Deleted: jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/NoJobExecutorDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/NoJobExecutorDbTest.java 2008-09-11 05:59:58 UTC (rev 2170)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/NoJobExecutorDbTest.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -1,66 +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.job.executor;
-
-import junit.framework.TestCase;
-
-import org.jbpm.JbpmConfiguration;
-import org.jbpm.JbpmContext;
-import org.jbpm.configuration.ObjectFactory;
-import org.jbpm.graph.def.ProcessDefinition;
-import org.jbpm.graph.exe.ProcessInstance;
-
-/**
- * Test case or JBPM-1452
- * @author Alejandro Guizar
- */
-public class NoJobExecutorDbTest extends TestCase {
-
- private JbpmContext jbpmContext;
-
- private static JbpmConfiguration jbpmConfiguration = JbpmConfiguration.parseXmlString(
- "<jbpm-configuration>" +
- " <null name='jbpm.job.executor' />" +
- "</jbpm-configuration>");
-
- public void setUp() throws Exception {
- jbpmConfiguration.createSchema();
- jbpmContext = jbpmConfiguration.createJbpmContext();
- }
-
- public void tearDown() throws Exception {
- jbpmContext.close();
- jbpmConfiguration.dropSchema();
- }
-
- public void testNoJobExecutor() {
- // check the job executor is properly nullified
- ObjectFactory objectFactory = jbpmContext.getObjectFactory();
- assertTrue("expected object factory to have object jbpm.job.executor",
- objectFactory.hasObject("jbpm.job.executor"));
- assertNull(objectFactory.createObject("jbpm.job.executor"));
- // start and end a process instance, no exception should be thrown
- jbpmContext.deployProcessDefinition(new ProcessDefinition("Audit"));
- ProcessInstance processInstance = jbpmContext.newProcessInstanceForUpdate("Audit");
- processInstance.end();
- }
-}
Deleted: jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/TimerOnTimerDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/TimerOnTimerDbTest.java 2008-09-11 05:59:58 UTC (rev 2170)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/TimerOnTimerDbTest.java 2008-09-11 06:47:07 UTC (rev 2171)
@@ -1,64 +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.job.executor;
-
-import org.jbpm.db.AbstractDbTestCase;
-import org.jbpm.graph.def.Event;
-import org.jbpm.graph.def.ProcessDefinition;
-import org.jbpm.graph.exe.ProcessInstance;
-
-/**
- * Test case for JBPM-1135
- * @author Alejandro Guizar
- */
-public class TimerOnTimerDbTest extends AbstractDbTestCase {
-
- public void testTimerOnTimer() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlResource("org/jbpm/job/executor/timerprocess.xml");
- jbpmContext.deployProcessDefinition(processDefinition);
-
- ProcessInstance processInstance = jbpmContext.newProcessInstanceForUpdate("timerProcess");
- processInstance.getContextInstance().setVariable("eventCallback", new EventCallback());
- processInstance.signal();
- assertEquals("firstNode", processInstance.getRootToken().getNode().getName());
- commitAndCloseSession();
-
- startJobExecutor();
- try {
- EventCallback.waitForEvent(Event.EVENTTYPE_NODE_ENTER);
- beginSessionTransaction();
- long processInstanceId = processInstance.getId();
- assertEquals("secondNode", jbpmContext.loadProcessInstance(processInstanceId)
- .getRootToken()
- .getNode()
- .getName());
- commitAndCloseSession();
-
- EventCallback.waitForEvent(Event.EVENTTYPE_PROCESS_END);
- beginSessionTransaction();
- assertTrue(jbpmContext.loadProcessInstance(processInstanceId).hasEnded());
- }
- finally {
- stopJobExecutor();
- }
- }
-}
Copied: jbpm3/trunk/modules/core/src/test/resources/org/jbpm/jbpm1135/timerprocess.xml (from rev 2169, jbpm3/trunk/modules/core/src/test/resources/org/jbpm/job/executor/timerprocess.xml)
===================================================================
--- jbpm3/trunk/modules/core/src/test/resources/org/jbpm/jbpm1135/timerprocess.xml (rev 0)
+++ jbpm3/trunk/modules/core/src/test/resources/org/jbpm/jbpm1135/timerprocess.xml 2008-09-11 06:47:07 UTC (rev 2171)
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<process-definition name="timerProcess" xmlns="urn:jbpm.org:jpdl-3.2"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="urn:jbpm.org:jpdl-3.2 http://jbpm.org/xsd/jpdl-3.2.xsd">
+
+ <event type="process-start">
+ <action expression="#{eventCallback.processStart}"/>
+ </event>
+ <event type="process-end">
+ <action expression="#{eventCallback.processEnd}"/>
+ </event>
+ <event type="node-enter">
+ <action expression="#{eventCallback.nodeEnter}" />
+ </event>
+ <event type="node-leave">
+ <action expression="#{eventCallback.nodeLeave}" />
+ </event>
+
+ <start-state name="start">
+ <transition name="doneStart" to="firstNode" />
+ </start-state>
+
+ <task-node name="firstNode" end-tasks="yes">
+ <task name="firstTask">
+ <assignment actor-id="admin" />
+ <timer duedate="1 second" transition="doneFirst" />
+ </task>
+ <transition name="doneFirst" to="secondNode" />
+ </task-node>
+
+ <task-node name="secondNode" end-tasks="yes">
+ <task name="secondTask">
+ <assignment actor-id="admin" />
+ <timer duedate="1 second" transition="doneSecond" />
+ </task>
+ <transition name="doneSecond" to="end" />
+ </task-node>
+
+ <end-state name="end" />
+
+</process-definition>
\ No newline at end of file
Copied: jbpm3/trunk/modules/core/src/test/resources/org/jbpm/jbpm522 (from rev 2169, jbpm3/trunk/modules/core/src/test/resources/org/jbpm/ant)
Deleted: jbpm3/trunk/modules/core/src/test/resources/org/jbpm/job/executor/.gpd.timerprocess.xml
===================================================================
--- jbpm3/trunk/modules/core/src/test/resources/org/jbpm/job/executor/.gpd.timerprocess.xml 2008-09-11 05:59:58 UTC (rev 2170)
+++ jbpm3/trunk/modules/core/src/test/resources/org/jbpm/job/executor/.gpd.timerprocess.xml 2008-09-11 06:47:07 UTC (rev 2171)
@@ -1,3 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<root-container/>
\ No newline at end of file
Deleted: jbpm3/trunk/modules/core/src/test/resources/org/jbpm/job/executor/timerprocess.xml
===================================================================
--- jbpm3/trunk/modules/core/src/test/resources/org/jbpm/job/executor/timerprocess.xml 2008-09-11 05:59:58 UTC (rev 2170)
+++ jbpm3/trunk/modules/core/src/test/resources/org/jbpm/job/executor/timerprocess.xml 2008-09-11 06:47:07 UTC (rev 2171)
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<process-definition name="timerProcess" xmlns="urn:jbpm.org:jpdl-3.2"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="urn:jbpm.org:jpdl-3.2 http://jbpm.org/xsd/jpdl-3.2.xsd">
-
- <event type="process-start">
- <action expression="#{eventCallback.processStart}"/>
- </event>
- <event type="process-end">
- <action expression="#{eventCallback.processEnd}"/>
- </event>
- <event type="node-enter">
- <action expression="#{eventCallback.nodeEnter}" />
- </event>
- <event type="node-leave">
- <action expression="#{eventCallback.nodeLeave}" />
- </event>
-
- <start-state name="start">
- <transition name="doneStart" to="firstNode" />
- </start-state>
-
- <task-node name="firstNode" end-tasks="yes">
- <task name="firstTask">
- <assignment actor-id="admin" />
- <timer duedate="1 second" transition="doneFirst" />
- </task>
- <transition name="doneFirst" to="secondNode" />
- </task-node>
-
- <task-node name="secondNode" end-tasks="yes">
- <task name="secondTask">
- <assignment actor-id="admin" />
- <timer duedate="1 second" transition="doneSecond" />
- </task>
- <transition name="doneSecond" to="end" />
- </task-node>
-
- <end-state name="end" />
-
-</process-definition>
\ No newline at end of file
17 years, 7 months
JBoss JBPM SVN: r2170 - jbpm3/trunk/hudson.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-11 01:59:58 -0400 (Thu, 11 Sep 2008)
New Revision: 2170
Removed:
jbpm3/trunk/hudson/.classpath
Modified:
jbpm3/trunk/hudson/.project
Log:
Remove the Java nature
Deleted: jbpm3/trunk/hudson/.classpath
===================================================================
--- jbpm3/trunk/hudson/.classpath 2008-09-11 00:18:38 UTC (rev 2169)
+++ jbpm3/trunk/hudson/.classpath 2008-09-11 05:59:58 UTC (rev 2170)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="target"/>
-</classpath>
Modified: jbpm3/trunk/hudson/.project
===================================================================
--- jbpm3/trunk/hudson/.project 2008-09-11 00:18:38 UTC (rev 2169)
+++ jbpm3/trunk/hudson/.project 2008-09-11 05:59:58 UTC (rev 2170)
@@ -4,14 +4,4 @@
<comment></comment>
<projects>
</projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
</projectDescription>
17 years, 7 months
JBoss JBPM SVN: r2169 - in jbpm3/trunk/modules: enterprise/jar/src/main/java/org/jbpm/ejb and 3 other directories.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2008-09-10 20:18:38 -0400 (Wed, 10 Sep 2008)
New Revision: 2169
Modified:
jbpm3/trunk/modules/core/src/main/java/org/jbpm/jpdl/xml/JpdlXmlReader.java
jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/ejb/LocalTimerEntityHome.java
jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/ejb/impl/TimerEntityBean.java
jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/scheduler/ejbtimer/EntitySchedulerService.java
jbpm3/trunk/modules/enterprise/jar/src/main/resources/META-INF/ejb-jar.xml
Log:
[JBPM-1708] revised ejb queries to address entity not found exceptions
Modified: jbpm3/trunk/modules/core/src/main/java/org/jbpm/jpdl/xml/JpdlXmlReader.java
===================================================================
--- jbpm3/trunk/modules/core/src/main/java/org/jbpm/jpdl/xml/JpdlXmlReader.java 2008-09-10 23:48:04 UTC (rev 2168)
+++ jbpm3/trunk/modules/core/src/main/java/org/jbpm/jpdl/xml/JpdlXmlReader.java 2008-09-11 00:18:38 UTC (rev 2169)
@@ -70,12 +70,15 @@
protected String initialNodeName = null;
protected Collection unresolvedTransitionDestinations = null;
protected Collection unresolvedActionReferences = null;
-
+
/**
* the parsed process definition as DOM tree (available after readProcessDefinition)
*/
protected Document document;
-
+
+ /** for autonumbering anonymous timers. */
+ private int timerNumber;
+
public JpdlXmlReader(InputSource inputSource) {
this.inputSource = inputSource;
}
@@ -540,6 +543,7 @@
protected void readNodeTimer(Element timerElement, Node node) {
String name = timerElement.attributeValue("name", node.getName());
+ if (name == null) name = generateTimerName();
CreateTimerAction createTimerAction = new CreateTimerAction();
createTimerAction.read(timerElement, this);
@@ -551,7 +555,11 @@
cancelTimerAction.setTimerName(name);
addAction(node, Event.EVENTTYPE_NODE_LEAVE, cancelTimerAction);
}
-
+
+ private String generateTimerName() {
+ return "timer-" + (timerNumber++);
+ }
+
protected void readTaskTimers(Element taskElement, Task task) {
Iterator iter = taskElement.elementIterator();
while (iter.hasNext()) {
@@ -566,8 +574,8 @@
protected void readTaskTimer(Element timerElement, Task task) {
String name = timerElement.attributeValue("name", task.getName());
- if (name==null) name = "timer-for-task-"+task.getId();
-
+ if (name==null) name = generateTimerName();
+
CreateTimerAction createTimerAction = new CreateTimerAction();
createTimerAction.read(timerElement, this);
createTimerAction.setTimerName(name);
Modified: jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/ejb/LocalTimerEntityHome.java
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/ejb/LocalTimerEntityHome.java 2008-09-10 23:48:04 UTC (rev 2168)
+++ jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/ejb/LocalTimerEntityHome.java 2008-09-11 00:18:38 UTC (rev 2169)
@@ -10,12 +10,10 @@
public LocalTimerEntity create() throws CreateException;
- public LocalTimerEntity findByPrimaryKey(Long key) throws FinderException;
+ public LocalTimerEntity findByPrimaryKey(Long timerId) throws FinderException;
- public Collection findByTokenId(Long key) throws FinderException;
-
- public Collection findByTokenIdAndName(Long key, String name)
+ public Collection findByNameAndTokenId(String name, Long tokenId)
throws FinderException;
- public Collection findByProcessInstanceId(Long key) throws FinderException;
+ public Collection findByProcessInstanceId(Long processInstanceId) throws FinderException;
}
Modified: jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/ejb/impl/TimerEntityBean.java
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/ejb/impl/TimerEntityBean.java 2008-09-10 23:48:04 UTC (rev 2168)
+++ jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/ejb/impl/TimerEntityBean.java 2008-09-11 00:18:38 UTC (rev 2169)
@@ -74,9 +74,9 @@
public abstract void setProcessInstanceId(Long processInstanceId);
- public abstract char getDiscriminator();
+ public abstract String getDiscriminator();
- public abstract void setDiscriminator(char discriminator);
+ public abstract void setDiscriminator(String discriminator);
public void ejbActivate() {
try {
Modified: jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/scheduler/ejbtimer/EntitySchedulerService.java
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/scheduler/ejbtimer/EntitySchedulerService.java 2008-09-10 23:48:04 UTC (rev 2168)
+++ jbpm3/trunk/modules/enterprise/jar/src/main/java/org/jbpm/scheduler/ejbtimer/EntitySchedulerService.java 2008-09-11 00:18:38 UTC (rev 2169)
@@ -64,13 +64,7 @@
public void deleteTimersByName(String timerName, Token token) {
try {
- Collection timerEntities;
- if(timerName == null || timerName.equals("")) {
- timerEntities = timerEntityHome.findByTokenId(new Long(token.getId()));
- }
- else {
- timerEntities = timerEntityHome.findByTokenIdAndName(new Long(token.getId()), timerName);
- }
+ Collection timerEntities = timerEntityHome.findByNameAndTokenId(timerName, new Long(token.getId()));
log.debug("found " + timerEntities.size() + " timer entities by name '" + timerName + "' for " + token);
for (Iterator i = timerEntities.iterator(); i.hasNext();) {
LocalTimerEntity timerEntity = (LocalTimerEntity) i.next();
Modified: jbpm3/trunk/modules/enterprise/jar/src/main/resources/META-INF/ejb-jar.xml
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/src/main/resources/META-INF/ejb-jar.xml 2008-09-10 23:48:04 UTC (rev 2168)
+++ jbpm3/trunk/modules/enterprise/jar/src/main/resources/META-INF/ejb-jar.xml 2008-09-11 00:18:38 UTC (rev 2169)
@@ -247,37 +247,22 @@
</ejb-local-ref>
<query>
- <description>Retrieve all timers by token identifier</description>
+ <description>Retrieve all timers by name and token identifier</description>
<query-method>
- <method-name>findByTokenId</method-name>
+ <method-name>findByNameAndTokenId</method-name>
<method-params>
+ <method-param>java.lang.String</method-param>
<method-param>java.lang.Long</method-param>
</method-params>
</query-method>
<ejb-ql><![CDATA[
select object(obj)
from TimerEntityBean obj
- where obj.tokenId = ?1 and obj.discriminator = 84
+ where obj.name = ?1 and obj.tokenId = ?2 and obj.discriminator = 'T'
]]></ejb-ql>
</query>
<query>
- <description>Retrieve all timers by token identifier and name</description>
- <query-method>
- <method-name>findByTokenIdAndName</method-name>
- <method-params>
- <method-param>java.lang.Long</method-param>
- <method-param>java.lang.String</method-param>
- </method-params>
- </query-method>
- <ejb-ql><![CDATA[
- select object(obj)
- from TimerEntityBean obj
- where obj.tokenId = ?1 and obj.name = ?2 and obj.discriminator = 84
- ]]></ejb-ql>
- </query>
-
- <query>
<description>Retrieve all timers by process instance identifier</description>
<query-method>
<method-name>findByProcessInstanceId</method-name>
@@ -288,7 +273,7 @@
<ejb-ql><![CDATA[
select object(obj)
from TimerEntityBean obj
- where obj.processInstanceId = ?1 and obj.discriminator = 84
+ where obj.processInstanceId = ?1 and obj.discriminator = 'T'
]]></ejb-ql>
</query>
</entity>
17 years, 7 months
JBoss JBPM SVN: r2168 - in jbpm3/trunk/modules/distribution/src/main/resources: destination and 1 other directories.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2008-09-10 19:48:04 -0400 (Wed, 10 Sep 2008)
New Revision: 2168
Added:
jbpm3/trunk/modules/distribution/src/main/resources/destination/
jbpm3/trunk/modules/distribution/src/main/resources/destination/jbpm-destinations-service.xml
Modified:
jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
Log:
[JBPM-1726] added jms destinations service descriptor and install option
Added: jbpm3/trunk/modules/distribution/src/main/resources/destination/jbpm-destinations-service.xml
===================================================================
--- jbpm3/trunk/modules/distribution/src/main/resources/destination/jbpm-destinations-service.xml (rev 0)
+++ jbpm3/trunk/modules/distribution/src/main/resources/destination/jbpm-destinations-service.xml 2008-09-10 23:48:04 UTC (rev 2168)
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id: jbossmq-destinations-service.xml 25907 2004-11-16 04:32:39Z ejort $ -->
+
+<!--
+ 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.
+
+ You can add other destinations to this file, or you can create other
+ *-service.xml files to contain your application's destinations.
+ -->
+
+<server>
+ <!--
+ Destinations without a configured SecurityManager or without a
+ SecurityConf will default to role guest with read=true, write=true,
+ create=false.
+ -->
+
+ <mbean code="org.jboss.mq.server.jmx.Queue"
+ name="jboss.mq.destination:service=Queue,name=JbpmJobQueue">
+ <depends optional-attribute-name="DestinationManager">jboss.mq:service=DestinationManager</depends>
+ </mbean>
+
+ <mbean code="org.jboss.mq.server.jmx.Queue"
+ name="jboss.mq.destination:service=Queue,name=JbpmCommandQueue">
+ <depends optional-attribute-name="DestinationManager">jboss.mq:service=DestinationManager</depends>
+ </mbean>
+
+</server>
Modified: jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
===================================================================
--- jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-10 14:50:23 UTC (rev 2167)
+++ jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-10 23:48:04 UTC (rev 2168)
@@ -212,5 +212,11 @@
<file src="@{resources.dir}/database/jbpm-postgresql-ds.xml" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm" />
<singlefile src="@{deploy.artifacts.dir}/resources/jbpm-core-config/hibernate.cfg.postgresql.xml" target="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar/hibernate.cfg.xml" />
</pack>
+
+ <!-- jBPM JMS Destinations -->
+ <pack name="jBPM3 JMS Destinations" required="no" preselected="yes">
+ <description>The JMS Destinations</description>
+ <file src="@{resources.dir}/destination/jbpm-destinations-service.xml" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm" />
+ </pack>
</packs>
</installation>
\ No newline at end of file
17 years, 7 months
JBoss JBPM SVN: r2167 - jbpm3/trunk/modules/distribution/src/main/resources/installer.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-10 10:50:23 -0400 (Wed, 10 Sep 2008)
New Revision: 2167
Modified:
jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
Log:
fix path for download-helper.xml
Modified: jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
===================================================================
--- jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-10 14:46:37 UTC (rev 2166)
+++ jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-10 14:50:23 UTC (rev 2167)
@@ -151,7 +151,7 @@
<pack name="Download Eclipse-3.4.0" required="no" parent="Optional Downloads" preselected="no">
<description>Download and Install Eclipse-3.4.0</description>
<!-- http://jira.codehaus.org/browse/IZPACK-158 -->
- <file src="@{resources.dir}/installer/download-helper.xml" targetdir="$INSTALL_PATH/tmp"/>
+ <file src="@{resources.dir}/installer/download-helper.xml" targetdir="$INSTALL_PATH/Uninstaller"/>
</pack>
<!-- jBPM3 Server Components -->
17 years, 7 months
JBoss JBPM SVN: r2166 - in jbpm3/trunk: modules/distribution and 1 other directories.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-10 10:46:37 -0400 (Wed, 10 Sep 2008)
New Revision: 2166
Modified:
jbpm3/trunk/modules/distribution/pom.xml
jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
jbpm3/trunk/pom.xml
Log:
Add GPD to distro
Modified: jbpm3/trunk/modules/distribution/pom.xml
===================================================================
--- jbpm3/trunk/modules/distribution/pom.xml 2008-09-10 14:12:01 UTC (rev 2165)
+++ jbpm3/trunk/modules/distribution/pom.xml 2008-09-10 14:46:37 UTC (rev 2166)
@@ -85,6 +85,11 @@
<version>${version}</version>
<type>jdocbook</type>
</dependency>
+ <dependency>
+ <groupId>org.jbpm</groupId>
+ <artifactId>jbpm-jpdl-designer</artifactId>
+ <type>zip</type>
+ </dependency>
<!-- Sources -->
<dependency>
Modified: jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
===================================================================
--- jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-10 14:12:01 UTC (rev 2165)
+++ jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-10 14:46:37 UTC (rev 2166)
@@ -102,6 +102,11 @@
<file src="@{deploy.artifacts.dir}/etc/JBossORG-EULA.txt" targetdir="$INSTALL_PATH/jbpm3"
override="true" />
+ <!-- jbpm3/designer -->
+ <fileset dir="@{deploy.artifacts.dir}/lib" targetdir="$INSTALL_PATH/jbpm3/designer" override="true">
+ <include name="jbpm-jpdl-designer.zip" />
+ </fileset>
+
<!-- jbpm3/lib -->
<fileset dir="@{deploy.artifacts.dir}/lib" targetdir="$INSTALL_PATH/jbpm3/lib" override="true">
<include name="jbpm-enterprise-archive.ear" />
Modified: jbpm3/trunk/pom.xml
===================================================================
--- jbpm3/trunk/pom.xml 2008-09-10 14:12:01 UTC (rev 2165)
+++ jbpm3/trunk/pom.xml 2008-09-10 14:46:37 UTC (rev 2166)
@@ -68,6 +68,7 @@
<javax.jaxb.version>2.1</javax.jaxb.version>
<jaxen.version>1.1.1</jaxen.version>
<jboss.bpm.api.version>1.0.0-Alpha1</jboss.bpm.api.version>
+ <jboss.jbpm.designer.version>3.1.4</jboss.jbpm.designer.version>
<jboss.gravel.version>1.0.0.GA</jboss.gravel.version>
<jboss.seam.version>2.0.2.GA</jboss.seam.version>
<junit.version>3.8.1</junit.version>
@@ -98,6 +99,12 @@
<version>${jboss.bpm.api.version}</version>
<type>zip</type>
</dependency>
+ <dependency>
+ <groupId>org.jbpm</groupId>
+ <artifactId>jbpm-jpdl-designer</artifactId>
+ <version>${jboss.jbpm.designer.version}</version>
+ <type>zip</type>
+ </dependency>
<!-- Thirdparty Dependencies -->
<dependency>
17 years, 7 months
JBoss JBPM SVN: r2165 - in jbpm3/trunk: modules/core and 1 other directory.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-10 10:12:01 -0400 (Wed, 10 Sep 2008)
New Revision: 2165
Modified:
jbpm3/trunk/hudson/hudson-home/command.sh
jbpm3/trunk/modules/core/pom.xml
Log:
Another attempt to fix the OOM error
Modified: jbpm3/trunk/hudson/hudson-home/command.sh
===================================================================
--- jbpm3/trunk/hudson/hudson-home/command.sh 2008-09-10 13:02:58 UTC (rev 2164)
+++ jbpm3/trunk/hudson/hudson-home/command.sh 2008-09-10 14:12:01 UTC (rev 2165)
@@ -9,9 +9,6 @@
JBPMDIR=$WORKSPACE/jbpm
DISTRODIR=$JBPMDIR/modules/distribution/target
-# Give Maven some more heap
-export MAVEN_OPTS=-Xmx512m
-
case "$CONTAINER" in
jboss422*)
JBOSS_BUILD=jboss-4.2.2.GA
Modified: jbpm3/trunk/modules/core/pom.xml
===================================================================
--- jbpm3/trunk/modules/core/pom.xml 2008-09-10 13:02:58 UTC (rev 2164)
+++ jbpm3/trunk/modules/core/pom.xml 2008-09-10 14:12:01 UTC (rev 2165)
@@ -25,12 +25,14 @@
<version>3.3.0-SNAPSHOT</version>
</parent>
+ <!-- Properties -->
+ <properties>
+ <surefire.jvm.args>-Xmx512m</surefire.jvm.args>
+ </properties>
+
<!-- Dependencies -->
<dependencies>
<!-- jBPM Dependencies -->
- <!--
- dependency> <groupId>org.jboss.jbpm</groupId> <artifactId>jbpm-api</artifactId> <version>${version}</version> </dependency
- -->
<!-- Compile Dependencies -->
<dependency>
@@ -152,6 +154,12 @@
</execution>
</executions>
</plugin>
+ <plugin>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <argLine>${surefire.jvm.args}</argLine>
+ </configuration>
+ </plugin>
</plugins>
</build>
17 years, 7 months