JBoss JBPM SVN: r2154 - jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-09 10:49:37 -0400 (Tue, 09 Sep 2008)
New Revision: 2154
Modified:
jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/MultiJobExecutorDbTest.java
Log:
Comment System.out.println in core tests
Modified: 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-09 14:41:32 UTC (rev 2153)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/MultiJobExecutorDbTest.java 2008-09-09 14:49:37 UTC (rev 2154)
@@ -49,36 +49,42 @@
+ "<end-state name='end-state1' />"
+ "</process-definition>";
- protected void setUp() throws SQLException {
+ protected void setUp() throws SQLException
+ {
jbpmConfiguration.createSchema();
// deploy process definition
JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
+ try
+ {
jbpmContext.deployProcessDefinition(ProcessDefinition.parseXmlString(PROCESS_DEFINITION));
}
- finally {
+ finally
+ {
jbpmContext.close();
}
}
- public void testMultipleJobExecutors() {
+ public void testMultipleJobExecutors()
+ {
// start job executors
- for (int i = 0; i < executors.length; i++) {
- executors[i] = (JobExecutor) JbpmConfiguration.Configs.getObjectFactory().createObject(
- "jbpm.job.executor");
+ 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 {
+ try
+ {
ProcessInstance processInstance = jbpmContext.newProcessInstanceForUpdate(PROCESS_NAME);
processInstance.getContextInstance().setVariable("eventCallback", new EventCallback());
processInstance.signal();
}
- finally {
+ finally
+ {
jbpmContext.close();
}
@@ -86,11 +92,14 @@
EventCallback.waitForEvent(Event.EVENTTYPE_PROCESS_END);
// stop job executors
- for (int i = executors.length - 1; i >= 0; i--) {
- try {
+ for (int i = executors.length - 1; i >= 0; i--)
+ {
+ try
+ {
executors[i].stopAndJoin();
}
- catch (InterruptedException e) {
+ catch (InterruptedException e)
+ {
// continue to next executor
}
}
@@ -98,37 +107,43 @@
assertEquals(1, SimpleAction2.getExecutionCount());
}
- protected void tearDown() {
+ protected void tearDown()
+ {
jbpmConfiguration.dropSchema();
}
- public static class SimpleAction implements ActionHandler {
+ public static class SimpleAction implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext exeContext) throws Exception {
- // System.out.println("Action 1");
+ public void execute(ExecutionContext exeContext) throws Exception
+ {
exeContext.leaveNode();
}
}
- public static class SimpleAction2 implements ActionHandler {
+ public static class SimpleAction2 implements ActionHandler
+ {
private static int executionCount = 0;
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext exeContext) throws Exception {
- // System.out.println("Action 2: " + incrementCount());
+ public void execute(ExecutionContext exeContext) throws Exception
+ {
+ incrementCount();
exeContext.leaveNode();
}
- private static synchronized int incrementCount() {
+ private static synchronized int incrementCount()
+ {
return ++executionCount;
}
- public static synchronized int getExecutionCount() {
+ public static synchronized int getExecutionCount()
+ {
return executionCount;
}
}
17 years, 7 months
JBoss JBPM SVN: r2153 - in jbpm3/trunk/modules/core/src/test/java/org/jbpm: graph/exe and 6 other directories.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-09 10:41:32 -0400 (Tue, 09 Sep 2008)
New Revision: 2153
Modified:
jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/exe/TokenVariableMapDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/ActionExceptionsTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/BusinessKeyDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/ExceptionHandlingTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/JobExecutorDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/el/DecisionExpressionTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/par/ResourceAction.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/SchemaTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/msg/command/AsyncExecutionDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/optimisticlocking/LockingTest.java
Log:
Remove unwanted test output
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/exe/TokenVariableMapDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/exe/TokenVariableMapDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/exe/TokenVariableMapDbTest.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -21,33 +21,37 @@
*/
package org.jbpm.context.exe;
-import java.util.*;
+import java.util.HashMap;
+import java.util.Map;
-import org.jbpm.context.def.*;
-import org.jbpm.context.exe.variableinstance.*;
-import org.jbpm.db.*;
-import org.jbpm.graph.def.*;
-import org.jbpm.graph.exe.*;
+import org.jbpm.context.def.ContextDefinition;
+import org.jbpm.context.exe.variableinstance.StringInstance;
+import org.jbpm.db.AbstractDbTestCase;
+import org.jbpm.graph.def.ProcessDefinition;
+import org.jbpm.graph.exe.ProcessInstance;
+import org.jbpm.graph.exe.Token;
-public class TokenVariableMapDbTest extends AbstractDbTestCase {
-
+public class TokenVariableMapDbTest extends AbstractDbTestCase
+{
+
ProcessDefinition processDefinition;
ProcessInstance processInstance;
Token token;
ContextInstance contextInstance;
Map tokenVariableMaps;
TokenVariableMap tokenVariableMap;
-
- public void setUp() throws Exception {
+
+ public void setUp() throws Exception
+ {
super.setUp();
-
+
processDefinition = new ProcessDefinition();
processDefinition.addDefinition(new ContextDefinition());
graphSession.saveProcessDefinition(processDefinition);
-
+
processInstance = new ProcessInstance(processDefinition);
token = processInstance.getRootToken();
-
+
contextInstance = processInstance.getContextInstance();
tokenVariableMaps = new HashMap();
tokenVariableMap = contextInstance.getOrCreateTokenVariableMap(token);
@@ -55,32 +59,35 @@
contextInstance.tokenVariableMaps = tokenVariableMaps;
}
- public void testTokenVariableMapContextInstance() {
+ public void testTokenVariableMapContextInstance()
+ {
processInstance = saveAndReload(processInstance);
token = processInstance.getRootToken();
contextInstance = processInstance.getContextInstance();
tokenVariableMaps = contextInstance.tokenVariableMaps;
- tokenVariableMap = (TokenVariableMap) tokenVariableMaps.get(token);
-
+ tokenVariableMap = (TokenVariableMap)tokenVariableMaps.get(token);
+
assertSame(contextInstance, tokenVariableMap.getContextInstance());
}
- public void testTokenVariableMapToken() {
+ public void testTokenVariableMapToken()
+ {
processInstance = saveAndReload(processInstance);
token = processInstance.getRootToken();
contextInstance = processInstance.getContextInstance();
tokenVariableMaps = contextInstance.tokenVariableMaps;
- tokenVariableMap = (TokenVariableMap) tokenVariableMaps.get(token);
-
+ tokenVariableMap = (TokenVariableMap)tokenVariableMaps.get(token);
+
assertSame(token, tokenVariableMap.getToken());
}
- public void testTokenVariableMapVariableInstances() {
- StringInstance stringVariable = (StringInstance) VariableInstance.create(token, "one", "hello");
+ public void testTokenVariableMapVariableInstances()
+ {
+ StringInstance stringVariable = (StringInstance)VariableInstance.create(token, "one", "hello");
tokenVariableMap.addVariableInstance(stringVariable);
- stringVariable = (StringInstance) VariableInstance.create(token, "two", "world");
+ stringVariable = (StringInstance)VariableInstance.create(token, "two", "world");
tokenVariableMap.addVariableInstance(stringVariable);
processInstance = saveAndReload(processInstance);
@@ -88,12 +95,12 @@
token = processInstance.getRootToken();
contextInstance = processInstance.getContextInstance();
tokenVariableMaps = contextInstance.tokenVariableMaps;
- tokenVariableMap = (TokenVariableMap) tokenVariableMaps.get(processInstance.getRootToken());
-
- System.out.println(tokenVariableMap.getVariable("one"));
- System.out.println(tokenVariableMap.getVariable("two"));
-
- assertEquals("hello", ((StringInstance)tokenVariableMap.variableInstances.get("one")).getValue() );
- assertEquals("world", ((StringInstance)tokenVariableMap.variableInstances.get("two")).getValue() );
+ tokenVariableMap = (TokenVariableMap)tokenVariableMaps.get(processInstance.getRootToken());
+
+ // System.out.println(tokenVariableMap.getVariable("one"));
+ // System.out.println(tokenVariableMap.getVariable("two"));
+
+ assertEquals("hello", ((StringInstance)tokenVariableMap.variableInstances.get("one")).getValue());
+ assertEquals("world", ((StringInstance)tokenVariableMap.variableInstances.get("two")).getValue());
}
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/ActionExceptionsTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/ActionExceptionsTest.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/ActionExceptionsTest.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -26,66 +26,53 @@
import org.jbpm.graph.def.ActionHandler;
import org.jbpm.graph.def.ProcessDefinition;
-public class ActionExceptionsTest extends TestCase {
+public class ActionExceptionsTest extends TestCase
+{
- public static class FailingAction implements ActionHandler {
+ public static class FailingAction implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext context) {
+
+ public void execute(ExecutionContext context)
+ {
throw new IllegalArgumentException();
}
}
- public void testFailingReferenced() throws Exception {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state name='start'>" +
- " <transition to='state'/>" +
- " </start-state>" +
- " <state name='state'>" +
- " <transition to='end'>" +
- " <action ref-name='failing'/>" +
- " </transition>"+
- " </state>" +
- " <end-state name='end'/>" +
- " <action name='failing' class='org.jbpm.graph.exe.ActionExceptionsTest$FailingAction'/>"+
- "</process-definition>");
+ public void testFailingReferenced() throws Exception
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state name='start'>" + " <transition to='state'/>"
+ + " </start-state>" + " <state name='state'>" + " <transition to='end'>" + " <action ref-name='failing'/>" + " </transition>" + " </state>"
+ + " <end-state name='end'/>" + " <action name='failing' class='org.jbpm.graph.exe.ActionExceptionsTest$FailingAction'/>" + "</process-definition>");
ProcessInstance pi = new ProcessInstance(processDefinition);
pi.signal();
- try {
+ try
+ {
pi.signal();
- } catch (RuntimeException e) {
- e.printStackTrace();
- // ObjectAssert.assertInstanceOf(IllegalArgumentException.class,
- // e.getCause());
+ }
+ catch (RuntimeException e)
+ {
assertTrue(e.getCause() instanceof IllegalArgumentException);
return;
}
fail("should have throws IllegalArgumentException");
}
- public void testFailingNotReferenced() throws Exception {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state name='start'>" +
- " <transition to='state'/>" +
- " </start-state>" +
- " <state name='state'>" +
- " <transition to='end'>" +
- " <action class='org.jbpm.graph.exe.ActionExceptionsTest$FailingAction'/>" +
- " </transition>" +
- " </state>" +
- " <end-state name='end'/>" +
- "</process-definition>");
+ public void testFailingNotReferenced() throws Exception
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state name='start'>" + " <transition to='state'/>"
+ + " </start-state>" + " <state name='state'>" + " <transition to='end'>" + " <action class='org.jbpm.graph.exe.ActionExceptionsTest$FailingAction'/>"
+ + " </transition>" + " </state>" + " <end-state name='end'/>" + "</process-definition>");
ProcessInstance pi = new ProcessInstance(processDefinition);
pi.signal();
- try {
+ try
+ {
pi.signal();
- } catch (RuntimeException e) {
- e.printStackTrace();
- // ObjectAssert.assertInstanceOf(IllegalArgumentException.class,
- // e.getCause());
+ }
+ catch (RuntimeException e)
+ {
assertTrue(e.getCause() instanceof IllegalArgumentException);
return;
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/BusinessKeyDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/BusinessKeyDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/BusinessKeyDbTest.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -3,19 +3,21 @@
import org.jbpm.db.AbstractDbTestCase;
import org.jbpm.graph.def.ProcessDefinition;
-public class BusinessKeyDbTest extends AbstractDbTestCase {
+public class BusinessKeyDbTest extends AbstractDbTestCase
+{
- public void testSimpleBusinessKey() {
+ public void testSimpleBusinessKey()
+ {
ProcessDefinition processDefinition = new ProcessDefinition("businesskeytest");
jbpmContext.deployProcessDefinition(processDefinition);
-
+
newTransaction();
-
+
ProcessInstance processInstance = jbpmContext.newProcessInstanceForUpdate("businesskeytest");
processInstance.setKey("businesskey1");
newTransaction();
-
+
processInstance = jbpmContext.newProcessInstanceForUpdate("businesskeytest");
processInstance.setKey("businesskey2");
@@ -26,41 +28,16 @@
assertEquals("businesskey1", processInstance.getKey());
}
-/*
-
- problematic unique key constraint. see also http://jira.jboss.com/jira/browse/JBPM-913
-
- public void testDuplicateBusinessKey() {
- ProcessDefinition processDefinition = new ProcessDefinition("businesskeytest");
- jbpmContext.deployProcessDefinition(processDefinition);
-
- newTransaction();
-
- jbpmContext.newProcessInstanceForUpdate("businesskeytest").setKey("duplicatekey");
- jbpmContext.newProcessInstanceForUpdate("businesskeytest").setKey("duplicatekey");
-
- try {
- jbpmContext.close();
- fail("expected exception");
- } catch (JbpmException e) {
- e.printStackTrace();
- } catch (Throwable t) {
- t.printStackTrace();
- }
-
- beginSessionTransaction();
- jbpmContext.getSession();
- }
-*/
- public void testDuplicateBusinessKeyInDifferentProcesses() {
+ public void testDuplicateBusinessKeyInDifferentProcesses()
+ {
ProcessDefinition processDefinition = new ProcessDefinition("businesskeytest1");
jbpmContext.deployProcessDefinition(processDefinition);
-
+
processDefinition = new ProcessDefinition("businesskeytest2");
jbpmContext.deployProcessDefinition(processDefinition);
-
+
newTransaction();
-
+
jbpmContext.newProcessInstanceForUpdate("businesskeytest1").setKey("duplicatekey");
jbpmContext.newProcessInstanceForUpdate("businesskeytest2").setKey("duplicatekey");
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/ExceptionHandlingTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/ExceptionHandlingTest.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/exe/ExceptionHandlingTest.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -30,230 +30,198 @@
import org.jbpm.graph.def.DelegationException;
import org.jbpm.graph.def.ProcessDefinition;
-public class ExceptionHandlingTest extends TestCase {
-
+public class ExceptionHandlingTest extends TestCase
+{
+
static List executedActions = null;
-
- public void setUp() {
+
+ public void setUp()
+ {
executedActions = new ArrayList();
}
-
- public static class BatterException extends Exception {
+
+ public static class BatterException extends Exception
+ {
private static final long serialVersionUID = 1L;
}
- public static class Batter implements ActionHandler {
+ public static class Batter implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext executionContext) throws Exception {
+
+ public void execute(ExecutionContext executionContext) throws Exception
+ {
throw new BatterException();
}
}
-
- public static class Pitcher implements ActionHandler {
+
+ public static class Pitcher implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
Throwable exception = null;
- public void execute(ExecutionContext executionContext) throws DelegationException {
+
+ public void execute(ExecutionContext executionContext) throws DelegationException
+ {
this.exception = executionContext.getException();
executedActions.add(this);
}
}
- public void testUncaughtException() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='play ball' />" +
- " </start-state>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" +
- " </event>" +
- " </state>" +
- "</process-definition>");
-
- try {
+ public void testUncaughtException()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='play ball' />"
+ + " </start-state>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" + " </event>" + " </state>" + "</process-definition>");
+
+ try
+ {
new ProcessInstance(processDefinition).signal();
fail("expected exception");
- } catch (DelegationException e) {
- // OK
- e.printStackTrace();
+ }
+ catch (DelegationException e)
+ {
assertSame(BatterException.class, e.getCause().getClass());
}
}
- public static class RuntimeBatter implements ActionHandler {
+ public static class RuntimeBatter implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext executionContext) throws Exception {
+
+ public void execute(ExecutionContext executionContext) throws Exception
+ {
throw new RuntimeException("here i come");
}
}
-
- public void testUncaughtRuntimeException() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='play ball' />" +
- " </start-state>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$RuntimeBatter' />" +
- " </event>" +
- " </state>" +
- "</process-definition>");
-
- try {
+
+ public void testUncaughtRuntimeException()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='play ball' />"
+ + " </start-state>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$RuntimeBatter' />" + " </event>" + " </state>" + "</process-definition>");
+
+ try
+ {
new ProcessInstance(processDefinition).signal();
fail("expected exception");
- } catch (DelegationException e) {
- // OK
- e.printStackTrace();
+ }
+ catch (DelegationException e)
+ {
assertSame(RuntimeException.class, e.getCause().getClass());
}
}
- public static class ErrorBatter implements ActionHandler {
+ public static class ErrorBatter implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext executionContext) throws Exception {
+
+ public void execute(ExecutionContext executionContext) throws Exception
+ {
throw new Error("jvm trouble coming your way");
}
}
-
- public void testUncaughtError() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='play ball' />" +
- " </start-state>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$ErrorBatter' />" +
- " </event>" +
- " </state>" +
- "</process-definition>");
-
- try {
+
+ public void testUncaughtError()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='play ball' />"
+ + " </start-state>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$ErrorBatter' />" + " </event>" + " </state>" + "</process-definition>");
+
+ try
+ {
new ProcessInstance(processDefinition).signal();
fail("expected exception");
- } catch (DelegationException e) {
+ }
+ catch (DelegationException e)
+ {
fail("i don't want a delegation exception. jBPM should not handle Error's since that might lead to JVM halts");
- } catch (Error e) {
+ }
+ catch (Error e)
+ {
// OK
}
}
- public void testSimpleCatchAll() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='play ball' />" +
- " </start-state>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" +
- " </event>" +
- " <exception-handler>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" +
- " </exception-handler>" +
- " </state>" +
- "</process-definition>");
+ public void testSimpleCatchAll()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='play ball' />"
+ + " </start-state>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" + " </event>" + " <exception-handler>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" + " </exception-handler>" + " </state>" + "</process-definition>");
new ProcessInstance(processDefinition).signal();
assertEquals(1, executedActions.size());
- Pitcher executedPitcher = (Pitcher) executedActions.get(0);
+ Pitcher executedPitcher = (Pitcher)executedActions.get(0);
assertSame(BatterException.class, executedPitcher.exception.getClass());
}
- public void testCatchOnlyTheSpecifiedException() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='play ball' />" +
- " </start-state>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" +
- " </event>" +
- " <exception-handler exception-class='org.jbpm.graph.exe.ExceptionHandlingTest$BatterException'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" +
- " </exception-handler>" +
- " </state>" +
- "</process-definition>");
+ public void testCatchOnlyTheSpecifiedException()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='play ball' />"
+ + " </start-state>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" + " </event>"
+ + " <exception-handler exception-class='org.jbpm.graph.exe.ExceptionHandlingTest$BatterException'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" + " </exception-handler>" + " </state>" + "</process-definition>");
new ProcessInstance(processDefinition).signal();
}
- public void testDontCatchTheNonSpecifiedException() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='play ball' />" +
- " </start-state>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" +
- " </event>" +
- " <exception-handler exception-class='java.lang.RuntimeException'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" +
- " </exception-handler>" +
- " </state>" +
- "</process-definition>");
+ public void testDontCatchTheNonSpecifiedException()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='play ball' />"
+ + " </start-state>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" + " </event>"
+ + " <exception-handler exception-class='java.lang.RuntimeException'>" + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>"
+ + " </exception-handler>" + " </state>" + "</process-definition>");
- try {
+ try
+ {
new ProcessInstance(processDefinition).signal();
- } catch (DelegationException e) {
+ }
+ catch (DelegationException e)
+ {
assertSame(BatterException.class, e.getCause().getClass());
}
}
- public static class SecondExceptionHandler implements ActionHandler {
+ public static class SecondExceptionHandler implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext executionContext) throws DelegationException {
+
+ public void execute(ExecutionContext executionContext) throws DelegationException
+ {
executedActions.add(this);
}
}
- public void testCatchWithTheSecondSpecifiedExceptionHandler() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='play ball' />" +
- " </start-state>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" +
- " </event>" +
- // the first exception-handler will not catch the BatterException
- " <exception-handler exception-class='java.lang.RuntimeException'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" +
- " </exception-handler>" +
- // but the second exception-handler will catch all
- " <exception-handler>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$SecondExceptionHandler'/>" +
- " </exception-handler>" +
- " </state>" +
- "</process-definition>");
+ public void testCatchWithTheSecondSpecifiedExceptionHandler()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='play ball' />"
+ + " </start-state>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />"
+ + " </event>"
+ +
+ // the first exception-handler will not catch the BatterException
+ " <exception-handler exception-class='java.lang.RuntimeException'>" + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>"
+ + " </exception-handler>"
+ +
+ // but the second exception-handler will catch all
+ " <exception-handler>" + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$SecondExceptionHandler'/>" + " </exception-handler>"
+ + " </state>" + "</process-definition>");
new ProcessInstance(processDefinition).signal();
assertEquals(1, executedActions.size());
assertSame(SecondExceptionHandler.class, executedActions.get(0).getClass());
}
- public void testTwoActionsInOneExceptionHandler() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='play ball' />" +
- " </start-state>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" +
- " </event>" +
- " <exception-handler>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$SecondExceptionHandler'/>" +
- " </exception-handler>" +
- " </state>" +
- "</process-definition>");
+ public void testTwoActionsInOneExceptionHandler()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='play ball' />"
+ + " </start-state>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" + " </event>" + " <exception-handler>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$SecondExceptionHandler'/>" + " </exception-handler>" + " </state>"
+ + "</process-definition>");
new ProcessInstance(processDefinition).signal();
assertEquals(2, executedActions.size());
@@ -261,43 +229,23 @@
assertSame(SecondExceptionHandler.class, executedActions.get(1).getClass());
}
- public void testProcessDefinitionExceptionHandling() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='play ball' />" +
- " </start-state>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" +
- " </event>" +
- " </state>" +
- " <exception-handler>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" +
- " </exception-handler>" +
- "</process-definition>");
+ public void testProcessDefinitionExceptionHandling()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='play ball' />"
+ + " </start-state>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" + " </event>" + " </state>" + " <exception-handler>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" + " </exception-handler>" + "</process-definition>");
new ProcessInstance(processDefinition).signal();
assertEquals(1, executedActions.size());
}
- public void testSuperStateExceptionHandling() {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='superstate/play ball' />" +
- " </start-state>" +
- " <super-state name='superstate'>" +
- " <state name='play ball'>" +
- " <event type='node-enter'>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" +
- " </event>" +
- " </state>" +
- " <exception-handler>" +
- " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" +
- " </exception-handler>" +
- " </super-state>" +
- "</process-definition>");
+ public void testSuperStateExceptionHandling()
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='superstate/play ball' />"
+ + " </start-state>" + " <super-state name='superstate'>" + " <state name='play ball'>" + " <event type='node-enter'>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Batter' />" + " </event>" + " </state>" + " <exception-handler>"
+ + " <action class='org.jbpm.graph.exe.ExceptionHandlingTest$Pitcher'/>" + " </exception-handler>" + " </super-state>" + "</process-definition>");
new ProcessInstance(processDefinition).signal();
assertEquals(1, executedActions.size());
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/JobExecutorDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/JobExecutorDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/JobExecutorDbTest.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -19,42 +19,50 @@
import org.jbpm.graph.exe.ExecutionContext;
import org.jbpm.graph.exe.ProcessInstance;
-public class JobExecutorDbTest extends TestCase {
+public class JobExecutorDbTest extends TestCase
+{
static int nbrOfConcurrentProcessExecutions = 20;
static int maxWaitTime = 60000;
static Set collectedResults = Collections.synchronizedSet(new TreeSet());
-
- protected static JbpmConfiguration jbpmConfiguration =
- JbpmConfiguration.getInstance("org/jbpm/jbpm.test.cfg.xml");
-
- static {
+
+ protected static JbpmConfiguration jbpmConfiguration = JbpmConfiguration.getInstance("org/jbpm/jbpm.test.cfg.xml");
+
+ static
+ {
jbpmConfiguration.getJobExecutor().nbrOfThreads = 5;
}
protected JobExecutor jobExecutor;
- public static class AutomaticActivity implements ActionHandler {
+ public static class AutomaticActivity implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext executionContext) throws Exception {
+
+ public void execute(ExecutionContext executionContext) throws Exception
+ {
long id = executionContext.getProcessInstance().getId();
String nodeName = executionContext.getNode().getName();
- collectedResults.add(id+nodeName);
+ collectedResults.add(id + nodeName);
executionContext.leaveNode();
}
}
- public static class AsyncAction implements ActionHandler {
+ public static class AsyncAction implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext executionContext) throws Exception {
+
+ public void execute(ExecutionContext executionContext) throws Exception
+ {
long id = executionContext.getProcessInstance().getId();
Action action = executionContext.getAction();
String actionName = action.getName();
- collectedResults.add(id+actionName);
+ collectedResults.add(id + actionName);
}
}
- public void testJobExecutor() {
+ public void testJobExecutor()
+ {
jbpmConfiguration.createSchema();
deployProcess();
launchProcesses();
@@ -63,161 +71,209 @@
jbpmConfiguration.createSchema();
}
- public void deployProcess() {
+ public void deployProcess()
+ {
JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
+ try
+ {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition name='bulk messages'>" +
- " <start-state>" +
- " <transition to='a' />" +
- " </start-state>" +
- " <node name='a' async='true'>" +
- " <action class='"+AutomaticActivity.class.getName()+"' />" +
- " <transition to='b' />" +
- " </node>" +
- " <node name='b' async='true'>" +
- " <event type='node-enter'>" +
- " <action name='X' async='true' class='"+AsyncAction.class.getName()+"' />" +
- " </event>" +
- " <action class='"+AutomaticActivity.class.getName()+"' />" +
- " <transition to='c' />" +
- " </node>" +
- " <node name='c' async='true'>" +
- " <action class='"+AutomaticActivity.class.getName()+"' />" +
- " <transition to='d'>" +
- " <action name='Y' async='true' class='"+AsyncAction.class.getName()+"' />" +
- " </transition>" +
- " </node>" +
- " <node name='d' async='true'>" +
- " <action class='"+AutomaticActivity.class.getName()+"' />" +
- " <transition to='e' />" +
- " <event type='node-leave'>" +
- " <action name='Z' async='true' class='"+AsyncAction.class.getName()+"' />" +
- " </event>" +
- " </node>" +
- " <node name='e' async='true'>" +
- " <action class='"+AutomaticActivity.class.getName()+"' />" +
- " <transition to='end' />" +
- " </node>" +
- " <end-state name='end'/>" +
- "</process-definition>"
- );
-
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition name='bulk messages'>" + " <start-state>"
+ + " <transition to='a' />" + " </start-state>" + " <node name='a' async='true'>" + " <action class='"
+ + AutomaticActivity.class.getName()
+ + "' />"
+ + " <transition to='b' />"
+ + " </node>"
+ + " <node name='b' async='true'>"
+ + " <event type='node-enter'>"
+ + " <action name='X' async='true' class='"
+ + AsyncAction.class.getName()
+ + "' />"
+ + " </event>"
+ + " <action class='"
+ + AutomaticActivity.class.getName()
+ + "' />"
+ + " <transition to='c' />"
+ + " </node>"
+ + " <node name='c' async='true'>"
+ + " <action class='"
+ + AutomaticActivity.class.getName()
+ + "' />"
+ + " <transition to='d'>"
+ + " <action name='Y' async='true' class='"
+ + AsyncAction.class.getName()
+ + "' />"
+ + " </transition>"
+ + " </node>"
+ + " <node name='d' async='true'>"
+ + " <action class='"
+ + AutomaticActivity.class.getName()
+ + "' />"
+ + " <transition to='e' />"
+ + " <event type='node-leave'>"
+ + " <action name='Z' async='true' class='"
+ + AsyncAction.class.getName()
+ + "' />"
+ + " </event>"
+ + " </node>"
+ + " <node name='e' async='true'>"
+ + " <action class='"
+ + AutomaticActivity.class.getName()
+ + "' />"
+ + " <transition to='end' />" + " </node>" + " <end-state name='end'/>" + "</process-definition>");
+
jbpmContext.deployProcessDefinition(processDefinition);
- } finally {
+ }
+ finally
+ {
jbpmContext.close();
}
}
- public void launchProcesses() {
- for (int i=0; i<nbrOfConcurrentProcessExecutions; i++) {
+ public void launchProcesses()
+ {
+ for (int i = 0; i < nbrOfConcurrentProcessExecutions; i++)
+ {
JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
+ try
+ {
ProcessInstance processInstance = jbpmContext.newProcessInstanceForUpdate("bulk messages");
processInstance.signal();
- } finally {
+ }
+ finally
+ {
jbpmContext.close();
}
}
}
- public Set createExpectedResults() {
+ public Set createExpectedResults()
+ {
Set expectedResults = new TreeSet();
- for (int i=1; i<nbrOfConcurrentProcessExecutions+1; i++) {
- expectedResults.add(i+"a");
- expectedResults.add(i+"b");
- expectedResults.add(i+"c");
- expectedResults.add(i+"d");
- expectedResults.add(i+"e");
- expectedResults.add(i+"X");
- expectedResults.add(i+"Y");
- expectedResults.add(i+"Z");
+ for (int i = 1; i < nbrOfConcurrentProcessExecutions + 1; i++)
+ {
+ expectedResults.add(i + "a");
+ expectedResults.add(i + "b");
+ expectedResults.add(i + "c");
+ expectedResults.add(i + "d");
+ expectedResults.add(i + "e");
+ expectedResults.add(i + "X");
+ expectedResults.add(i + "Y");
+ expectedResults.add(i + "Z");
}
return expectedResults;
}
- protected void startJobExecutor() {
+ protected void startJobExecutor()
+ {
jobExecutor = jbpmConfiguration.getJobExecutor();
jobExecutor.start();
}
-
- private void processAllJobs(final long maxWait) {
+
+ private void processAllJobs(final long maxWait)
+ {
boolean jobsAvailable = true;
// install a timer that will interrupt if it takes too long
// if that happens, it will lead to an interrupted exception and the test will fail
- TimerTask interruptTask = new TimerTask() {
+ TimerTask interruptTask = new TimerTask()
+ {
Thread testThread = Thread.currentThread();
- public void run() {
- log.debug("test "+getName()+" took too long. going to interrupt...");
+
+ public void run()
+ {
+ log.debug("test " + getName() + " took too long. going to interrupt...");
testThread.interrupt();
}
};
Timer timer = new Timer();
timer.schedule(interruptTask, maxWait);
-
- try {
- while (jobsAvailable) {
+
+ try
+ {
+ while (jobsAvailable)
+ {
log.debug("going to sleep for 200 millis, waiting for the job executor to process more jobs");
Thread.sleep(200);
jobsAvailable = areJobsAvailable();
}
jobExecutor.stopAndJoin();
-
- } catch (InterruptedException e) {
- fail("test execution exceeded treshold of "+maxWait+" milliseconds");
- } finally {
+
+ }
+ catch (InterruptedException e)
+ {
+ fail("test execution exceeded treshold of " + maxWait + " milliseconds");
+ }
+ finally
+ {
timer.cancel();
}
}
- private int getNbrOfJobsAvailable() {
+ private int getNbrOfJobsAvailable()
+ {
int nbrOfJobsAvailable = 0;
JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
+ try
+ {
Session session = jbpmContext.getSession();
- Number jobs = (Number) session.createQuery("select count(*) from org.jbpm.job.Job").uniqueResult();
- log.debug("there are '"+jobs+"' jobs currently in the job table");
- if (jobs!=null) {
+ Number jobs = (Number)session.createQuery("select count(*) from org.jbpm.job.Job").uniqueResult();
+ log.debug("there are '" + jobs + "' jobs currently in the job table");
+ if (jobs != null)
+ {
nbrOfJobsAvailable = jobs.intValue();
}
- } finally {
+ }
+ finally
+ {
jbpmContext.close();
}
return nbrOfJobsAvailable;
}
- protected boolean areJobsAvailable() {
- return (getNbrOfJobsAvailable()>0);
+ protected boolean areJobsAvailable()
+ {
+ return (getNbrOfJobsAvailable() > 0);
}
-
- protected void processJobs(long maxWait) {
- try {
+
+ protected void processJobs(long maxWait)
+ {
+ try
+ {
Thread.sleep(300);
- } catch (InterruptedException e) {
- e.printStackTrace();
}
+ catch (InterruptedException e)
+ {
+ // ignore
+ }
startJobExecutor();
- try {
+ try
+ {
processAllJobs(maxWait);
- } catch (Exception e) {
- e.printStackTrace();
+ }
+ catch (Exception e)
+ {
throw new RuntimeException(e);
- } finally {
+ }
+ finally
+ {
stopJobExecutor();
}
}
-
- protected void stopJobExecutor() {
- if (jobExecutor!=null) {
- try {
+
+ protected void stopJobExecutor()
+ {
+ if (jobExecutor != null)
+ {
+ try
+ {
jobExecutor.stopAndJoin();
- } catch (InterruptedException e) {
- throw new RuntimeException("waiting for job executor to stop and join got interrupted", e);
}
+ catch (InterruptedException e)
+ {
+ throw new RuntimeException("waiting for job executor to stop and join got interrupted", e);
+ }
}
}
-
+
private static Log log = LogFactory.getLog(JobExecutorDbTest.class);
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/el/DecisionExpressionTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/el/DecisionExpressionTest.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/el/DecisionExpressionTest.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -6,44 +6,45 @@
import org.jbpm.graph.def.ProcessDefinition;
import org.jbpm.graph.exe.ProcessInstance;
-public class DecisionExpressionTest extends TestCase {
-
- public static class Customer {
+public class DecisionExpressionTest extends TestCase
+{
+
+ public static class Customer
+ {
String priority;
int number;
- public Customer(String priority) {
+
+ public Customer(String priority)
+ {
this.priority = priority;
}
- public Customer(int number) {
+
+ public Customer(int number)
+ {
this.number = number;
}
- public String getPriority() {
+
+ public String getPriority()
+ {
return priority;
}
- public int getNumber() {
+
+ public int getNumber()
+ {
return number;
}
}
-
- public ProcessDefinition createCustomerPriorityProcess() {
- return ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='d'/>" +
- " </start-state>" +
- " <decision name='d' expression='#{customer.priority}'>" +
- " <transition name='LOW' to='l' />" +
- " <transition name='MEDIUM' to='m' />" +
- " <transition name='HIGH' to='h' />" +
- " </decision>" +
- " <state name='l' />" +
- " <state name='m' />" +
- " <state name='h' />" +
- "</process-definition>"
- );
+
+ public ProcessDefinition createCustomerPriorityProcess()
+ {
+ return ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='d'/>" + " </start-state>"
+ + " <decision name='d' expression='#{customer.priority}'>" + " <transition name='LOW' to='l' />" + " <transition name='MEDIUM' to='m' />"
+ + " <transition name='HIGH' to='h' />" + " </decision>" + " <state name='l' />" + " <state name='m' />" + " <state name='h' />"
+ + "</process-definition>");
}
- public void testCustomerPriorityLow() {
+ public void testCustomerPriorityLow()
+ {
ProcessDefinition processDefinition = createCustomerPriorityProcess();
ProcessInstance processInstance = new ProcessInstance(processDefinition);
processInstance.getContextInstance().setVariable("customer", new Customer("LOW"));
@@ -51,7 +52,8 @@
assertEquals("l", processInstance.getRootToken().getNode().getName());
}
- public void testCustomerPriorityMedium() {
+ public void testCustomerPriorityMedium()
+ {
ProcessDefinition processDefinition = createCustomerPriorityProcess();
ProcessInstance processInstance = new ProcessInstance(processDefinition);
processInstance.getContextInstance().setVariable("customer", new Customer("MEDIUM"));
@@ -59,50 +61,48 @@
assertEquals("m", processInstance.getRootToken().getNode().getName());
}
- public void testCustomerPriorityUndefined() {
+ public void testCustomerPriorityUndefined()
+ {
ProcessDefinition processDefinition = createCustomerPriorityProcess();
ProcessInstance processInstance = new ProcessInstance(processDefinition);
processInstance.getContextInstance().setVariable("customer", new Customer("UNDEFINED"));
- try {
+ try
+ {
processInstance.signal();
fail("expected exception");
- } catch (JbpmException e) {
- e.printStackTrace();
- assertTrue(e.getMessage().indexOf("non existing transition")!=-1);
- // OK
}
+ catch (JbpmException e)
+ {
+ assertTrue(e.getMessage().indexOf("non existing transition") != -1);
+ }
}
- public void testCustomerPriorityNull() {
+ public void testCustomerPriorityNull()
+ {
ProcessDefinition processDefinition = createCustomerPriorityProcess();
ProcessInstance processInstance = new ProcessInstance(processDefinition);
processInstance.getContextInstance().setVariable("customer", new Customer(null));
- try {
+ try
+ {
processInstance.signal();
fail("expected exception");
- } catch (JbpmException e) {
+ }
+ catch (JbpmException e)
+ {
// OK
}
}
-
- public ProcessDefinition createBooleanExpressionProcess() {
- return ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='d'/>" +
- " </start-state>" +
- " <decision name='d' expression='#{customer.number > 5}'>" +
- " <transition name='true' to='high-numbered-customer' />" +
- " <transition name='false' to='low-numbered-customer' />" +
- " </decision>" +
- " <state name='high-numbered-customer' />" +
- " <state name='low-numbered-customer' />" +
- "</process-definition>"
- );
+ public ProcessDefinition createBooleanExpressionProcess()
+ {
+ return ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='d'/>" + " </start-state>"
+ + " <decision name='d' expression='#{customer.number > 5}'>" + " <transition name='true' to='high-numbered-customer' />"
+ + " <transition name='false' to='low-numbered-customer' />" + " </decision>" + " <state name='high-numbered-customer' />"
+ + " <state name='low-numbered-customer' />" + "</process-definition>");
}
- public void testBooleanExpressionTrue() {
+ public void testBooleanExpressionTrue()
+ {
ProcessDefinition processDefinition = createBooleanExpressionProcess();
ProcessInstance processInstance = new ProcessInstance(processDefinition);
processInstance.getContextInstance().setVariable("customer", new Customer(9));
@@ -110,7 +110,8 @@
assertEquals("high-numbered-customer", processInstance.getRootToken().getNode().getName());
}
- public void testBooleanExpressionFalse() {
+ public void testBooleanExpressionFalse()
+ {
ProcessDefinition processDefinition = createBooleanExpressionProcess();
ProcessInstance processInstance = new ProcessInstance(processDefinition);
processInstance.getContextInstance().setVariable("customer", new Customer(3));
@@ -118,29 +119,17 @@
assertEquals("low-numbered-customer", processInstance.getRootToken().getNode().getName());
}
- public ProcessDefinition createConditionProcess() {
- return ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='d'/>" +
- " </start-state>" +
- " <decision name='d'>" +
- " <transition to='low-numbered-customer' />" +
- " <transition to='high-numbered-customer'>" +
- " <condition expression='#{customer.number > 5}' />" +
- " </transition>" +
- " <transition to='medium-numbered-customer'>" +
- " <condition expression='#{customer.number == 5}' />" +
- " </transition>" +
- " </decision>" +
- " <state name='high-numbered-customer' />" +
- " <state name='medium-numbered-customer' />" +
- " <state name='low-numbered-customer' />" +
- "</process-definition>"
- );
+ public ProcessDefinition createConditionProcess()
+ {
+ return ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='d'/>" + " </start-state>" + " <decision name='d'>"
+ + " <transition to='low-numbered-customer' />" + " <transition to='high-numbered-customer'>" + " <condition expression='#{customer.number > 5}' />"
+ + " </transition>" + " <transition to='medium-numbered-customer'>" + " <condition expression='#{customer.number == 5}' />" + " </transition>"
+ + " </decision>" + " <state name='high-numbered-customer' />" + " <state name='medium-numbered-customer' />" + " <state name='low-numbered-customer' />"
+ + "</process-definition>");
}
- public void testConditionHigh() {
+ public void testConditionHigh()
+ {
ProcessDefinition processDefinition = createConditionProcess();
ProcessInstance processInstance = new ProcessInstance(processDefinition);
processInstance.getContextInstance().setVariable("customer", new Customer(9));
@@ -148,7 +137,8 @@
assertEquals("high-numbered-customer", processInstance.getRootToken().getNode().getName());
}
- public void testConditionMedium() {
+ public void testConditionMedium()
+ {
ProcessDefinition processDefinition = createConditionProcess();
ProcessInstance processInstance = new ProcessInstance(processDefinition);
processInstance.getContextInstance().setVariable("customer", new Customer(5));
@@ -156,7 +146,8 @@
assertEquals("medium-numbered-customer", processInstance.getRootToken().getNode().getName());
}
- public void testConditionLow() {
+ public void testConditionLow()
+ {
ProcessDefinition processDefinition = createConditionProcess();
ProcessInstance processInstance = new ProcessInstance(processDefinition);
processInstance.getContextInstance().setVariable("customer", new Customer(3));
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/par/ResourceAction.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/par/ResourceAction.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/par/ResourceAction.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -8,61 +8,89 @@
import org.jbpm.graph.def.ActionHandler;
import org.jbpm.graph.exe.ExecutionContext;
-public class ResourceAction implements ActionHandler {
+public class ResourceAction implements ActionHandler
+{
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext executionContext) throws Exception {
- try {
- // class resources
-
- URL resource = getClass().getResource("classresource.txt");
- InputStream stream = resource.openStream();
- ProcessArchiveDeploymentDbTest.classResourceUrl = read(stream);
+ public void execute(ExecutionContext executionContext) throws Exception
+ {
+ // class resources
- stream = getClass().getResourceAsStream("classresource.txt");
- ProcessArchiveDeploymentDbTest.classResourceStream = read(stream);
+ URL resource = getClass().getResource("classresource.txt");
+ InputStream stream = resource.openStream();
+ ProcessArchiveDeploymentDbTest.classResourceUrl = read(stream);
- resource = ResourceAction.class.getClassLoader().getResource("org/jbpm/jpdl/par/classresource.txt");
- stream = resource.openStream();
- ProcessArchiveDeploymentDbTest.classLoaderResourceUrl = read(stream);
+ stream = getClass().getResourceAsStream("classresource.txt");
+ ProcessArchiveDeploymentDbTest.classResourceStream = read(stream);
- stream = ResourceAction.class.getClassLoader().getResourceAsStream("org/jbpm/jpdl/par/classresource.txt");
- ProcessArchiveDeploymentDbTest.classLoaderResourceStream = read(stream);
-
- // archive resources
+ resource = ResourceAction.class.getClassLoader().getResource("org/jbpm/jpdl/par/classresource.txt");
+ stream = resource.openStream();
+ ProcessArchiveDeploymentDbTest.classLoaderResourceUrl = read(stream);
- resource = getClass().getResource("//archiveresource.txt");
- stream = resource.openStream();
- ProcessArchiveDeploymentDbTest.archiveResourceUrl = read(stream);
+ stream = ResourceAction.class.getClassLoader().getResourceAsStream("org/jbpm/jpdl/par/classresource.txt");
+ ProcessArchiveDeploymentDbTest.classLoaderResourceStream = read(stream);
- stream = getClass().getResourceAsStream("//archiveresource.txt");
- ProcessArchiveDeploymentDbTest.archiveResourceStream = read(stream);
+ // archive resources
- resource = ResourceAction.class.getClassLoader().getResource("//archiveresource.txt");
- stream = resource.openStream();
- ProcessArchiveDeploymentDbTest.archiveClassLoaderResourceUrl = read(stream);
+ resource = getClass().getResource("//archiveresource.txt");
+ stream = resource.openStream();
+ ProcessArchiveDeploymentDbTest.archiveResourceUrl = read(stream);
- stream = ResourceAction.class.getClassLoader().getResourceAsStream("//archiveresource.txt");
- ProcessArchiveDeploymentDbTest.archiveClassLoaderResourceStream = read(stream);
-
- // unexisting resources
-
+ stream = getClass().getResourceAsStream("//archiveresource.txt");
+ ProcessArchiveDeploymentDbTest.archiveResourceStream = read(stream);
+
+ resource = ResourceAction.class.getClassLoader().getResource("//archiveresource.txt");
+ stream = resource.openStream();
+ ProcessArchiveDeploymentDbTest.archiveClassLoaderResourceUrl = read(stream);
+
+ stream = ResourceAction.class.getClassLoader().getResourceAsStream("//archiveresource.txt");
+ ProcessArchiveDeploymentDbTest.archiveClassLoaderResourceStream = read(stream);
+
+ // unexisting resources
+ try
+ {
ProcessArchiveDeploymentDbTest.unexistingClassResourceStream = getClass().getResourceAsStream("unexistingresource.txt");
+ }
+ catch (RuntimeException e)
+ {
+ // ignore
+ }
+
+ try
+ {
ProcessArchiveDeploymentDbTest.unexistingClassLoaderResourceStream = ResourceAction.class.getClassLoader().getResourceAsStream("org/jbpm/jpdl/par/unexistingresource.txt");
+ }
+ catch (RuntimeException e)
+ {
+ // ignore
+ }
+
+ try
+ {
ProcessArchiveDeploymentDbTest.unexistingArchiveResourceStream = getClass().getResourceAsStream("//unexistingarchiveresource.txt");
+ }
+ catch (RuntimeException e)
+ {
+ // ignore
+ }
+ try
+ {
ProcessArchiveDeploymentDbTest.unexistingArchiveLoaderResourceStream = ResourceAction.class.getClassLoader().getResourceAsStream("//unexistingarchiveresource.txt");
-
- } catch (RuntimeException e) {
- e.printStackTrace();
}
+ catch (RuntimeException e)
+ {
+ // ignore
+ }
}
- private String read(InputStream resourceAsStream) throws Exception {
+ private String read(InputStream resourceAsStream) throws Exception
+ {
BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(resourceAsStream));
StringBuffer buffer = new StringBuffer();
String l;
- while ((l = bufferedReader.readLine()) != null) {
+ while ((l = bufferedReader.readLine()) != null)
+ {
buffer.append(l);
}
return buffer.toString();
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/SchemaTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/SchemaTest.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/SchemaTest.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -22,271 +22,188 @@
import org.xml.sax.SAXException;
import org.xml.sax.SAXParseException;
-public class SchemaTest extends TestCase {
-
+public class SchemaTest extends TestCase
+{
+
private static Log log = LogFactory.getLog(SchemaTest.class);
-
- public static class TestEntityResolver implements EntityResolver {
+
+ public static class TestEntityResolver implements EntityResolver
+ {
Map schemas;
- public TestEntityResolver(Map schemas) {
+
+ public TestEntityResolver(Map schemas)
+ {
this.schemas = schemas;
}
- public InputSource resolveEntity(String publicId, String systemId) {
- String schemaXmlString = (String) schemas.get(systemId);
- if (schemaXmlString==null) {
+
+ public InputSource resolveEntity(String publicId, String systemId)
+ {
+ String schemaXmlString = (String)schemas.get(systemId);
+ if (schemaXmlString == null)
+ {
return null;
}
return new InputSource(new StringReader(schemaXmlString));
}
}
- public static class TestErrorHandler implements ErrorHandler {
+ public static class TestErrorHandler implements ErrorHandler
+ {
List errors = new ArrayList();
- public void error(SAXParseException exception) throws SAXException {
- errors.add("["+exception.getLineNumber()+"] "+exception.getMessage());
+
+ public void error(SAXParseException exception) throws SAXException
+ {
+ errors.add("[" + exception.getLineNumber() + "] " + exception.getMessage());
}
- public void fatalError(SAXParseException exception) throws SAXException {
+
+ public void fatalError(SAXParseException exception) throws SAXException
+ {
error(exception);
}
- public void warning(SAXParseException exception) throws SAXException {
+
+ public void warning(SAXParseException exception) throws SAXException
+ {
error(exception);
}
}
-
+
DocumentBuilderFactory dbf;
DocumentBuilder db;
Map schemas;
TestEntityResolver testEntityResolver;
-
- protected void setUp() throws Exception {
+
+ protected void setUp() throws Exception
+ {
dbf = DocumentBuilderFactory.newInstance();
dbf.setValidating(true);
dbf.setNamespaceAware(true);
- dbf.setAttribute("http://java.sun.com/xml/jaxp/properties/schemaLanguage",
- "http://www.w3.org/2001/XMLSchema");
+ dbf.setAttribute("http://java.sun.com/xml/jaxp/properties/schemaLanguage", "http://www.w3.org/2001/XMLSchema");
schemas = new HashMap();
testEntityResolver = new TestEntityResolver(schemas);
}
- public void addSchema(String schemaXmlString) {
- String systemId = "urn:schema"+schemas.size();
+ public void addSchema(String schemaXmlString)
+ {
+ String systemId = "urn:schema" + schemas.size();
schemas.put(systemId, schemaXmlString);
-
+
String[] schemaSources = new String[schemas.size()];
- for (int i=0; i<schemas.size(); i++) {
- schemaSources[i] = "urn:schema"+i;
+ for (int i = 0; i < schemas.size(); i++)
+ {
+ schemaSources[i] = "urn:schema" + i;
}
-
- dbf.setAttribute("http://java.sun.com/xml/jaxp/properties/schemaSource",
- schemaSources);
+
+ dbf.setAttribute("http://java.sun.com/xml/jaxp/properties/schemaSource", schemaSources);
}
-
- public Document assertValidXml(String documentXmlString) {
- try {
+
+ public Document assertValidXml(String documentXmlString)
+ {
+ try
+ {
db = dbf.newDocumentBuilder();
db.setEntityResolver(testEntityResolver);
TestErrorHandler errorHandler = new TestErrorHandler();
db.setErrorHandler(errorHandler);
Document document = db.parse(new InputSource(new StringReader(documentXmlString)));
- if (! errorHandler.errors.isEmpty()) {
+ if (!errorHandler.errors.isEmpty())
+ {
StringBuffer buffer = new StringBuffer();
buffer.append("parsing problems: \n");
Iterator iter = errorHandler.errors.iterator();
- while (iter.hasNext()) {
+ while (iter.hasNext())
+ {
buffer.append("ERR: ");
buffer.append(iter.next());
}
throw new XmlException(buffer.toString());
}
-
+
return document;
- } catch (XmlException e) {
+ }
+ catch (XmlException e)
+ {
throw e;
- } catch (Exception e) {
- e.printStackTrace();
+ }
+ catch (Exception e)
+ {
throw new XmlException("couldn't parse", e);
}
}
- protected void tearDown() throws Exception {
+ protected void tearDown() throws Exception
+ {
super.tearDown();
}
- public static void printDocument(Document document) {
+ public static void printDocument(Document document)
+ {
log.debug(XmlUtil.toString(document.getDocumentElement()));
}
-
- public static class XmlException extends RuntimeException {
+
+ public static class XmlException extends RuntimeException
+ {
private static final long serialVersionUID = 1L;
- public XmlException(String message) {
+
+ public XmlException(String message)
+ {
super(message);
}
- public XmlException(String message, Throwable cause) {
+
+ public XmlException(String message, Throwable cause)
+ {
super(message, cause);
}
}
/*
+ *
+ * public void testSchemaChoices() { addSchema( "<xs:schema targetNamespace='urn:jbpm.org:test' \n" + " xmlns='urn:jbpm.org:test' \n" +
+ * " xmlns:xs='http://www.w3.org/2001/XMLSchema'\n" + " elementFormDefault='qualified'>\n" + " <xs:element name='root'>\n" +
+ * " <xs:complexType>\n" + " <xs:choice minOccurs='0' maxOccurs='3'>\n" + " <xs:element name='hello' />\n" + " <xs:element name='world' />\n" +
+ * " </xs:choice>\n" + " </xs:complexType>\n" + " </xs:element>\n" + "</xs:schema>" );
+ *
+ * assertValidXml( "<?xml version='1.0'?>\n" + "<root xmlns='urn:jbpm.org:test'>\n" + " <hello />\n" + "</root>" );
+ *
+ * assertValidXml( "<?xml version='1.0'?>\n" + "<root xmlns='urn:jbpm.org:test'>\n" + " <hello />\n" + " <world />\n" + " <hello />\n" + "</root>" );
+ *
+ * try { assertValidXml( "<?xml version='1.0'?>\n" + "<root xmlns='urn:jbpm.org:test'>\n" + " <hello />\n" + " <world />\n" + " <hello />\n" + " <hello />\n" +
+ * "</root>" ); fail("expected exception"); } catch (XmlException e) { // OK } }
+ *
+ * public void testSchemaSequenceOfChoice() { addSchema( "<xs:schema targetNamespace='urn:jbpm.org:test' \n" + " xmlns='urn:jbpm.org:test' \n" +
+ * " xmlns:xs='http://www.w3.org/2001/XMLSchema'\n" + " elementFormDefault='qualified'>\n" + " <xs:element name='root'>\n" +
+ * " <xs:complexType>\n" + " <xs:sequence maxOccurs='3'>\n" + " <xs:choice>\n" + " <xs:element name='hello' />\n" +
+ * " <xs:element name='world' />\n" + " </xs:choice>\n" + " </xs:sequence>\n" + " </xs:complexType>\n" + " </xs:element>\n" + "</xs:schema>"
+ * );
+ *
+ * assertValidXml( "<?xml version='1.0'?>\n" + "<root xmlns='urn:jbpm.org:test'>\n" + " <hello />\n" + "</root>" );
+ *
+ * assertValidXml( "<?xml version='1.0'?>\n" + "<root xmlns='urn:jbpm.org:test'>\n" + " <hello />\n" + " <world />\n" + " <hello />\n" + "</root>" );
+ *
+ * assertValidXml( "<?xml version='1.0'?>\n" + "<root xmlns='urn:jbpm.org:test'>\n" + " <hello />\n" + " <world />\n" + " <hello />\n" + "</root>" );
+ *
+ * try { assertValidXml( "<?xml version='1.0'?>\n" + "<root xmlns='urn:jbpm.org:test'>\n" + " <hello />\n" + " <world />\n" + " <hello />\n" + " <hello />\n" +
+ * "</root>" ); fail("expected exception"); } catch (XmlException e) { // OK } }
+ */
- public void testSchemaChoices() {
- addSchema(
- "<xs:schema targetNamespace='urn:jbpm.org:test' \n" +
- " xmlns='urn:jbpm.org:test' \n" +
- " xmlns:xs='http://www.w3.org/2001/XMLSchema'\n" +
- " elementFormDefault='qualified'>\n" +
- " <xs:element name='root'>\n" +
- " <xs:complexType>\n" +
- " <xs:choice minOccurs='0' maxOccurs='3'>\n" +
- " <xs:element name='hello' />\n" +
- " <xs:element name='world' />\n" +
- " </xs:choice>\n" +
- " </xs:complexType>\n" +
- " </xs:element>\n" +
- "</xs:schema>"
- );
+ public void testMultiSchemas()
+ {
+ addSchema("<xs:schema targetNamespace='urn:jbpm.org:default' \n" + " xmlns='urn:jbpm.org:default' \n"
+ + " xmlns:xs='http://www.w3.org/2001/XMLSchema'\n" + " elementFormDefault='qualified'>\n" + " <xs:element name='root'>\n"
+ + " <xs:complexType>\n" + " <xs:choice minOccurs='0' maxOccurs='3'>\n" + " <xs:element name='hello' />\n"
+ + " <xs:element name='world' />\n" + " <xs:any processContents='lax' minOccurs='0' maxOccurs='unbounded'/>\n"
+ + " <xs:any namespace='##other' processContents='lax' minOccurs='0' maxOccurs='unbounded'/>\n" + " </xs:choice>\n" + " </xs:complexType>\n"
+ + " </xs:element>\n" + " <xs:element name='tuut' />\n" + "</xs:schema>");
- assertValidXml(
- "<?xml version='1.0'?>\n" +
- "<root xmlns='urn:jbpm.org:test'>\n" +
- " <hello />\n" +
- "</root>"
- );
+ addSchema("<xs:schema targetNamespace='urn:jbpm.org:other' \n" + " xmlns='urn:jbpm.org:other' \n"
+ + " xmlns:xs='http://www.w3.org/2001/XMLSchema'\n" + " elementFormDefault='qualified'>\n" + " <xs:element name='tree'>\n"
+ + " <xs:complexType>\n" + " <xs:choice minOccurs='0' maxOccurs='3'>\n" + " <xs:element name='tree' />\n"
+ + " <xs:element name='leaf' />\n" + " </xs:choice>\n" + " </xs:complexType>\n" + " </xs:element>\n" + " <xs:element name='leaf' />\n"
+ + "</xs:schema>");
- assertValidXml(
- "<?xml version='1.0'?>\n" +
- "<root xmlns='urn:jbpm.org:test'>\n" +
- " <hello />\n" +
- " <world />\n" +
- " <hello />\n" +
- "</root>"
- );
-
- try {
- assertValidXml(
- "<?xml version='1.0'?>\n" +
- "<root xmlns='urn:jbpm.org:test'>\n" +
- " <hello />\n" +
- " <world />\n" +
- " <hello />\n" +
- " <hello />\n" +
- "</root>"
- );
- fail("expected exception");
- } catch (XmlException e) {
- // OK
- }
+ assertValidXml("<?xml version='1.0'?>\n" + "<root xmlns='urn:jbpm.org:default'" + " xmlns:other='urn:jbpm.org:other'>\n" + " <hello />\n" + " <hello />\n"
+ + " <tuut />" + " <other:tree />" + "</root>");
}
- public void testSchemaSequenceOfChoice() {
- addSchema(
- "<xs:schema targetNamespace='urn:jbpm.org:test' \n" +
- " xmlns='urn:jbpm.org:test' \n" +
- " xmlns:xs='http://www.w3.org/2001/XMLSchema'\n" +
- " elementFormDefault='qualified'>\n" +
- " <xs:element name='root'>\n" +
- " <xs:complexType>\n" +
- " <xs:sequence maxOccurs='3'>\n" +
- " <xs:choice>\n" +
- " <xs:element name='hello' />\n" +
- " <xs:element name='world' />\n" +
- " </xs:choice>\n" +
- " </xs:sequence>\n" +
- " </xs:complexType>\n" +
- " </xs:element>\n" +
- "</xs:schema>"
- );
-
- assertValidXml(
- "<?xml version='1.0'?>\n" +
- "<root xmlns='urn:jbpm.org:test'>\n" +
- " <hello />\n" +
- "</root>"
- );
-
- assertValidXml(
- "<?xml version='1.0'?>\n" +
- "<root xmlns='urn:jbpm.org:test'>\n" +
- " <hello />\n" +
- " <world />\n" +
- " <hello />\n" +
- "</root>"
- );
-
- assertValidXml(
- "<?xml version='1.0'?>\n" +
- "<root xmlns='urn:jbpm.org:test'>\n" +
- " <hello />\n" +
- " <world />\n" +
- " <hello />\n" +
- "</root>"
- );
-
- try {
- assertValidXml(
- "<?xml version='1.0'?>\n" +
- "<root xmlns='urn:jbpm.org:test'>\n" +
- " <hello />\n" +
- " <world />\n" +
- " <hello />\n" +
- " <hello />\n" +
- "</root>"
- );
- fail("expected exception");
- } catch (XmlException e) {
- // OK
- }
- }
-*/
-
- public void testMultiSchemas() {
- addSchema(
- "<xs:schema targetNamespace='urn:jbpm.org:default' \n" +
- " xmlns='urn:jbpm.org:default' \n" +
- " xmlns:xs='http://www.w3.org/2001/XMLSchema'\n" +
- " elementFormDefault='qualified'>\n" +
- " <xs:element name='root'>\n" +
- " <xs:complexType>\n" +
- " <xs:choice minOccurs='0' maxOccurs='3'>\n" +
- " <xs:element name='hello' />\n" +
- " <xs:element name='world' />\n" +
- " <xs:any processContents='lax' minOccurs='0' maxOccurs='unbounded'/>\n" +
- " <xs:any namespace='##other' processContents='lax' minOccurs='0' maxOccurs='unbounded'/>\n" +
- " </xs:choice>\n" +
- " </xs:complexType>\n" +
- " </xs:element>\n" +
- " <xs:element name='tuut' />\n" +
- "</xs:schema>"
- );
-
- addSchema(
- "<xs:schema targetNamespace='urn:jbpm.org:other' \n" +
- " xmlns='urn:jbpm.org:other' \n" +
- " xmlns:xs='http://www.w3.org/2001/XMLSchema'\n" +
- " elementFormDefault='qualified'>\n" +
- " <xs:element name='tree'>\n" +
- " <xs:complexType>\n" +
- " <xs:choice minOccurs='0' maxOccurs='3'>\n" +
- " <xs:element name='tree' />\n" +
- " <xs:element name='leaf' />\n" +
- " </xs:choice>\n" +
- " </xs:complexType>\n" +
- " </xs:element>\n" +
- " <xs:element name='leaf' />\n" +
- "</xs:schema>"
- );
-
- assertValidXml(
- "<?xml version='1.0'?>\n" +
- "<root xmlns='urn:jbpm.org:default'" +
- " xmlns:other='urn:jbpm.org:other'>\n" +
- " <hello />\n" +
- " <hello />\n" +
- " <tuut />" +
- " <other:tree />" +
- "</root>"
- );
- }
-
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/msg/command/AsyncExecutionDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/msg/command/AsyncExecutionDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/msg/command/AsyncExecutionDbTest.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -33,42 +33,32 @@
import org.jbpm.graph.exe.ExecutionContext;
import org.jbpm.graph.exe.ProcessInstance;
-public class AsyncExecutionDbTest extends AbstractDbTestCase {
-
+public class AsyncExecutionDbTest extends AbstractDbTestCase
+{
+
static List recordedNodes = new ArrayList();
-
- public static class RecordNode implements ActionHandler {
+
+ public static class RecordNode implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
- public void execute(ExecutionContext executionContext) throws Exception {
+
+ public void execute(ExecutionContext executionContext) throws Exception
+ {
Node node = executionContext.getNode();
recordedNodes.add(node.getName());
node.leave(executionContext);
}
}
-
- public void testAsyncExecution() throws Exception {
- try {
-
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <start-state>" +
- " <transition to='one' />" +
- " </start-state>" +
- " <node async='true' name='one'>" +
- " <action class='org.jbpm.msg.command.AsyncExecutionDbTest$RecordNode' />" +
- " <transition to='two' />" +
- " </node>" +
- " <node async='exclusive' name='two'>" +
- " <action class='org.jbpm.msg.command.AsyncExecutionDbTest$RecordNode' />" +
- " <transition to='three' />" +
- " </node>" +
- " <node async='true' name='three'>" +
- " <action class='org.jbpm.msg.command.AsyncExecutionDbTest$RecordNode' />" +
- " <transition to='end' />" +
- " </node>" +
- " <end-state name='end' />" +
- "</process-definition>"
- );
+
+ public void testAsyncExecution() throws Exception
+ {
+
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <start-state>" + " <transition to='one' />"
+ + " </start-state>" + " <node async='true' name='one'>" + " <action class='org.jbpm.msg.command.AsyncExecutionDbTest$RecordNode' />"
+ + " <transition to='two' />" + " </node>" + " <node async='exclusive' name='two'>"
+ + " <action class='org.jbpm.msg.command.AsyncExecutionDbTest$RecordNode' />" + " <transition to='three' />" + " </node>"
+ + " <node async='true' name='three'>" + " <action class='org.jbpm.msg.command.AsyncExecutionDbTest$RecordNode' />" + " <transition to='end' />"
+ + " </node>" + " <end-state name='end' />" + "</process-definition>");
processDefinition = saveAndReload(processDefinition);
ProcessInstance processInstance = new ProcessInstance(processDefinition);
@@ -77,73 +67,79 @@
assertEquals(processDefinition.getNode("one"), processInstance.getRootToken().getNode());
assertEquals(1, getNbrOfJobsAvailable());
-
+
processJobs(5000);
-
+
assertEquals(0, getNbrOfJobsAvailable());
-
+
List expectedNodes = new ArrayList();
expectedNodes.add("one");
expectedNodes.add("two");
expectedNodes.add("three");
-
+
assertEquals(expectedNodes, recordedNodes);
processDefinition = graphSession.loadProcessDefinition(processDefinition.getId());
processInstance = graphSession.loadProcessInstance(processInstance.getId());
assertTrue(processInstance.hasEnded());
assertEquals(processDefinition.getNode("end"), processInstance.getRootToken().getNode());
-
- } catch (Exception e) {
- e.printStackTrace();
- }
}
static Set recordedActionNumbers = new HashSet();
-
- public static class RecordAction implements ActionHandler {
+
+ public static class RecordAction implements ActionHandler
+ {
private static final long serialVersionUID = 1L;
String nbr;
- public void execute(ExecutionContext executionContext) throws Exception {
+
+ public void execute(ExecutionContext executionContext) throws Exception
+ {
recordedActionNumbers.add(nbr);
}
}
-
- public void testAsyncAction() throws Exception {
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition>" +
- " <event type='process-start'>" +
- " <action async='true' class='"+RecordAction.class.getName()+"'>" +
- " <nbr>1</nbr>" +
- " </action>" +
- " <action async='exclusive' class='"+RecordAction.class.getName()+"'>" +
- " <nbr>2</nbr>" +
- " </action>" +
- " </event>" +
- " <start-state>" +
- " <transition to='one'>" +
- " <action async='true' class='"+RecordAction.class.getName()+"'>" +
- " <nbr>3</nbr>" +
- " </action>" +
- " <action async='exclusive' class='"+RecordAction.class.getName()+"'>" +
- " <nbr>4</nbr>" +
- " </action>" +
- " </transition>" +
- " </start-state>" +
- " <node name='one'>" +
- " <event type='node-enter'>" +
- " <action async='true' class='"+RecordAction.class.getName()+"'>" +
- " <nbr>5</nbr>" +
- " </action>" +
- " <action async='exclusive' class='"+RecordAction.class.getName()+"'>" +
- " <nbr>6</nbr>" +
- " </action>" +
- " </event>" +
- " <transition to='end' />" +
- " </node>" +
- " <end-state name='end' />" +
- "</process-definition>"
- );
+
+ public void testAsyncAction() throws Exception
+ {
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition>" + " <event type='process-start'>"
+ + " <action async='true' class='"
+ + RecordAction.class.getName()
+ + "'>"
+ + " <nbr>1</nbr>"
+ + " </action>"
+ + " <action async='exclusive' class='"
+ + RecordAction.class.getName()
+ + "'>"
+ + " <nbr>2</nbr>"
+ + " </action>"
+ + " </event>"
+ + " <start-state>"
+ + " <transition to='one'>"
+ + " <action async='true' class='"
+ + RecordAction.class.getName()
+ + "'>"
+ + " <nbr>3</nbr>"
+ + " </action>"
+ + " <action async='exclusive' class='"
+ + RecordAction.class.getName()
+ + "'>"
+ + " <nbr>4</nbr>"
+ + " </action>"
+ + " </transition>"
+ + " </start-state>"
+ + " <node name='one'>"
+ + " <event type='node-enter'>"
+ + " <action async='true' class='"
+ + RecordAction.class.getName()
+ + "'>"
+ + " <nbr>5</nbr>"
+ + " </action>"
+ + " <action async='exclusive' class='"
+ + RecordAction.class.getName()
+ + "'>"
+ + " <nbr>6</nbr>"
+ + " </action>"
+ + " </event>"
+ + " <transition to='end' />" + " </node>" + " <end-state name='end' />" + "</process-definition>");
processDefinition = saveAndReload(processDefinition);
ProcessInstance processInstance = new ProcessInstance(processDefinition);
@@ -152,9 +148,9 @@
assertEquals(processDefinition.getNode("end"), processInstance.getRootToken().getNode());
assertEquals(6, getNbrOfJobsAvailable());
assertEquals(0, recordedActionNumbers.size());
-
+
processJobs(5000);
-
+
assertEquals(0, getNbrOfJobsAvailable());
HashSet expected = new HashSet();
@@ -164,7 +160,7 @@
expected.add("4");
expected.add("5");
expected.add("6");
-
+
assertEquals(expected, recordedActionNumbers);
}
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/optimisticlocking/LockingTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/optimisticlocking/LockingTest.java 2008-09-09 14:21:41 UTC (rev 2152)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/optimisticlocking/LockingTest.java 2008-09-09 14:41:32 UTC (rev 2153)
@@ -16,62 +16,65 @@
import org.jbpm.graph.exe.ProcessInstance;
import org.jbpm.persistence.db.DbPersistenceServiceFactory;
-public class LockingTest extends TestCase {
+public class LockingTest extends TestCase
+{
static JbpmConfiguration jbpmConfiguration = AbstractDbTestCase.getDbTestJbpmConfiguration();
-
+
static int nbrOfThreads = 5;
static int nbrOfIterations = 20;
- private void deployProcess() {
+ private void deployProcess()
+ {
// the process will be executed in 2 separete transactions:
- // Transaction 1 will create the process instance and position
+ // Transaction 1 will create the process instance and position
// the root token in the start state
// Transaction 2 will signal the process instance while it is in the
// start state, and that signal will bring the process to it's end state.
-
+
// It's the second transaction for which we'll set up multiple competing threads
- ProcessDefinition processDefinition = ProcessDefinition.parseXmlString(
- "<process-definition name='lockprocess'>" +
- " <start-state name='start'>" +
- " <transition to='end'/>" +
- " </start-state>" +
- " <end-state name='end' />" +
- "</process-definition>"
- );
+ ProcessDefinition processDefinition = ProcessDefinition.parseXmlString("<process-definition name='lockprocess'>" + " <start-state name='start'>"
+ + " <transition to='end'/>" + " </start-state>" + " <end-state name='end' />" + "</process-definition>");
// deploy the process
JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
+ try
+ {
jbpmContext.deployProcessDefinition(processDefinition);
- } finally {
+ }
+ finally
+ {
jbpmContext.close();
}
}
- public void testLocking() {
+ public void testLocking()
+ {
createSchema();
deployProcess();
-
- for(int i=0; i<nbrOfIterations; i++) {
+
+ for (int i = 0; i < nbrOfIterations; i++)
+ {
long processInstanceId = launchProcessInstance();
-
- // create a bunch of threads that will all wait on the
+
+ // create a bunch of threads that will all wait on the
// semaphore before they will try to signal the same process instance
Object semaphore = new Object();
List threads = startThreads(semaphore, processInstanceId);
-
+
// release all the threads
- synchronized(semaphore) {
+ synchronized (semaphore)
+ {
semaphore.notifyAll();
}
-
+
// wait for all threads to finish
joinAllThreads(threads);
-
+
// check that only 1 of those threads committed
JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
+ try
+ {
Session session = jbpmContext.getSession();
Query query = session.createQuery("select c from org.jbpm.graph.exe.Comment as c");
List results = query.list();
@@ -80,109 +83,143 @@
// delete the comment
session.delete(results.get(0));
-
- } finally {
+
+ }
+ finally
+ {
jbpmContext.close();
}
// check that the process instance has ended
jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
+ try
+ {
ProcessInstance processInstance = jbpmContext.loadProcessInstance(processInstanceId);
assertTrue(processInstance.hasEnded());
-
- } finally {
+
+ }
+ finally
+ {
jbpmContext.close();
}
}
}
-
- private long launchProcessInstance() {
+
+ private long launchProcessInstance()
+ {
JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
+ try
+ {
return jbpmContext.newProcessInstance("lockprocess").getId();
- } finally {
+ }
+ finally
+ {
jbpmContext.close();
}
}
-
- private List startThreads(Object semaphore, long processInstanceId) {
+
+ private List startThreads(Object semaphore, long processInstanceId)
+ {
List threads = new ArrayList();
- for (int i=0; i<nbrOfThreads; i++) {
+ for (int i = 0; i < nbrOfThreads; i++)
+ {
Thread thread = new LockThread(semaphore, processInstanceId);
thread.start();
threads.add(thread);
}
-
- try {
+
+ try
+ {
// giving the threads the opportunity to start and arrive in the wait
Thread.sleep(200);
- } catch (InterruptedException e) {
- e.printStackTrace();
}
+ catch (InterruptedException e)
+ {
+ // ignore
+ }
return threads;
}
-
- public static class LockThread extends Thread {
+
+ public static class LockThread extends Thread
+ {
Object semaphore;
long processInstanceId;
- public LockThread(Object semaphore, long processInstanceId) {
+
+ public LockThread(Object semaphore, long processInstanceId)
+ {
this.semaphore = semaphore;
this.processInstanceId = processInstanceId;
}
- public void run() {
- try {
- // first wait until the all threads are released at once in the
+
+ public void run()
+ {
+ try
+ {
+ // first wait until the all threads are released at once in the
// method testLocking
- synchronized(semaphore) {
+ synchronized (semaphore)
+ {
semaphore.wait();
}
-
+
// after a thread is released (=notified), it will try to load the process instance,
// signal it and then commit the transaction
JbpmContext jbpmContext = jbpmConfiguration.createJbpmContext();
- try {
+ try
+ {
ProcessInstance processInstance = jbpmContext.loadProcessInstance(processInstanceId);
processInstance.signal();
jbpmContext.save(processInstance);
-
+
// add a comment in the same transaction so that we can see which thread won
- Comment comment = new Comment(getName()+" committed");
+ Comment comment = new Comment(getName() + " committed");
jbpmContext.getSession().save(comment);
- } catch (Exception e) {
+ }
+ catch (Exception e)
+ {
jbpmContext.setRollbackOnly();
- } finally {
+ }
+ finally
+ {
jbpmContext.close();
}
-
- } catch (InterruptedException e) {
- e.printStackTrace();
+
+ }
+ catch (InterruptedException e)
+ {
fail("semaphore waiting got interrupted");
- } catch (Throwable t) {
- t.printStackTrace();
}
+ catch (Throwable t)
+ {
+ // ignore
+ }
}
}
- private void joinAllThreads(List threads) {
+ private void joinAllThreads(List threads)
+ {
Iterator iter = threads.iterator();
- while (iter.hasNext()) {
- Thread thread = (Thread) iter.next();
- try {
+ while (iter.hasNext())
+ {
+ Thread thread = (Thread)iter.next();
+ try
+ {
thread.join();
- } catch (InterruptedException e) {
- e.printStackTrace();
+ }
+ catch (InterruptedException e)
+ {
fail("join interrupted");
}
}
}
- private void createSchema() {
+ private void createSchema()
+ {
// create the jbpm schema
- DbPersistenceServiceFactory persistenceServiceFactory = (DbPersistenceServiceFactory) jbpmConfiguration.getServiceFactory("persistence");
+ DbPersistenceServiceFactory persistenceServiceFactory = (DbPersistenceServiceFactory)jbpmConfiguration.getServiceFactory("persistence");
persistenceServiceFactory.createSchema();
}
-
+
}
17 years, 7 months
JBoss JBPM SVN: r2152 - in jbpm3/trunk/modules/core/src/test/java/org/jbpm: db and 11 other directories.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-09 10:21:41 -0400 (Tue, 09 Sep 2008)
New Revision: 2152
Modified:
jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/log/VariableLogTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/db/GraphSessionDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/def/MultipleProcessDefinitionEventsDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/log/ActionLogDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/node/ProcessStateDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/MultiJobExecutorDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/convert/ConversionTestCase.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/AbstractXmlTestCase.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/ActionXmlTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/optimisticlocking/LockingTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/perf/PerfWithoutDbTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/scheduler/exe/SchedulerTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/taskmgmt/exe/TaskInstanceEndTest.java
jbpm3/trunk/modules/core/src/test/java/org/jbpm/util/StringUtilTest.java
Log:
Comment System.out.println in core tests
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/log/VariableLogTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/log/VariableLogTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/context/log/VariableLogTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -67,7 +67,7 @@
contextInstance.setVariable("a", "first value".getBytes());
contextInstance.setVariable("a", "second value".getBytes());
- System.out.println(loggingInstance.getLogs());
+ // System.out.println(loggingInstance.getLogs());
List logs = loggingInstance.getLogs(VariableUpdateLog.class);
VariableUpdateLog variableLog = (VariableUpdateLog)logs.get(1);
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/db/GraphSessionDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/db/GraphSessionDbTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/db/GraphSessionDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -327,7 +327,7 @@
public void testCalculateAverageTimeByNode() {
List foo = graphSession.calculateAverageTimeByNode(1L, 3000L);
- System.out.println("Foo has " + foo.size() + " members");
+ // System.out.println("Foo has " + foo.size() + " members");
}
private int getVersionOfProcess(String name, List latestProcessDefinitions) {
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/def/MultipleProcessDefinitionEventsDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/def/MultipleProcessDefinitionEventsDbTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/def/MultipleProcessDefinitionEventsDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -70,7 +70,7 @@
assertTrue(stateOne.getEvent("node-enter") != stateTwo.getEvent("node-enter"));
Map processEvents = processDefinitionTwo.getEvents();
- System.out.println(processDefinitionTwo.getEvents());
+ // System.out.println(processDefinitionTwo.getEvents());
assertEquals("Process Definition should not have any events. events = " + processEvents, 0, processEvents.size());
}
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/log/ActionLogDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/log/ActionLogDbTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/log/ActionLogDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -38,10 +38,10 @@
public void testActionExceptionLog() {
ActionLog actionLog = new ActionLog();
actionLog.setException(new IllegalArgumentException("it's not rocket science"));
- System.out.println("EXCEPTION LENGTH: "+actionLog.getException().length());
+ // System.out.println("EXCEPTION LENGTH: "+actionLog.getException().length());
actionLog = (ActionLog) saveAndReload(actionLog);
assertNotNull(actionLog.getException());
- System.out.println("EXCEPTION LENGTH: "+actionLog.getException().length());
+ // System.out.println("EXCEPTION LENGTH: "+actionLog.getException().length());
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/node/ProcessStateDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/node/ProcessStateDbTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/graph/node/ProcessStateDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -349,7 +349,7 @@
long processInstanceId = processInstance1.getId();
long subProcessInstanceId = processInstance1.getRootToken().getSubProcessInstance().getId();
- System.out.println("process ID: " + processInstanceId + " subprocess ID: " + subProcessInstanceId);
+ // System.out.println("process ID: " + processInstanceId + " subprocess ID: " + subProcessInstanceId);
processInstance1 = jbpmContext.loadProcessInstance(processInstanceId);
assertNotNull(processInstance1.getRootToken().getSubProcessInstance());
@@ -382,7 +382,7 @@
long processInstanceId2 = processInstance2.getId();
long subProcessInstanceId2 = processInstance2.getRootToken().getSubProcessInstance().getId();
- System.out.println("process ID: " + processInstanceId2 + " subprocess ID: " + subProcessInstanceId2);
+ // System.out.println("process ID: " + processInstanceId2 + " subprocess ID: " + subProcessInstanceId2);
processInstance2 = jbpmContext.loadProcessInstance(processInstanceId2);
assertNotNull(processInstance2.getRootToken().getSubProcessInstance());
Modified: 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-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/job/executor/MultiJobExecutorDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -107,7 +107,7 @@
private static final long serialVersionUID = 1L;
public void execute(ExecutionContext exeContext) throws Exception {
- System.out.println("Action 1");
+ // System.out.println("Action 1");
exeContext.leaveNode();
}
@@ -120,7 +120,7 @@
private static final long serialVersionUID = 1L;
public void execute(ExecutionContext exeContext) throws Exception {
- System.out.println("Action 2: " + incrementCount());
+ // System.out.println("Action 2: " + incrementCount());
exeContext.leaveNode();
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/convert/ConversionTestCase.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/convert/ConversionTestCase.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/convert/ConversionTestCase.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -51,7 +51,7 @@
converter.serializetoXML( bos, doc30) ;
- System.out.println(bos.toString());
+ // System.out.println(bos.toString());
ProcessDefinition.parseXmlString( bos.toString() );
}
@@ -77,7 +77,7 @@
fail("2.0 PAR did not convert successfully.");
else
{
- System.out.println(result);
+ // System.out.println(result);
try
{
ProcessDefinition.parseXmlString( result );
@@ -110,7 +110,7 @@
fail("2.0 PAR did not convert successfully.");
else
{
- System.out.println(result);
+ // System.out.println(result);
try
{
ProcessDefinition.parseXmlString( result );
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/AbstractXmlTestCase.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/AbstractXmlTestCase.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/AbstractXmlTestCase.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -72,6 +72,6 @@
StringWriter stringWriter = new StringWriter();
JpdlXmlWriter jpdlWriter = new JpdlXmlWriter(stringWriter);
jpdlWriter.write( processDefinition );
- System.out.println( stringWriter.toString() );
+ // System.out.println( stringWriter.toString() );
}
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/ActionXmlTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/ActionXmlTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/jpdl/xml/ActionXmlTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -139,14 +139,14 @@
"<process-definition>" +
" <event type='node-enter'>" +
" <script class='one'>" +
- " System.out.println(\"blabla\");" +
+ " // System.out.println(\"blabla\");" +
" </script>" +
" </event>" +
"</process-definition>"
);
Event event = processDefinition.getEvent("node-enter");
Script script = (Script)event.getActions().get(0);
- assertEquals("System.out.println(\"blabla\");", script.getExpression().trim());
+ assertEquals("// System.out.println(\"blabla\");", script.getExpression().trim());
}
public void testWriteActionTextConfiguration() throws Exception {
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/optimisticlocking/LockingTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/optimisticlocking/LockingTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/optimisticlocking/LockingTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -75,7 +75,7 @@
Session session = jbpmContext.getSession();
Query query = session.createQuery("select c from org.jbpm.graph.exe.Comment as c");
List results = query.list();
- System.out.println("iteration "+i+": "+results);
+ // System.out.println("iteration "+i+": "+results);
assertEquals(results.toString(), 1, results.size());
// delete the comment
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/perf/PerfWithoutDbTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/perf/PerfWithoutDbTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/perf/PerfWithoutDbTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -42,7 +42,7 @@
}
String msg = i+" "+millis+" "+freeMemory+" "+avg;
- System.out.println(msg);
+ // System.out.println(msg);
out.println(msg);
out.flush();
@@ -62,7 +62,7 @@
executeWebSale();
if (i>nbrOfExecutions) {
long elapsed = System.currentTimeMillis() - start;
- System.out.println(Float.toString((float)nbrOfExecutions/(float)elapsed));
+ // System.out.println(Float.toString((float)nbrOfExecutions/(float)elapsed));
i = 0;
start = System.currentTimeMillis();
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/scheduler/exe/SchedulerTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/scheduler/exe/SchedulerTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/scheduler/exe/SchedulerTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -108,7 +108,7 @@
Timer scheduledTimer = (Timer) testSchedulerService.createdTimers.get(0);
assertEquals("reminder", scheduledTimer.getName());
assertEquals(processDefinition.getNode("catch crooks"), scheduledTimer.getGraphElement());
- System.out.println("due date: "+scheduledTimer.getDueDate());
+ // System.out.println("due date: "+scheduledTimer.getDueDate());
assertNotNull(scheduledTimer.getDueDate());
assertEquals("the-remainder-action-class-name", scheduledTimer.getAction().getActionDelegation().getClassName());
assertSame(processInstance.getRootToken(), scheduledTimer.getToken());
@@ -145,7 +145,7 @@
Timer scheduledTimer = (Timer) testSchedulerService.createdTimers.get(0);
assertEquals("reminder", scheduledTimer.getName());
assertEquals(processDefinition.getNode("catch crooks"), scheduledTimer.getGraphElement());
- System.out.println("due date: "+scheduledTimer.getDueDate());
+ // System.out.println("due date: "+scheduledTimer.getDueDate());
assertNotNull(scheduledTimer.getDueDate());
assertEquals("10 business minutes", scheduledTimer.getRepeat());
assertEquals("the-remainder-action-class-name", scheduledTimer.getAction().getActionDelegation().getClassName());
@@ -186,7 +186,7 @@
Timer scheduledTimer = (Timer) testSchedulerService.createdTimers.get(0);
assertEquals("reminder", scheduledTimer.getName());
assertEquals(processDefinition.getNode("catch crooks"), scheduledTimer.getGraphElement());
- System.out.println("due date: "+scheduledTimer.getDueDate());
+ // System.out.println("due date: "+scheduledTimer.getDueDate());
assertNotNull(scheduledTimer.getDueDate());
assertEquals("the-remainder-action-class-name", scheduledTimer.getAction().getActionDelegation().getClassName());
assertSame(processInstance.getRootToken(), scheduledTimer.getToken());
@@ -232,7 +232,7 @@
Timer scheduledTimer = (Timer) testSchedulerService.createdTimers.get(0);
assertEquals("reminder", scheduledTimer.getName());
assertEquals(processDefinition.getNode("catch crooks"), scheduledTimer.getGraphElement());
- System.out.println("due date: "+scheduledTimer.getDueDate());
+ // System.out.println("due date: "+scheduledTimer.getDueDate());
assertNotNull(scheduledTimer.getDueDate());
assertEquals("10 business minutes", scheduledTimer.getRepeat());
assertEquals("the-remainder-action-class-name", scheduledTimer.getAction().getActionDelegation().getClassName());
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/taskmgmt/exe/TaskInstanceEndTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/taskmgmt/exe/TaskInstanceEndTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/taskmgmt/exe/TaskInstanceEndTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -217,7 +217,7 @@
TaskInstance ti = (TaskInstance)it.next();
if (!ti.hasEnded()) n++;
}
- System.out.println("There are " + n + " unfinished tasks");
+ // System.out.println("There are " + n + " unfinished tasks");
assertEquals(1, n);
}
Modified: jbpm3/trunk/modules/core/src/test/java/org/jbpm/util/StringUtilTest.java
===================================================================
--- jbpm3/trunk/modules/core/src/test/java/org/jbpm/util/StringUtilTest.java 2008-09-09 13:38:01 UTC (rev 2151)
+++ jbpm3/trunk/modules/core/src/test/java/org/jbpm/util/StringUtilTest.java 2008-09-09 14:21:41 UTC (rev 2152)
@@ -6,7 +6,7 @@
public class StringUtilTest extends TestCase {
public void testConv() {
- System.out.println(StringUtil.toHexString(new byte[]{(byte) 0x5a,(byte) 0x23,(byte) 0x7c,(byte) 0x0b}));
- System.out.println(StringUtil.toHexStringHibernate(new byte[]{(byte) 0x5a,(byte) 0x23,(byte) 0x7c,(byte) 0x0b}));
+ // System.out.println(StringUtil.toHexString(new byte[]{(byte) 0x5a,(byte) 0x23,(byte) 0x7c,(byte) 0x0b}));
+ // System.out.println(StringUtil.toHexStringHibernate(new byte[]{(byte) 0x5a,(byte) 0x23,(byte) 0x7c,(byte) 0x0b}));
}
}
17 years, 7 months
JBoss JBPM SVN: r2151 - jbpm3/trunk/hudson/hudson-home.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-09 09:38:01 -0400 (Tue, 09 Sep 2008)
New Revision: 2151
Modified:
jbpm3/trunk/hudson/hudson-home/command.sh
Log:
docu, dependency tree
Modified: jbpm3/trunk/hudson/hudson-home/command.sh
===================================================================
--- jbpm3/trunk/hudson/hudson-home/command.sh 2008-09-09 13:25:02 UTC (rev 2150)
+++ jbpm3/trunk/hudson/hudson-home/command.sh 2008-09-09 13:38:01 UTC (rev 2151)
@@ -1,4 +1,9 @@
#!/bin/sh
+#
+# A script that uses Maven to build the project and
+# execute its test suite against a given target container
+#
+# $Id:$
WORKSPACE=`pwd`
JBPMDIR=$WORKSPACE/jbpm
@@ -28,17 +33,12 @@
ENVIRONMENT="-Ddatabase=$DATABASE -Djboss.id=$CONTAINER -Djboss.home=$JBOSS_HOME -Djboss.bind.address=$JBOSS_BINDADDR"
#
-# log dependency tree
+# Build distro
#
cd $JBPMDIR
cp profiles.xml.example profiles.xml
-mvn -U $ENVIRONMENT dependency:tree | tee $WORKSPACE/dependency-tree.txt
-
-#
-# Build distro
-#
echo "mvn $ENVIRONMENT -Pdistro clean package"
-mvn $ENVIRONMENT -Pdistro clean package; MVN_STATUS=$?
+mvn -U $ENVIRONMENT -Pdistro clean package; MVN_STATUS=$?
if [ $MVN_STATUS -ne 0 ]; then
echo maven exit status $MVN_STATUS
exit 1
@@ -75,6 +75,11 @@
fi
#
+# log dependency tree
+#
+mvn $ENVIRONMENT dependency:tree | tee $WORKSPACE/dependency-tree.txt
+
+#
# execute tests
#
echo "mvn $ENVIRONMENT -DtestFailureIgnore=true test"
17 years, 7 months
JBoss JBPM SVN: r2150 - in jbpm3/trunk/modules/distribution: scripts and 1 other directories.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-09 09:25:02 -0400 (Tue, 09 Sep 2008)
New Revision: 2150
Modified:
jbpm3/trunk/modules/distribution/pom.xml
jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml
jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
Log:
Include more sources
Modified: jbpm3/trunk/modules/distribution/pom.xml
===================================================================
--- jbpm3/trunk/modules/distribution/pom.xml 2008-09-09 12:48:36 UTC (rev 2149)
+++ jbpm3/trunk/modules/distribution/pom.xml 2008-09-09 13:25:02 UTC (rev 2150)
@@ -40,12 +40,6 @@
</dependency>
<dependency>
<groupId>org.jboss.jbpm</groupId>
- <artifactId>jbpm-core</artifactId>
- <classifier>sources</classifier>
- <version>${version}</version>
- </dependency>
- <dependency>
- <groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-enterprise-beans</artifactId>
<version>${version}</version>
<type>ejb</type>
@@ -76,12 +70,6 @@
<dependency>
<groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-identity</artifactId>
- <classifier>sources</classifier>
- <version>${version}</version>
- </dependency>
- <dependency>
- <groupId>org.jboss.jbpm</groupId>
- <artifactId>jbpm-identity</artifactId>
<classifier>service</classifier>
<version>${version}</version>
<type>zip</type>
@@ -98,6 +86,32 @@
<type>jdocbook</type>
</dependency>
+ <!-- Sources -->
+ <dependency>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-console</artifactId>
+ <classifier>sources</classifier>
+ <version>${version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-core</artifactId>
+ <classifier>sources</classifier>
+ <version>${version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-enterprise-beans</artifactId>
+ <classifier>sources</classifier>
+ <version>${version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-identity</artifactId>
+ <classifier>sources</classifier>
+ <version>${version}</version>
+ </dependency>
+
<!-- Thirdparty Dependencies -->
<dependency>
<groupId>org.apache.ant</groupId>
Modified: jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml
===================================================================
--- jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml 2008-09-09 12:48:36 UTC (rev 2149)
+++ jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml 2008-09-09 13:25:02 UTC (rev 2150)
@@ -57,8 +57,7 @@
<outputFileNameMapping>${artifact.artifactId}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
<useStrictFiltering>true</useStrictFiltering>
<includes>
- <include>*:jbpm-core:jar:sources</include>
- <include>*:jbpm-identity:jar:sources</include>
+ <include>org.jboss.jbpm:*:jar:sources</include>
</includes>
<unpack>false</unpack>
</dependencySet>
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-09 12:48:36 UTC (rev 2149)
+++ jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-09 13:25:02 UTC (rev 2150)
@@ -123,7 +123,9 @@
<!-- jbpm3/src -->
<fileset dir="@{deploy.artifacts.dir}/src" targetdir="$INSTALL_PATH/jbpm3/src" override="true">
+ <include name="jbpm-console-sources.jar" />
<include name="jbpm-core-sources.jar" />
+ <include name="jbpm-enterprise-beans-sources.jar" />
<include name="jbpm-identity-sources.jar" />
</fileset>
</pack>
17 years, 7 months
JBoss JBPM SVN: r2149 - in jbpm3/trunk/modules/distribution: src/main/etc and 1 other directories.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-09 08:48:36 -0400 (Tue, 09 Sep 2008)
New Revision: 2149
Added:
jbpm3/trunk/modules/distribution/src/main/etc/version.info.xml
Modified:
jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml
jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
Log:
Restore version.info.xml
Modified: jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml
===================================================================
--- jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml 2008-09-09 12:25:15 UTC (rev 2148)
+++ jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml 2008-09-09 12:48:36 UTC (rev 2149)
@@ -9,13 +9,32 @@
<!-- Dependency Sets -->
<dependencySets>
+
+ <!-- lib -->
<dependencySet>
<outputDirectory>lib</outputDirectory>
<outputFileNameMapping>${artifact.artifactId}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
<useStrictFiltering>true</useStrictFiltering>
+ <scope>compile</scope>
<unpack>false</unpack>
</dependencySet>
<dependencySet>
+ <outputDirectory>lib</outputDirectory>
+ <outputFileNameMapping>${artifact.artifactId}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
+ <useStrictFiltering>true</useStrictFiltering>
+ <scope>provided</scope>
+ <unpack>false</unpack>
+ </dependencySet>
+ <dependencySet>
+ <outputDirectory>lib</outputDirectory>
+ <outputFileNameMapping>${artifact.artifactId}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
+ <useStrictFiltering>true</useStrictFiltering>
+ <scope>test</scope>
+ <unpack>false</unpack>
+ </dependencySet>
+
+ <!-- resources -->
+ <dependencySet>
<outputDirectory>resources/jbpm-core-config</outputDirectory>
<useStrictFiltering>true</useStrictFiltering>
<includes>
@@ -31,6 +50,8 @@
</includes>
<unpack>true</unpack>
</dependencySet>
+
+ <!-- src -->
<dependencySet>
<outputDirectory>src</outputDirectory>
<outputFileNameMapping>${artifact.artifactId}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
@@ -44,12 +65,13 @@
</dependencySets>
<fileSets>
- <!-- / -->
+ <!-- etc -->
<fileSet>
<directory>src/main/etc</directory>
- <outputDirectory>/</outputDirectory>
+ <outputDirectory>/etc</outputDirectory>
<includes>
<include>JBossORG-EULA.txt</include>
+ <include>version.info.xml</include>
</includes>
</fileSet>
</fileSets>
Added: jbpm3/trunk/modules/distribution/src/main/etc/version.info.xml
===================================================================
--- jbpm3/trunk/modules/distribution/src/main/etc/version.info.xml (rev 0)
+++ jbpm3/trunk/modules/distribution/src/main/etc/version.info.xml 2008-09-09 12:48:36 UTC (rev 2149)
@@ -0,0 +1,26 @@
+<jbpm-version-info name="jBPM3" namespace="urn:jbpm.org:jpdl-3.2">
+
+ <classpathentry path="lib/jbpm-core.jar" src="src/jbpm-core-sources.jar" />
+ <classpathentry path="lib/jbpm-identity.jar" src="src/jbpm-identity-sources.jar" />
+
+ <classpathentry path="lib/activation.jar" />
+ <classpathentry path="lib/antlr.jar" />
+ <classpathentry path="lib/asm.jar"/>
+ <classpathentry path="lib/bsh.jar"/>
+ <classpathentry path="lib/cglib.jar"/>
+ <classpathentry path="lib/commons-collections.jar"/>
+ <classpathentry path="lib/commons-logging.jar"/>
+ <classpathentry path="lib/dom4j.jar"/>
+ <classpathentry path="lib/hibernate.jar"/>
+ <classpathentry path="lib/hsqldb.jar"/>
+ <!-- classpathentry path="lib/jboss-j2ee.jar"/-->
+ <!-- classpathentry path="lib/jcr-1.0.jar"/ -->
+ <classpathentry path="lib/junit.jar"/>
+ <classpathentry path="lib/log4j.jar"/>
+ <!-- classpathentry path="lib/mail.jar"/ -->
+ <!-- classpathentry path="lib/servlet-api.jar"/ -->
+
+ <config path="config"/>
+ <examples path="examples" />
+
+</jbpm-version-info>
Property changes on: jbpm3/trunk/modules/distribution/src/main/etc/version.info.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
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-09 12:25:15 UTC (rev 2148)
+++ jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-09 12:48:36 UTC (rev 2149)
@@ -93,10 +93,14 @@
<!-- jbpm3/config -->
<file src="@{deploy.artifacts.dir}/lib/jbpm-core-config.zip" targetdir="$INSTALL_PATH/jbpm3/config"
unpack="true" override="true" />
+ <file src="@{deploy.artifacts.dir}/etc/version.info.xml" targetdir="$INSTALL_PATH/jbpm3/config"
+ override="true" />
<!-- jbpm3/docs -->
<file src="@{deploy.artifacts.dir}/lib/jbpm-userguide.zip" targetdir="$INSTALL_PATH/jbpm3/docs/userguide"
unpack="true" override="true" />
+ <file src="@{deploy.artifacts.dir}/etc/JBossORG-EULA.txt" targetdir="$INSTALL_PATH/jbpm3"
+ override="true" />
<!-- jbpm3/lib -->
<fileset dir="@{deploy.artifacts.dir}/lib" targetdir="$INSTALL_PATH/jbpm3/lib" override="true">
@@ -113,6 +117,8 @@
<include name="dom4j.jar" />
<include name="hibernate.jar" />
<include name="hsqldb.jar" />
+ <include name="junit.jar" />
+ <include name="log4j.jar" />
</fileset>
<!-- jbpm3/src -->
17 years, 7 months
JBoss JBPM SVN: r2148 - in jbpm3/trunk/modules/enterprise: jar and 1 other directory.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-09 08:25:15 -0400 (Tue, 09 Sep 2008)
New Revision: 2148
Added:
jbpm3/trunk/modules/enterprise/ear/.classpath
jbpm3/trunk/modules/enterprise/ear/.project
jbpm3/trunk/modules/enterprise/jar/.classpath
jbpm3/trunk/modules/enterprise/jar/.project
Modified:
jbpm3/trunk/modules/enterprise/ear/
jbpm3/trunk/modules/enterprise/jar/
Log:
Use enterprise EAR packaging
Property changes on: jbpm3/trunk/modules/enterprise/ear
___________________________________________________________________
Name: svn:ignore
+ target
.settings
Added: jbpm3/trunk/modules/enterprise/ear/.classpath
===================================================================
--- jbpm3/trunk/modules/enterprise/ear/.classpath (rev 0)
+++ jbpm3/trunk/modules/enterprise/ear/.classpath 2008-09-09 12:25:15 UTC (rev 2148)
@@ -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.5"/>
+ <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
Added: jbpm3/trunk/modules/enterprise/ear/.project
===================================================================
--- jbpm3/trunk/modules/enterprise/ear/.project (rev 0)
+++ jbpm3/trunk/modules/enterprise/ear/.project 2008-09-09 12:25:15 UTC (rev 2148)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>jbpm-enterprise-archive</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>
Property changes on: jbpm3/trunk/modules/enterprise/jar
___________________________________________________________________
Name: svn:ignore
+ target
.settings
Added: jbpm3/trunk/modules/enterprise/jar/.classpath
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/.classpath (rev 0)
+++ jbpm3/trunk/modules/enterprise/jar/.classpath 2008-09-09 12:25:15 UTC (rev 2148)
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" output="target/classes" path="src/main/java"/>
+ <classpathentry kind="src" output="target/test-classes" path="src/test/java"/>
+ <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"/>
+ <classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/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/trunk/modules/enterprise/jar/.project
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/.project (rev 0)
+++ jbpm3/trunk/modules/enterprise/jar/.project 2008-09-09 12:25:15 UTC (rev 2148)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>jbpm-enterprise-beans</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>
17 years, 7 months
JBoss JBPM SVN: r2147 - in jbpm3/trunk/modules: distribution and 5 other directories.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-09 08:20:10 -0400 (Tue, 09 Sep 2008)
New Revision: 2147
Added:
jbpm3/trunk/modules/enterprise/ear/
jbpm3/trunk/modules/enterprise/ear/pom.xml
jbpm3/trunk/modules/enterprise/jar/
jbpm3/trunk/modules/enterprise/jar/pom.xml
jbpm3/trunk/modules/enterprise/jar/scripts/
jbpm3/trunk/modules/enterprise/jar/src/
Removed:
jbpm3/trunk/modules/enterprise/scripts/
jbpm3/trunk/modules/enterprise/src/
Modified:
jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/jboss-web.xml
jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/web.xml
jbpm3/trunk/modules/distribution/pom.xml
jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml
jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml
jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
jbpm3/trunk/modules/enterprise/pom.xml
Log:
Use enterprise EAR packaging
Modified: jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/jboss-web.xml
===================================================================
--- jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/jboss-web.xml 2008-09-09 09:30:11 UTC (rev 2146)
+++ jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/jboss-web.xml 2008-09-09 12:20:10 UTC (rev 2147)
@@ -1,36 +1,34 @@
<?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>
+ <!--
+ 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>jdbc/JbpmDataSource</res-ref-name>
+ <jndi-name>java:/JbpmDS</jndi-name>
+ </resource-ref>
- <!-- EJB local references (begin) ===
- <resource-ref>
- <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
- <jndi-name>java:JmsXA</jndi-name>
- </resource-ref>
+ <resource-ref>
+ <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
+ <jndi-name>java:JmsXA</jndi-name>
+ </resource-ref>
- <ejb-local-ref>
- <ejb-ref-name>ejb/TimerEntityBean</ejb-ref-name>
- <local-jndi-name>java:ejb/TimerEntityBean</local-jndi-name>
- </ejb-local-ref>
+ <ejb-local-ref>
+ <ejb-ref-name>ejb/TimerEntityBean</ejb-ref-name>
+ <local-jndi-name>java:ejb/TimerEntityBean</local-jndi-name>
+ </ejb-local-ref>
- <message-destination-ref>
- <message-destination-ref-name>jms/JobQueue</message-destination-ref-name>
- <jndi-name>queue/JbpmJobQueue</jndi-name>
- </message-destination-ref>
- ==== EJB local references (end) -->
+ <message-destination-ref>
+ <message-destination-ref-name>jms/JobQueue</message-destination-ref-name>
+ <jndi-name>queue/JbpmJobQueue</jndi-name>
+ </message-destination-ref>
</jboss-web>
Modified: jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/web.xml
===================================================================
--- jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/web.xml 2008-09-09 09:30:11 UTC (rev 2146)
+++ jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/web.xml 2008-09-09 12:20:10 UTC (rev 2147)
@@ -110,7 +110,7 @@
</login-config>
<!== End Login configuration option #2 -->
- <!-- Job executor launcher (begin) -->
+ <!-- Job executor launcher (begin) ===
<listener>
<description>
Starts the job executor on servlet context initialization and stops it on
@@ -118,7 +118,7 @@
</description>
<listener-class>org.jbpm.web.JobExecutorLauncher</listener-class>
</listener>
- <!-- Job executor launcher (end) -->
+ ==== Job executor launcher (end) -->
<listener>
<description>
@@ -145,52 +145,50 @@
</servlet-mapping>
==== Job executor servlet (end) -->
- <resource-ref>
- <description>
+ <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>
+ </description>
+ <res-ref-name>jdbc/JbpmDataSource</res-ref-name>
+ <res-type>javax.sql.DataSource</res-type>
+ <res-auth>Container</res-auth>
+ </resource-ref>
- <!-- This section is so that the web console can deploy in the jbpm-enterprise.ear module -->
- <!-- EJB local references (begin) ===
- <resource-ref>
- <description>
+ <!-- This section is so that the web console can deploy in the jbpm-enterprise.ear module -->
+ <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>
+ </description>
+ <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
+ <res-type>javax.jms.ConnectionFactory</res-type>
+ <res-auth>Container</res-auth>
+ </resource-ref>
- <ejb-local-ref>
- <description>
+ <ejb-local-ref>
+ <description>
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>
- <local-home>org.jbpm.ejb.LocalTimerEntityHome</local-home>
- <local>org.jbpm.ejb.LocalTimerEntity</local>
- <ejb-link>TimerEntityBean</ejb-link>
- </ejb-local-ref>
+ </description>
+ <ejb-ref-name>ejb/TimerEntityBean</ejb-ref-name>
+ <ejb-ref-type>Entity</ejb-ref-type>
+ <local-home>org.jbpm.ejb.LocalTimerEntityHome</local-home>
+ <local>org.jbpm.ejb.LocalTimerEntity</local>
+ <ejb-link>TimerEntityBean</ejb-link>
+ </ejb-local-ref>
- <message-destination-ref>
- <description>
+ <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-type>javax.jms.Queue</message-destination-type>
- <message-destination-usage>Produces</message-destination-usage>
- <message-destination-link>JobQueue</message-destination-link>
- </message-destination-ref>
- ==== EJB local references (end) -->
+ <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-link>JobQueue</message-destination-link>
+ </message-destination-ref>
</web-app>
Modified: jbpm3/trunk/modules/distribution/pom.xml
===================================================================
--- jbpm3/trunk/modules/distribution/pom.xml 2008-09-09 09:30:11 UTC (rev 2146)
+++ jbpm3/trunk/modules/distribution/pom.xml 2008-09-09 12:20:10 UTC (rev 2147)
@@ -29,12 +29,6 @@
<dependencies>
<dependency>
<groupId>org.jboss.jbpm</groupId>
- <artifactId>jbpm-console</artifactId>
- <version>${version}</version>
- <type>war</type>
- </dependency>
- <dependency>
- <groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-core</artifactId>
<version>${version}</version>
</dependency>
@@ -52,17 +46,24 @@
</dependency>
<dependency>
<groupId>org.jboss.jbpm</groupId>
- <artifactId>jbpm-enterprise</artifactId>
+ <artifactId>jbpm-enterprise-beans</artifactId>
<version>${version}</version>
+ <type>ejb</type>
</dependency>
<dependency>
<groupId>org.jboss.jbpm</groupId>
- <artifactId>jbpm-enterprise</artifactId>
+ <artifactId>jbpm-enterprise-beans</artifactId>
<classifier>config</classifier>
<version>${version}</version>
</dependency>
<dependency>
<groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-enterprise-archive</artifactId>
+ <version>${version}</version>
+ <type>ear</type>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-identity</artifactId>
<version>${version}</version>
</dependency>
Modified: jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml
===================================================================
--- jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml 2008-09-09 09:30:11 UTC (rev 2146)
+++ jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml 2008-09-09 12:20:10 UTC (rev 2147)
@@ -92,12 +92,6 @@
<equals arg1="${database}" arg2="postgresql"/>
</condition>
- <property name="web.xml" value="${deploy.artifacts.resources}/jbpm-console/WEB-INF/web.xml"/>
- <macro-disable file="${web.xml}" section="Job executor launcher"/>
- <macro-enable file="${web.xml}" section="EJB local references"/>
-
- <macro-enable file="${deploy.artifacts.resources}/jbpm-console/WEB-INF/jboss-web.xml"
- section="EJB local references"/>
</target>
<!-- ================================================================== -->
@@ -128,6 +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-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/scripts/assembly-deploy-artifacts.xml
===================================================================
--- jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml 2008-09-09 09:30:11 UTC (rev 2146)
+++ jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml 2008-09-09 12:20:10 UTC (rev 2147)
@@ -27,7 +27,7 @@
<outputDirectory>resources/jbpm-enterprise-config</outputDirectory>
<useStrictFiltering>true</useStrictFiltering>
<includes>
- <include>*:jbpm-enterprise:jar:config</include>
+ <include>*:jbpm-enterprise-beans:jar:config</include>
</includes>
<unpack>true</unpack>
</dependencySet>
@@ -41,14 +41,6 @@
</includes>
<unpack>false</unpack>
</dependencySet>
- <dependencySet>
- <outputDirectory>resources/jbpm-console</outputDirectory>
- <useStrictFiltering>true</useStrictFiltering>
- <includes>
- <include>*:jbpm-console:war</include>
- </includes>
- <unpack>true</unpack>
- </dependencySet>
</dependencySets>
<fileSets>
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-09 09:30:11 UTC (rev 2146)
+++ jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-09 12:20:10 UTC (rev 2147)
@@ -100,7 +100,7 @@
<!-- jbpm3/lib -->
<fileset dir="@{deploy.artifacts.dir}/lib" targetdir="$INSTALL_PATH/jbpm3/lib" override="true">
- <include name="jbpm-enterprise.jar" />
+ <include name="jbpm-enterprise-archive.ear" />
<include name="jbpm-core.jar" />
<include name="jbpm-identity.jar" />
<include name="activation.jar" />
@@ -160,12 +160,10 @@
<file src="@{deploy.artifacts.dir}/lib/jbpm-identity-service.zip" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar"
unpack="true" override="true" />
- <!-- jbpm/jbpm-console.war -->
- <fileset dir="@{deploy.artifacts.dir}/resources/jbpm-console" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-console.war"
- override="true">
- <exclude name="WEB-INF/lib/jbpm-jpdl-core-*.jar" />
- <exclude name="WEB-INF/lib/jbpm-jpdl-identity-*.jar" />
- </fileset>
+ <!-- jbpm/jbpm-enterprise.ear -->
+ <file src="@{deploy.artifacts.dir}/lib/jbpm-enterprise-archive.zip" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-enterprise-archive.ear"
+ unpack="true" override="true">
+ </file>
<!-- jbpm/jbpm-userguide.war -->
<file src="@{deploy.artifacts.dir}/lib/jbpm-userguide.zip" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-userguide.war"
Copied: jbpm3/trunk/modules/enterprise/ear/pom.xml (from rev 2146, jbpm3/trunk/modules/enterprise/pom.xml)
===================================================================
--- jbpm3/trunk/modules/enterprise/ear/pom.xml (rev 0)
+++ jbpm3/trunk/modules/enterprise/ear/pom.xml 2008-09-09 12:20:10 UTC (rev 2147)
@@ -0,0 +1,102 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+ <!-- ====================================================================== -->
+ <!-- -->
+ <!-- JBoss, the OpenSource J2EE webOS -->
+ <!-- -->
+ <!-- Distributable under LGPL license. -->
+ <!-- See terms of license at http://www.gnu.org. -->
+ <!-- -->
+ <!-- ====================================================================== -->
+
+ <!-- $Id$ -->
+<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>JBoss jBPM - Enterprise Archive</name>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-enterprise-archive</artifactId>
+ <packaging>ear</packaging>
+
+ <!-- Parent -->
+ <parent>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-enterprise</artifactId>
+ <version>3.3.0-SNAPSHOT</version>
+ </parent>
+
+ <!-- Dependencies -->
+ <dependencies>
+ <!-- jBPM Dependencies -->
+ <dependency>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-enterprise-beans</artifactId>
+ <version>${version}</version>
+ <type>ejb</type>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-console</artifactId>
+ <version>${version}</version>
+ <type>war</type>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-core</artifactId>
+ <version>${version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>bsh</groupId>
+ <artifactId>bsh</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>dom4j</groupId>
+ <artifactId>dom4j</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.ant</groupId>
+ <artifactId>ant</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.jackrabbit</groupId>
+ <artifactId>jackrabbit-core</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ </dependencies>
+
+ <!-- Plugins -->
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-ear-plugin</artifactId>
+ <configuration>
+ <generateApplicationXml>true</generateApplicationXml>
+ <version>1.4</version>
+ <modules>
+ <jarModule>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-core</artifactId>
+ </jarModule>
+ <ejbModule>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-enterprise-beans</artifactId>
+ </ejbModule>
+ <webModule>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-console</artifactId>
+ <contextRoot>/jbpm-console</contextRoot>
+ <unpack>true</unpack>
+ </webModule>
+ </modules>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+
+</project>
Copied: jbpm3/trunk/modules/enterprise/jar/pom.xml (from rev 2146, jbpm3/trunk/modules/enterprise/pom.xml)
===================================================================
--- jbpm3/trunk/modules/enterprise/jar/pom.xml (rev 0)
+++ jbpm3/trunk/modules/enterprise/jar/pom.xml 2008-09-09 12:20:10 UTC (rev 2147)
@@ -0,0 +1,201 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+ <!-- ====================================================================== -->
+ <!-- -->
+ <!-- JBoss, the OpenSource J2EE webOS -->
+ <!-- -->
+ <!-- Distributable under LGPL license. -->
+ <!-- See terms of license at http://www.gnu.org. -->
+ <!-- -->
+ <!-- ====================================================================== -->
+
+ <!-- $Id$ -->
+<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>JBoss jBPM - Enterprise Beans</name>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-enterprise-beans</artifactId>
+ <packaging>ejb</packaging>
+
+ <!-- Parent -->
+ <parent>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-enterprise</artifactId>
+ <version>3.3.0-SNAPSHOT</version>
+ </parent>
+
+ <!-- Dependencies -->
+ <dependencies>
+ <!-- jBPM Dependencies -->
+ <dependency>
+ <groupId>org.jboss.jbpm</groupId>
+ <artifactId>jbpm-core</artifactId>
+ <version>${version}</version>
+ </dependency>
+
+ <!-- Provided Dependencies -->
+ <dependency>
+ <groupId>javax.ejb</groupId>
+ <artifactId>ejb-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.jms</groupId>
+ <artifactId>jms</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate</artifactId>
+ <scope>provided</scope>
+ </dependency>
+
+ <!-- Test Dependencies -->
+ <dependency>
+ <groupId>org.apache.cactus</groupId>
+ <artifactId>cactus.core.framework.wrapper.javaEE.14</artifactId>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <artifactId>org.mortbay.jetty</artifactId>
+ <groupId>org.mortbay.jetty</groupId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.client</groupId>
+ <artifactId>jbossall-client</artifactId>
+ <!-- verify that this version works for all target containers -->
+ <version>4.2.2.GA</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.cactus</groupId>
+ <artifactId>cactus.integration.shared.api</artifactId>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <artifactId>org.mortbay.jetty</artifactId>
+ <groupId>org.mortbay.jetty</groupId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ </dependencies>
+
+ <!-- Plugins -->
+ <build>
+ <testResources>
+ <testResource>
+ <directory>src/test/resources</directory>
+ <filtering>true</filtering>
+ </testResource>
+ </testResources>
+ <plugins>
+ <plugin>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>build-test-jars</id>
+ <phase>test-compile</phase>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ <configuration>
+ <tasks>
+ <property name="tests.output.dir" value="${project.build.directory}" />
+ <property name="tests.resources.dir" value="${basedir}/src/test/resources" />
+ <ant antfile="scripts/antrun-test-jars.xml" target="build-test-jars" />
+ </tasks>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>assembly-config</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <finalName>${project.build.finalName}</finalName>
+ <appendAssemblyId>true</appendAssemblyId>
+ <descriptors>
+ <descriptor>scripts/assembly-config.xml</descriptor>
+ </descriptors>
+ </configuration>
+ </execution>
+ <execution>
+ <id>assembly-test-dependencies</id>
+ <phase>generate-test-resources</phase>
+ <goals>
+ <goal>directory-single</goal>
+ </goals>
+ <configuration>
+ <finalName>test-dependencies</finalName>
+ <ignoreDirFormatExtensions>true</ignoreDirFormatExtensions>
+ <appendAssemblyId>false</appendAssemblyId>
+ <descriptors>
+ <descriptor>scripts/assembly-test-dependencies.xml</descriptor>
+ </descriptors>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <showDeprecation>false</showDeprecation>
+ </configuration>
+ </plugin>
+ <plugin>
+ <artifactId>maven-jar-plugin</artifactId>
+ <configuration>
+ <excludes>
+ <exclude>jbpm.cfg.xml</exclude>
+ <exclude>hibernate.*</exclude>
+ </excludes>
+ </configuration>
+ </plugin>
+ <plugin>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <excludes>
+ <!-- https://jira.jboss.org/jira/browse/JBPM-1708 -->
+ <exclude>org/jbpm/scheduler/ejbtimer/EjbSchedulerTest.java</exclude>
+ <!-- https://jira.jboss.org/jira/browse/JBPM-1709 -->
+ <exclude>org/jbpm/msg/jms/AsyncProcessingTest.java</exclude>
+ </excludes>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <!-- Profiles -->
+ <profiles>
+ <!--
+ Name: no-jboss-bind-address Descr: Set the default jboss.bind.address command line cannot overwrite pom properties
+ http://jira.codehaus.org/browse/MNG-3546
+ -->
+ <profile>
+ <id>no-jboss-bind-address</id>
+ <activation>
+ <property>
+ <name>!jboss.bind.address</name>
+ </property>
+ </activation>
+ <properties>
+ <jboss.bind.address>localhost</jboss.bind.address>
+ </properties>
+ </profile>
+ </profiles>
+
+</project>
Copied: jbpm3/trunk/modules/enterprise/jar/scripts (from rev 2146, jbpm3/trunk/modules/enterprise/scripts)
Copied: jbpm3/trunk/modules/enterprise/jar/src (from rev 2146, jbpm3/trunk/modules/enterprise/src)
Modified: jbpm3/trunk/modules/enterprise/pom.xml
===================================================================
--- jbpm3/trunk/modules/enterprise/pom.xml 2008-09-09 09:30:11 UTC (rev 2146)
+++ jbpm3/trunk/modules/enterprise/pom.xml 2008-09-09 12:20:10 UTC (rev 2147)
@@ -1,23 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!-- ====================================================================== -->
-<!-- -->
-<!-- JBoss, the OpenSource J2EE webOS -->
-<!-- -->
-<!-- Distributable under LGPL license. -->
-<!-- See terms of license at http://www.gnu.org. -->
-<!-- -->
-<!-- ====================================================================== -->
+ <!-- ====================================================================== -->
+ <!-- -->
+ <!-- JBoss, the OpenSource J2EE webOS -->
+ <!-- -->
+ <!-- Distributable under LGPL license. -->
+ <!-- See terms of license at http://www.gnu.org. -->
+ <!-- -->
+ <!-- ====================================================================== -->
-<!-- $Id$ -->
+ <!-- $Id$ -->
<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>JBoss jBPM - Enterprise</name>
<groupId>org.jboss.jbpm</groupId>
<artifactId>jbpm-enterprise</artifactId>
- <packaging>jar</packaging>
-
+ <packaging>pom</packaging>
+
<!-- Parent -->
<parent>
<groupId>org.jboss.jbpm</groupId>
@@ -25,180 +25,10 @@
<version>3.3.0-SNAPSHOT</version>
</parent>
- <!-- Dependencies -->
- <dependencies>
- <!-- jBPM Dependencies -->
- <dependency>
- <groupId>org.jboss.jbpm</groupId>
- <artifactId>jbpm-core</artifactId>
- <version>${version}</version>
- </dependency>
-
- <!-- Provided Dependencies -->
- <dependency>
- <groupId>javax.ejb</groupId>
- <artifactId>ejb-api</artifactId>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>javax.jms</groupId>
- <artifactId>jms</artifactId>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>commons-logging</groupId>
- <artifactId>commons-logging</artifactId>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>org.hibernate</groupId>
- <artifactId>hibernate</artifactId>
- <scope>provided</scope>
- </dependency>
-
- <!-- Test Dependencies -->
- <dependency>
- <groupId>org.apache.cactus</groupId>
- <artifactId>cactus.core.framework.wrapper.javaEE.14</artifactId>
- <scope>test</scope>
- <exclusions>
- <exclusion>
- <artifactId>org.mortbay.jetty</artifactId>
- <groupId>org.mortbay.jetty</groupId>
- </exclusion>
- </exclusions>
- </dependency>
- <dependency>
- <groupId>org.jboss.client</groupId>
- <artifactId>jbossall-client</artifactId>
- <!-- verify that this version works for all target containers -->
- <version>4.2.2.GA</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.cactus</groupId>
- <artifactId>cactus.integration.shared.api</artifactId>
- <scope>test</scope>
- <exclusions>
- <exclusion>
- <artifactId>org.mortbay.jetty</artifactId>
- <groupId>org.mortbay.jetty</groupId>
- </exclusion>
- </exclusions>
- </dependency>
- </dependencies>
-
- <!-- Plugins -->
- <build>
- <testResources>
- <testResource>
- <directory>src/test/resources</directory>
- <filtering>true</filtering>
- </testResource>
- </testResources>
- <plugins>
- <plugin>
- <artifactId>maven-antrun-plugin</artifactId>
- <executions>
- <execution>
- <id>build-test-jars</id>
- <phase>test-compile</phase>
- <goals>
- <goal>run</goal>
- </goals>
- <configuration>
- <tasks>
- <property name="tests.output.dir" value="${project.build.directory}" />
- <property name="tests.resources.dir" value="${basedir}/src/test/resources" />
- <ant antfile="scripts/antrun-test-jars.xml" target="build-test-jars" />
- </tasks>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <artifactId>maven-assembly-plugin</artifactId>
- <executions>
- <execution>
- <id>assembly-config</id>
- <phase>package</phase>
- <goals>
- <goal>single</goal>
- </goals>
- <configuration>
- <finalName>${project.build.finalName}</finalName>
- <appendAssemblyId>true</appendAssemblyId>
- <descriptors>
- <descriptor>scripts/assembly-config.xml</descriptor>
- </descriptors>
- </configuration>
- </execution>
- <execution>
- <id>assembly-test-dependencies</id>
- <phase>generate-test-resources</phase>
- <goals>
- <goal>directory-single</goal>
- </goals>
- <configuration>
- <finalName>test-dependencies</finalName>
- <ignoreDirFormatExtensions>true</ignoreDirFormatExtensions>
- <appendAssemblyId>false</appendAssemblyId>
- <descriptors>
- <descriptor>scripts/assembly-test-dependencies.xml</descriptor>
- </descriptors>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <showDeprecation>false</showDeprecation>
- </configuration>
- </plugin>
- <plugin>
- <artifactId>maven-jar-plugin</artifactId>
- <configuration>
- <excludes>
- <exclude>jbpm.cfg.xml</exclude>
- <exclude>hibernate.*</exclude>
- </excludes>
- </configuration>
- </plugin>
- <plugin>
- <artifactId>maven-surefire-plugin</artifactId>
- <configuration>
- <excludes>
- <!-- https://jira.jboss.org/jira/browse/JBPM-1708 -->
- <exclude>org/jbpm/scheduler/ejbtimer/EjbSchedulerTest.java</exclude>
- <!-- https://jira.jboss.org/jira/browse/JBPM-1709 -->
- <exclude>org/jbpm/msg/jms/AsyncProcessingTest.java</exclude>
- </excludes>
- </configuration>
- </plugin>
- </plugins>
- </build>
+ <!-- Modules -->
+ <modules>
+ <module>jar</module>
+ <module>ear</module>
+ </modules>
- <!-- Profiles -->
- <profiles>
- <!--
- Name: no-jboss-bind-address
- Descr: Set the default jboss.bind.address
-
- command line cannot overwrite pom properties
- http://jira.codehaus.org/browse/MNG-3546
- -->
- <profile>
- <id>no-jboss-bind-address</id>
- <activation>
- <property>
- <name>!jboss.bind.address</name>
- </property>
- </activation>
- <properties>
- <jboss.bind.address>localhost</jboss.bind.address>
- </properties>
- </profile>
- </profiles>
-
</project>
17 years, 7 months
JBoss JBPM SVN: r2146 - jbpm3/trunk/modules/enterprise.
by do-not-reply@jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2008-09-09 05:30:11 -0400 (Tue, 09 Sep 2008)
New Revision: 2146
Modified:
jbpm3/trunk/modules/enterprise/pom.xml
Log:
Restore enterprise test excludes. Tests are still failing
Modified: jbpm3/trunk/modules/enterprise/pom.xml
===================================================================
--- jbpm3/trunk/modules/enterprise/pom.xml 2008-09-09 04:27:12 UTC (rev 2145)
+++ jbpm3/trunk/modules/enterprise/pom.xml 2008-09-09 09:30:11 UTC (rev 2146)
@@ -167,6 +167,14 @@
</plugin>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <excludes>
+ <!-- https://jira.jboss.org/jira/browse/JBPM-1708 -->
+ <exclude>org/jbpm/scheduler/ejbtimer/EjbSchedulerTest.java</exclude>
+ <!-- https://jira.jboss.org/jira/browse/JBPM-1709 -->
+ <exclude>org/jbpm/msg/jms/AsyncProcessingTest.java</exclude>
+ </excludes>
+ </configuration>
</plugin>
</plugins>
</build>
17 years, 7 months
JBoss JBPM SVN: r2145 - in jbpm3/trunk/modules: distribution/scripts and 2 other directories.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2008-09-09 00:27:12 -0400 (Tue, 09 Sep 2008)
New Revision: 2145
Modified:
jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/jboss-web.xml
jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml
jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml
jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml
jbpm3/trunk/modules/enterprise/pom.xml
Log:
[JBPM-1717] disabled job executor launcher and resolved ejb and destination references in web.xml
removed jars from jbpm-console.war/WEB-INF/lib which duplicated the libraries and configuration files in jbpm-service.sar
Modified: jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/jboss-web.xml
===================================================================
--- jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/jboss-web.xml 2008-09-08 16:05:24 UTC (rev 2144)
+++ jbpm3/trunk/modules/console/src/main/webapp/WEB-INF/jboss-web.xml 2008-09-09 04:27:12 UTC (rev 2145)
@@ -21,6 +21,16 @@
<res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
<jndi-name>java:JmsXA</jndi-name>
</resource-ref>
+
+ <ejb-local-ref>
+ <ejb-ref-name>ejb/TimerEntityBean</ejb-ref-name>
+ <local-jndi-name>java:ejb/TimerEntityBean</local-jndi-name>
+ </ejb-local-ref>
+
+ <message-destination-ref>
+ <message-destination-ref-name>jms/JobQueue</message-destination-ref-name>
+ <jndi-name>queue/JbpmJobQueue</jndi-name>
+ </message-destination-ref>
==== EJB local references (end) -->
</jboss-web>
Modified: jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml
===================================================================
--- jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml 2008-09-08 16:05:24 UTC (rev 2144)
+++ jbpm3/trunk/modules/distribution/scripts/antrun-installer.xml 2008-09-09 04:27:12 UTC (rev 2145)
@@ -26,7 +26,7 @@
</replace>
</sequential>
</macrodef>
-
+
<macrodef name="macro-enable">
<attribute name="file" />
<attribute name="section" />
@@ -41,7 +41,7 @@
</replace>
</sequential>
</macrodef>
-
+
<!-- ================================================================== -->
<!-- Setup -->
<!-- ================================================================== -->
@@ -56,32 +56,32 @@
<!-- Initialization -->
<!-- ================================================================== -->
<target name="init">
-
+
<echo />
<echo message="jboss.home=${jboss.home}" />
-
+
</target>
<!-- ================================================================== -->
<!-- Configuration -->
<!-- ================================================================== -->
<target name="configure" depends="init">
-
+
<property name="hsqldb.cfg.xml" value="${deploy.artifacts.resources}/jbpm-core-config/hibernate.cfg.hsqldb.xml"/>
<macro-disable file="${hsqldb.cfg.xml}" section="JDBC connection properties"/>
<macro-enable file="${hsqldb.cfg.xml}" section="DataSource properties"/>
<macro-enable file="${hsqldb.cfg.xml}" section="JTA transaction properties"/>
-
+
<property name="mysql.cfg.xml" value="${deploy.artifacts.resources}/jbpm-core-config/hibernate.cfg.mysql.xml"/>
<macro-disable file="${mysql.cfg.xml}" section="JDBC connection properties"/>
<macro-enable file="${mysql.cfg.xml}" section="DataSource properties"/>
<macro-enable file="${mysql.cfg.xml}" section="JTA transaction properties"/>
-
+
<property name="postgresql.cfg.xml" value="${deploy.artifacts.resources}/jbpm-core-config/hibernate.cfg.postgresql.xml"/>
<macro-disable file="${postgresql.cfg.xml}" section="JDBC connection properties"/>
<macro-enable file="${postgresql.cfg.xml}" section="DataSource properties"/>
<macro-enable file="${postgresql.cfg.xml}" section="JTA transaction properties"/>
-
+
<condition property="database.is.hsqldb" value="true" else="false">
<equals arg1="${database}" arg2="hsqldb"/>
</condition>
@@ -91,13 +91,20 @@
<condition property="database.is.postgresql" value="true" else="false">
<equals arg1="${database}" arg2="postgresql"/>
</condition>
+
+ <property name="web.xml" value="${deploy.artifacts.resources}/jbpm-console/WEB-INF/web.xml"/>
+ <macro-disable file="${web.xml}" section="Job executor launcher"/>
+ <macro-enable file="${web.xml}" section="EJB local references"/>
+
+ <macro-enable file="${deploy.artifacts.resources}/jbpm-console/WEB-INF/jboss-web.xml"
+ section="EJB local references"/>
</target>
-
+
<!-- ================================================================== -->
<!-- Distribution -->
<!-- ================================================================== -->
<target name="build-installer" depends="configure">
-
+
<copy todir="${filtered.resources.dir}" filtering="true" overwrite="true">
<fileset dir="${resources.dir}/installer" />
<filterset>
@@ -122,9 +129,8 @@
<!-- http://jira.codehaus.org/browse/IZPACK-151 -->
<copy file="${deploy.artifacts.lib}/jbpm-core-config.jar" tofile="${deploy.artifacts.lib}/jbpm-core-config.zip" />
- <copy file="${deploy.artifacts.lib}/jbpm-console.war" tofile="${deploy.artifacts.lib}/jbpm-console.zip" />
<copy file="${deploy.artifacts.lib}/jbpm-userguide.jdocbook" tofile="${deploy.artifacts.lib}/jbpm-userguide.zip" />
-
+
<!-- Run installer build -->
<echo message="Running IzPack to build the installer..." />
<izpack input="${resources.dir}/installer/install-definition.xml" output="${output.dir}/${product.short.name}-${product.version}-izpack.jar"
Modified: jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml
===================================================================
--- jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml 2008-09-08 16:05:24 UTC (rev 2144)
+++ jbpm3/trunk/modules/distribution/scripts/assembly-deploy-artifacts.xml 2008-09-09 04:27:12 UTC (rev 2145)
@@ -41,6 +41,14 @@
</includes>
<unpack>false</unpack>
</dependencySet>
+ <dependencySet>
+ <outputDirectory>resources/jbpm-console</outputDirectory>
+ <useStrictFiltering>true</useStrictFiltering>
+ <includes>
+ <include>*:jbpm-console:war</include>
+ </includes>
+ <unpack>true</unpack>
+ </dependencySet>
</dependencySets>
<fileSets>
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-08 16:05:24 UTC (rev 2144)
+++ jbpm3/trunk/modules/distribution/src/main/resources/installer/install-definition.xml 2008-09-09 04:27:12 UTC (rev 2145)
@@ -10,9 +10,11 @@
<uninstaller name="remove.task" write="yes" />
</info>
<guiprefs width="600" height="480" resizable="no">
+ <!--
<laf name="kunststoff">
<os family="unix" />
</laf>
+ -->
</guiprefs>
<locale>
<langpack iso3="eng" />
@@ -33,14 +35,14 @@
<res id="userInputSpec.xml" src="@{filtered.resources.dir}/user-input-spec.xml" />
<res id="TargetPanel.dir" src="@{filtered.resources.dir}/target-panel-dir.txt" />
</resources>
-
+
<!-- Variables -->
<variables>
<variable name="jboss422.home" value="@{jboss422.home}" />
<variable name="jboss423.home" value="@{jboss423.home}" />
<variable name="jboss500.home" value="@{jboss500.home}" />
</variables>
-
+
<!-- Dynamic Variables -->
<dynamicvariables>
<variable name="jboss.home" value="${jboss422.home}" condition="isJBoss422" />
@@ -49,7 +51,7 @@
<variable name="installPath" value="$INSTALL_PATH/jboss-4.2.2.GA" condition="isJBoss422Download" />
<variable name="jbossTargetServer" value="default" condition="isJBoss422Download" />
</dynamicvariables>
-
+
<!-- Conditions -->
<conditions>
<condition type="packselection" id="isJBoss422Download">
@@ -68,7 +70,7 @@
<value>jboss500</value>
</condition>
</conditions>
-
+
<!-- Panels -->
<panels>
<panel classname="HelloPanel" />
@@ -81,27 +83,26 @@
<panel classname="FinishPanel" />
<!-- http://jira.codehaus.org/browse/IZPACK-154 -->
</panels>
-
+
<!-- Packs -->
<packs>
<!-- jBPM3 Standalone -->
<pack name="jBPM3 Standalone" required="yes" preselected="yes">
<description>The jBPM3 Standalone Components</description>
-
+
<!-- jbpm3/config -->
<file src="@{deploy.artifacts.dir}/lib/jbpm-core-config.zip" targetdir="$INSTALL_PATH/jbpm3/config"
unpack="true" override="true" />
-
+
<!-- jbpm3/docs -->
<file src="@{deploy.artifacts.dir}/lib/jbpm-userguide.zip" targetdir="$INSTALL_PATH/jbpm3/docs/userguide"
unpack="true" override="true" />
-
+
<!-- jbpm3/lib -->
<fileset dir="@{deploy.artifacts.dir}/lib" targetdir="$INSTALL_PATH/jbpm3/lib" override="true">
<include name="jbpm-enterprise.jar" />
<include name="jbpm-core.jar" />
<include name="jbpm-identity.jar" />
-
<include name="activation.jar" />
<include name="antlr.jar" />
<include name="asm.jar" />
@@ -113,42 +114,42 @@
<include name="hibernate.jar" />
<include name="hsqldb.jar" />
</fileset>
-
+
<!-- jbpm3/src -->
<fileset dir="@{deploy.artifacts.dir}/src" targetdir="$INSTALL_PATH/jbpm3/src" override="true">
<include name="jbpm-core-sources.jar" />
<include name="jbpm-identity-sources.jar" />
</fileset>
</pack>
-
+
<!-- Optional Downloads -->
<pack name="Optional Downloads" required="no" preselected="no">
<description>Optional jBPM3 Downloads</description>
</pack>
-
+
<!-- JBoss-4.2.2 -->
<pack name="Download JBoss-4.2.2" required="no" parent="Optional Downloads" preselected="no">
<description>Download and Install JBoss-4.2.2</description>
<!-- http://jira.codehaus.org/browse/IZPACK-158 -->
<file src="@{resources.dir}/installer/download-helper.xml" targetdir="$INSTALL_PATH/Uninstaller"/>
</pack>
-
+
<!-- Eclipse-3.4.0 -->
<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"/>
</pack>
-
+
<!-- jBPM3 Server Components -->
<pack name="jBPM3 Server Components" required="yes" preselected="yes">
<description>The jBPM3 Server Components</description>
-
+
<!-- jbpm -->
<fileset dir="@{deploy.artifacts.dir}/lib" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm" override="true">
<include name="jbpm-enterprise.jar" />
</fileset>
-
+
<!-- jbpm/jbpm-service.sar -->
<fileset dir="@{deploy.artifacts.dir}/lib" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar"
override="true">
@@ -158,22 +159,25 @@
<file src="@{deploy.artifacts.dir}/resources/jbpm-enterprise-config/jbpm.cfg.xml" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar" />
<file src="@{deploy.artifacts.dir}/lib/jbpm-identity-service.zip" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar"
unpack="true" override="true" />
-
+
<!-- jbpm/jbpm-console.war -->
- <file src="@{deploy.artifacts.dir}/lib/jbpm-console.zip" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-console.war"
- unpack="true" override="true" />
-
+ <fileset dir="@{deploy.artifacts.dir}/resources/jbpm-console" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-console.war"
+ override="true">
+ <exclude name="WEB-INF/lib/jbpm-jpdl-core-*.jar" />
+ <exclude name="WEB-INF/lib/jbpm-jpdl-identity-*.jar" />
+ </fileset>
+
<!-- jbpm/jbpm-userguide.war -->
<file src="@{deploy.artifacts.dir}/lib/jbpm-userguide.zip" targetdir="${installPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-userguide.war"
unpack="true" override="true" />
-
+
</pack>
<!-- jBPM Databases -->
<pack name="jBPM3 Databases" required="no" preselected="no">
<description>The jBPM3 Supported Databases.</description>
</pack>
-
+
<!-- jBPM Hypersonic Database -->
<pack name="jBPM3 Hypersonic Database" required="no" parent="jBPM3 Databases" preselected="yes">
<description>The Hypersonic Database</description>
Modified: jbpm3/trunk/modules/enterprise/pom.xml
===================================================================
--- jbpm3/trunk/modules/enterprise/pom.xml 2008-09-08 16:05:24 UTC (rev 2144)
+++ jbpm3/trunk/modules/enterprise/pom.xml 2008-09-09 04:27:12 UTC (rev 2145)
@@ -167,12 +167,6 @@
</plugin>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
- <configuration>
- <excludes>
- <!-- https://jira.jboss.org/jira/browse/JBPM-1717 -->
- <exclude>org/jbpm/msg/jms/AsyncProcessingTest.java</exclude>
- </excludes>
- </configuration>
</plugin>
</plugins>
</build>
17 years, 7 months