[
http://jira.jboss.com/jira/browse/JBPM-1324?page=all ]
Thomas Diesler updated JBPM-1324:
---------------------------------
Description:
Support prepareForShutdown and cancelShutdown on the ProcessEngine.
public void testCreateProcess() throws Exception
{
// Create a Process through the ProcessManager
ProcessManager pm = ProcessManager.locateProcessManager();
assertNotNull("ProcessDefinition expected", pm.createProcess(jpdlURL));
// Try to create a ProcessDefinition during shutdown
try
{
engine.prepareForShutdown();
pm.createProcess(jpdlURL);
}
catch (EngineShutdownException ex)
{
assertEquals("Cannot create new Process while engine is shutting down",
ex.getMessage());
}
}
was:
Support prepareForShutdown and cancelShutdown on the ProcessEngine.
/**
* Try to create a Execution during shutdown
*/
public void testCreateExecution() throws Exception
{
// Create a ProcessDefinition through the ProcessDefinitionManager
ProcessDefinitionManager pdm =
ProcessDefinitionManager.locateProcessDefinitionManager();
ProcessDefinition pd = pdm.createProcessDefinition(jpdl);
assertNotNull("Execution expected", pd.createExecution());
// Try to create a Execution during shutdown
try
{
ProcessInstance pinst = pd.createProcessInstance();
engine.prepareForShutdown();
pinst.createExecution();
}
catch (EngineShutdownException ex)
{
assertEquals("Cannot create new Execution while engine is shutting down",
ex.getMessage());
}
}
Engine Shutdown
---------------
Key: JBPM-1324
URL:
http://jira.jboss.com/jira/browse/JBPM-1324
Project: JBoss jBPM
Issue Type: Task
Security Level: Public(Everyone can see)
Components: API
Reporter: Thomas Diesler
Assigned To: Thomas Diesler
Fix For: API 1.0.0.Alpha
Support prepareForShutdown and cancelShutdown on the ProcessEngine.
public void testCreateProcess() throws Exception
{
// Create a Process through the ProcessManager
ProcessManager pm = ProcessManager.locateProcessManager();
assertNotNull("ProcessDefinition expected", pm.createProcess(jpdlURL));
// Try to create a ProcessDefinition during shutdown
try
{
engine.prepareForShutdown();
pm.createProcess(jpdlURL);
}
catch (EngineShutdownException ex)
{
assertEquals("Cannot create new Process while engine is shutting down",
ex.getMessage());
}
}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira