[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-10-01 Thread sebastian.s
It seems strange to me that are just a few people interested in this topic 
although the situation described seems to me very common. Are there still so 
few people working with 4.x or has nobody run across the problem? If you have 
it would be great to count on your vote in JIRA.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4258123#4258123

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4258123
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-10-01 Thread sebastian.s
*push*

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4258246#4258246

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4258246
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-30 Thread sebastian.s
I'd really like having some feedback on this since for me questions arise:

- Is this behaviour just not desired from my point of view but conform to the 
processs excecution model in jBPM?

- Is this a bug since there is a task in somebody's task list which cannot be 
completed nor deleted? It cannot be deleted since tasks which belong to an 
execution cannot be deleted and it cannot be completed since the execution it 
belongs to does not exist anymore.

Or am I completely wrong?

Thanks in advance!
 

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257848#4257848

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257848
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-30 Thread kukeltje
Hmmm I thought I already responded.

To me it is a bug, but others might think not so (not sure what their arguments 
would be).

please file a jira issue, I do not seem to be able to find one

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257894#4257894

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257894
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-30 Thread sebastian.s
Here we go:

https://jira.jboss.org/jira/browse/JBPM-2559

I did not write a lot since there is a link to the forum post and I supplied a 
process definition and the unit test.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257963#4257963

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257963
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-30 Thread kukeltje
Thanks and sorry... while I was reading your jira issue I DID find the other 
one (not sure why it did not show up earlier)

https://jira.jboss.org/jira/browse/JBPM-2537

So I'll close yours as a duplicate. Again, sorry

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257968#4257968

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257968
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-30 Thread sebastian.s
No problem, I did not succeed either in finding it on JIRA. Forgot to mention I 
tried searching JIRA.  Thanks for your effort. I really hope this will be fixed 
in 4.2.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257978#4257978

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257978
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-30 Thread kukeltje
hmm... JBPM-2537 is targeted at 4.3, I saw you added your vote to it. Great now 
gather others to do the same to increase the chance of it getting fixed quicker 
-;)

I'm not sure what the default behaviour in jBPM 3 is, if that is to end 
(cancel) the task, the same should happen here, without having it configurable. 
Doing just that should not be to difficult I think and that might be targeted 
at 4.2 maybe... just raise your voice a little 

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257981#4257981

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257981
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-30 Thread sebastian.s
I commented on this again since I consider this really important because at the 
moment it makes you change your process model for escalations which is probably 
not wanted. If this was possible in 3.x this would also lead to problems when 
migrating from 3.x to 4.x, right?

Regarding the behaviour in 3.x Joram stated in the comments answering your 
question:

anonymous wrote : 
  | The most logical is not necessarily what was in 3 ;-)
  | 
  | But you are right: in 3, the task is kept open, but it can't be completed 
anymore. The only option is than to delete the task. Imo, this makes sense.
  | 

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4258038#4258038

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4258038
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-29 Thread sebastian.s
I don't manage to turn up the loglevel. Any hints?

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257632#4257632

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257632
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-29 Thread tom.baey...@jboss.com
configuration file looks good.

maybe you have multiple logging.properties files on your classpath.  check that 
you have only one.

another thing that you can do when you are in your ide is put this text in your 
Display window:

org.hsqldb.util.DatabaseManager.main(new String[]{})
  | 

select it and then press SHIFT+ALT+D  if you're using the hsqldb in memory db 
then you can inspect live during your debug session.  (be carful with closing 
the database manager as it will close your whole test run)

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257660#4257660

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257660
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-29 Thread sebastian.s
Okay, thanks for all the hints. It was really due to a classpath problem. 

Here's what I found:

Logging and using Tom's hint with the DBManager showed that there was a query 
for an execution which did not exist anymore. Before the executing of the job 
(transition with timer to task escalation) there are 2 entries in the 
Execution Table. One is escalation.1 and the second is 
escalation.1-timeout. After the transition to escalation 
escalation.1-timeout gets deleted, execution.1 is active again and when you try 
to complete the task timeout which is still in the tasklist you get the 
Exception because the associated execution cannot be found.

(I did not post logs since there cannot be seen really a lot and they get very 
large with a higher loglevel set.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257701#4257701

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257701
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-28 Thread kukeltje
there was a change in the businesscalendar config afaik between 4.0, and 4.1 
(or was it towards 4.2, not fully sure). Did you change versions? If so, search 
the jira for the related task and see if it is the possible cause.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257243#4257243

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257243
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-28 Thread sebastian.s
I'll have a look into JIRA and I will verify that I am not mixing up files from 
different versions. But what about my actual problem (see my last post). How do 
I get rid of the task which is not needed anymore?

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257247#4257247

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257247
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-28 Thread sebastian.s
Full Stacktrace ..


  | ### EXCEPTION ###
  | 11:00:39,186 INF | [DefaultCommandService] exception while executing 
command org.jbpm.pvm.internal.cmd.completetask...@1c01ba9
  | org.hibernate.ObjectNotFoundException: No row with the given identifier 
exists: [org.jbpm.pvm.internal.model.ExecutionImpl#2]
  | at 
org.hibernate.impl.SessionFactoryImpl$2.handleEntityNotFound(SessionFactoryImpl.java:409)
  | at 
org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:108)
  | at 
org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:97)
  | at 
org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:140)
  | at 
org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
  | at 
org.jbpm.pvm.internal.model.ExecutionImpl_$$_javassist_4.getHistoryActivityInstanceDbid(ExecutionImpl_$$_javassist_4.java)
  | at 
org.jbpm.pvm.internal.history.events.TaskComplete.process(TaskComplete.java:49)
  | at 
org.jbpm.pvm.internal.history.HistorySessionImpl.process(HistorySessionImpl.java:31)
  | at org.jbpm.pvm.internal.history.HistoryEvent.fire(HistoryEvent.java:61)
  | at 
org.jbpm.pvm.internal.task.TaskImpl.historyTaskComplete(TaskImpl.java:305)
  | at org.jbpm.pvm.internal.task.TaskImpl.complete(TaskImpl.java:190)
  | at org.jbpm.pvm.internal.task.TaskImpl.complete(TaskImpl.java:186)
  | at 
org.jbpm.pvm.internal.cmd.CompleteTaskCmd.execute(CompleteTaskCmd.java:58)
  | at 
org.jbpm.pvm.internal.cmd.CompleteTaskCmd.execute(CompleteTaskCmd.java:32)
  | at 
org.jbpm.pvm.internal.svc.DefaultCommandService.execute(DefaultCommandService.java:42)
  | at 
org.jbpm.pvm.internal.tx.StandardTransactionInterceptor.execute(StandardTransactionInterceptor.java:54)
  | at 
org.jbpm.pvm.internal.svc.EnvironmentInterceptor.execute(EnvironmentInterceptor.java:46)
  | at 
org.jbpm.pvm.internal.svc.RetryInterceptor.execute(RetryInterceptor.java:55)
  | at 
org.jbpm.pvm.internal.svc.TaskServiceImpl.completeTask(TaskServiceImpl.java:88)
  | at 
org.jbpm.examples.userescalation.EscalationTest.testTaskEscalaton(EscalationTest.java:70)
  | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  | at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
  | at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
  | at java.lang.reflect.Method.invoke(Method.java:597)
  | at junit.framework.TestCase.runTest(TestCase.java:164)
  | at org.jbpm.test.BaseJbpmTestCase.runTest(BaseJbpmTestCase.java:80)
  | at junit.framework.TestCase.runBare(TestCase.java:130)
  | at junit.framework.TestResult$1.protect(TestResult.java:106)
  | at junit.framework.TestResult.runProtected(TestResult.java:124)
  | at junit.framework.TestResult.run(TestResult.java:109)
  | at junit.framework.TestCase.run(TestCase.java:120)
  | at junit.framework.TestSuite.runTest(TestSuite.java:230)
  | at junit.framework.TestSuite.run(TestSuite.java:225)
  | at 
org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
  | at 
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
  | at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
  | at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
  | at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
  | at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
  | ### EXCEPTION ###
  | 11:00:39,186 SEV | [BaseJbpmTestCase] 
  | ### EXCEPTION ###
  | 11:00:39,186 SEV | [BaseJbpmTestCase] TEST THROWS EXCEPTION: No row with 
the given identifier exists: [org.jbpm.pvm.internal.model.ExecutionImpl#2]
  | org.hibernate.ObjectNotFoundException: No row with the given identifier 
exists: [org.jbpm.pvm.internal.model.ExecutionImpl#2]
  | at 
org.hibernate.impl.SessionFactoryImpl$2.handleEntityNotFound(SessionFactoryImpl.java:409)
  | at 
org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:108)
  | at 
org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:97)
  | at 
org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:140)
  | at 
org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
  | at 
org.jbpm.pvm.internal.model.ExecutionImpl_$$_javassist_4.getHistoryActivityInstanceDbid(ExecutionImpl_$$_javassist_4.java)
  | at 

[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-28 Thread kukeltje
might be because the process is actually already ended  Can you check?

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257316#4257316

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257316
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-28 Thread sebastian.s
There is an additional task to complete afterwards which I have not completed 
so the process should not be ended.   I am doing an 
assertTrue(processInstance.isActive(task2));
in the unit test and it does not fail.


View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257320#4257320

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257320
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-28 Thread kukeltje
ok, and I only now see there are 3 identical timers on the transition. Can you 
remove those and also turn up the loglevel when running the unittest.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257457#4257457

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257457
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-28 Thread sebastian.s
I am going to turn up the loglevel. The process was deployed with just one 
timer, does not change anything. The duplicate timers are due to the GPD bug 
already reported in JIRA.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257458#4257458

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257458
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-28 Thread sebastian.s
I must be doing something wrong since I don't see more in the log.


  | handlers= java.util.logging.ConsoleHandler
  | redirect.commons.logging = enabled
  | 
  | java.util.logging.ConsoleHandler.level = FINEST
  | java.util.logging.ConsoleHandler.formatter = 
org.jbpm.internal.log.LogFormatter
  | 
  | org.jbpm.level=FINEST
  | org.jbpm.pvm.internal.tx.level=FINEST
  | org.jbpm.pvm.internal.wire.level=FINEST
  | org.jbpm.pvm.internal.util.level=FINEST
  | 
  | org.hibernate.level=FINEST
  | org.hibernate.cfg.SettingsFactory.level=FINEST
  | org.hibernate.cfg.HbmBinder.level=FINEST
  | # org.hibernate.SQL.level=FINEST
  | # org.hibernate.type.level=FINEST
  | # org.hibernate.tool.hbm2ddl.SchemaExport.level=FINEST
  | org.hibernate.transaction.level=FINEST
  | 

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257461#4257461

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257461
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-27 Thread sebastian.s
I do not know what exactly is the problem with the BusinessCalendar but I 
created my process and my unit test within the examples project and the error 
has gone away. Now back to the actual goal.

Please disregard my old post since there were some mistakes and things missing.

My process definition looks like this:

  | process key=escalation name=escalation 
xmlns=http://jbpm.org/4.0/jpdl;
  |start g=130,8,48,48 name=start1
  |   transition g=-93,-21 name=to timeout_task to=timeout_task/
  |/start
  |task g=106,105,92,52 name=timeout_task assignee=alex
  |   transition g=7,-32 name=to escalated to=escalated
  |  timer duedate=5 seconds/
  |  timer duedate=5 seconds/
  |  timer duedate=5 seconds/
  |  timer duedate=5 seconds/
  |   /transition
  |   transition g=-50,-21 name=to task2 to=task2/
  |/task
  |task g=303,211,92,52 name=escalated assignee=mike
  |   transition g=-50,-21 name=to task2 to=task2/
  |/task
  |task g=109,256,92,52 name=task2 assignee=peter
  |   transition g=-48,-21 name=to end1 to=end1/
  |/task
  |end g=132,367,48,48 name=end1/
  | /process
  | 

My unit test follows:

  | package org.jbpm.examples.userescalation;
  | import java.util.List;
  | 
  | import org.jbpm.api.Execution;
  | import org.jbpm.api.ProcessInstance;
  | import org.jbpm.api.job.Job;
  | import org.jbpm.api.task.Task;
  | import org.jbpm.test.JbpmTestCase;
  | 
  | public class EscalationTest extends JbpmTestCase {
  | 
  |   String deploymentId;
  |   
  |   protected void setUp() throws Exception {
  | super.setUp();
  | 
  | deploymentId = repositoryService.createDeployment()
  | 
.addResourceFromClasspath(org/jbpm/examples/userescalation/escalation.jpdl.xml)
  | .deploy();
  |   }
  | 
  |   protected void tearDown() throws Exception {
  | repositoryService.deleteDeploymentCascade(deploymentId);
  | 
  | super.tearDown();
  |   }
  |   
  |   public void testTaskEscalaton() {
  |   
  | ProcessInstance processInstance = 
executionService.startProcessInstanceByKey(escalation);
  | 
  | ListTask tasksAlex = taskService.findPersonalTasks(alex);
  | 
  | // check if Alex's task has been created
  | if(tasksAlex.size() == 0) {
  | fail();
  | }
  | 
  | // executing the job which would normally be executed by the JobExecutor
  | Job job = managementService.createJobQuery()
  | .timers()
  | .processInstanceId(processInstance.getId())
  | .uniqueResult();
  |   
  | managementService.executeJob(job.getId());
  | processInstance = 
executionService.findProcessInstanceById(processInstance.getId());
  | 
  | // we now should have arrived in the node escalated
  | assertTrue(processInstance.isActive(escalated));
  | 
  | // there should be an item in Mike's tasklist now
  | ListTask tasksMike = taskService.findPersonalTasks(mike);
  | if(tasksMike.size() == 0) {
  | fail();
  | } else {
  | taskService.completeTask(tasksMike.get(0).getId());
  | }
  | 
  | // after Mike has completed his task we should have arrived in the node 
task2
  | processInstance = 
executionService.findProcessInstanceById(processInstance.getId());
  | assertTrue(processInstance.isActive(task2));
  | 
  | // Alex's tasks still exists although it is obsolete now
  | tasksAlex = taskService.findPersonalTasks(alex);
  | 
  | // deleting is not possible since this task belongs to an execution
  | //taskService.deleteTask(tasksAlex.get(0).getId(), obsolete);
  | 
  | // so we have to complete it, what is unwanted for BAM
  | taskService.completeTask(tasksAlex.get(0).getId());
  | 
  | // ### but this fails with an exception 
  | 
  | // there shouldn't be any tasks left for alex
  | //tasksAlex = taskService.findPersonalTasks(alex);
  | //assertEquals(0, tasksAlex.size());
  | 
  |   }
  |   
  | }
  | 

The exception thrown when completeTask() is called:

  | ### EXCEPTION ###
  | 16:19:12,140 INF | [DefaultCommandService] exception while executing 
command org.jbpm.pvm.internal.cmd.completetask...@ff45de
  | org.hibernate.ObjectNotFoundException: No row with the given identifier 
exists: [org.jbpm.pvm.internal.model.ExecutionImpl#2]
  | 

Am I doing anything wrong or does this mean you should not put timers on 
transitions coming from user tasks?

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257213#4257213

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257213
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-26 Thread sebastian.s
I must be doing something wrong. I took the unit tests of the supplied examples 
as a base (regarding configuration files) which always worked fine for and I 
created my process and my tests. The problem is that an exception is thrown:


  | 12:03:47,093 FIN | [ProcessDefinitionImpl] creating new execution for 
process 'escalation'
  | 12:03:47,109 FIN | [DefaultIdGenerator] generated execution id escalation.1
  | 12:03:47,234 FIN | [ExecuteActivity] executing activity(start1)
  | 12:03:47,250 FIN | [DefaultIdGenerator] generated execution id 
escalation.1.timeout_task
  | 12:03:47,406 FIN | [ExecutionImpl] created 
execution[escalation.1.timeout_task]
  | 12:03:47,406 FIN | [ScopeInstanceImpl] creating timer on 
execution[escalation.1.timeout_task]
  | ### EXCEPTION ###
  | 12:03:47,625 INF | [DefaultCommandService] exception while executing 
command org.jbpm.pvm.internal.cmd.startprocessinstanceinlatest...@694f12
  | org.jbpm.api.JbpmException: no org.jbpm.pvm.internal.cal.BusinessCalendar 
in current environment
  | 


  | process name=escalation xmlns=http://jbpm.org/4.0/jpdl;
  |start g=174,36,48,48 name=start1
  |   transition g=-106,-24 name=to timeout_task to=timeout_task/
  |/start
  |task assignee=alex g=152,168,92,52 name=timeout_task
  |   transition g=-50,-21 name=timeout to=escalated
  | timer duedate=5 seconds / 
  |   /transition
  |   transition g=-50,-21 name=to task2 to=task2/
  |/task
  |task assignee=mike g=352,169,92,52 name=escalated
  |   transition g=-50,-21 name=to task2 to=task2/
  |/task
  |task assignee=peter g=151,305,92,52 name=task2
  |   transition g=-48,-21 name=to end1 to=end1/
  |/task
  |end g=176,398,48,48 name=end1/   
  | /process
  | 


  |  public void testTaskEscalaton() {
  | ProcessInstance processInstance = 
executionService.startProcessInstanceByKey(escalation);
  | String processInstanceId = processInstance.getId();
  | processInstance = 
executionService.findProcessInstanceById(processInstanceId);
  | 
  | ListTask tasksAlex = taskService.findPersonalTasks(alex);
  | 
  | if(tasksAlex.size() == 0) {
  | fail();
  | }
  | 
  | Job job = managementService.createJobQuery()
  | .timers()
  | .processInstanceId(processInstance.getId())
  | .uniqueResult();
  |   
  | managementService.executeJob(job.getId());
  | processInstance = 
executionService.findProcessInstanceById(processInstance.getId());
  | assertTrue(processInstance.isActive(escalated));
  | 
  | ListTask tasksMike = taskService.findPersonalTasks(mike);
  | if(tasksMike.size() == 0) {
  | fail();
  | }
  | 
  | tasksAlex = taskService.findPersonalTasks(alex);
  | if(tasksAlex.size() == 1) {
  | taskService.completeTask(tasksAlex.get(0).getId());
  | } else {
  | fail();
  | }
  | 
  |   }
  | 

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257169#4257169

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257169
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-25 Thread kukeltje
One day late, and afternoon already since this response required a little 
digging for me :-) 

In theory you are right, escalating is a basic BPM-thing 

In practical situations howeever, escalation differs from company to company, 
department to department etc... and if you have a look at 
http://www.workflowpatterns.com/patterns/resource/detour/wrp28.php you see that 
even the theoretical people look at it from a very narrow perspective.

They say jBPM (3.1.4 ) does not support it, that is because they assume 
businesspeople should be able to to everything, and a BPM 'framework' like jBPM 
which can do much more than other products gets a '-' rating because sometimes 
you need java... sigh...

You can make it as complex as needed like in the article you refer to, but you 
can also keep it simple and just assigning  the current task to someone else on 
a timeout event.

The way it is done in the article is valid for jBPM 3 and 4 (ok different 
interfaces and jpdl changes, but the basics is the same)

jBPM 4 has a still undocumented feature (it is not even in the dev guide yet) 
which is based in the PVM. There is the concept of a task lifecycle in 
combination with the accompanying java code.

But keep in mind, it is not supported. This does not mean it does not work, 
only that there are no guarantees that it stays 100% as it is, and that I and 
other users, probably did not customize it much either so support in the forum 
is also kind of limited.

What *is* nice about this 'solution' is that jBPM eats its own dogfood (again) 
by re-using the pvm in yet another way.

(I think someone could even make a (ws-)Human Task based on this if he/she 
cares to read 100's of pages)

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257042#4257042

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257042
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-25 Thread sebastian.s
Thanks for this really long answer, Ronald. In my opinion you are right, 
escalation is a very complex thing and can mean a lot and I appreciate the 
flexibility of jBPM but maybe we should think of a basic thing to be included 
with the distro while replacing it with your own implementation is still 
possible. Enable simple escalations without the need of coding to give people a 
smooth start.

To me it is actually about a simple one right now. I would like to assign a 
task to somebody else or take a transition to a second task assigned to 
somebody else.

I managed to use a timer to make the engine take a timeout transition after 
some time. My question here: If you make the engine take the transition like 
this is the previous task completed? Or is this the wrong approach and I should 
just change the assignment of the task in jBPM?

I am thinking about the first one because business people often model 
escalations like this: There is a transition to take when the task is completed 
or a different one is taken on a timer event leading to a task assigned to 
somebody else.

If the task was marked completed when the timeout transition was taken wouldn't 
this be a bit strange for reports on processes because actually the first 
person did not complete the task but it was marked as completed?

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257059#4257059

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257059
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-25 Thread sebastian.s
Regarding the task lifecyle I have not written anything since I have not yet 
looked into this.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257061#4257061

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257061
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-25 Thread kukeltje
The European guy wrote : I managed to use a timer to make the engine take a 
timeout transition after some time. My question here: If you make the engine 
take the transition like this is the previous task completed? Or is this the 
wrong approach and I should just change the assignment of the task in jBPM?

In 3 it is ended (and configurable) in 4 it is not ended (not configurable) but 
there is a jira issue for this to make it compatible again. Reassignment is 
also an option, but that is not visible in the processdefinition then.

The European guy wrote : I am thinking about the first one because business 
people often model escalations like this: There is a transition to take when 
the task is completed or a different one is taken on a timer event leading to a 
task assigned to somebody else.
  |  Yes, me to, and this will be visualized also on the GPD once the timeout 
from BPMN comes into play

The European guy wrote : If the task was marked completed when the timeout 
transition was taken wouldn't this be a bit strange for reports on processes 
because actually the first person did not complete the task but it was marked 
as completed?

That is why the task lifecycle is so interesting since you can add an 
additional 'state' (not a node but the state of a task ;-))

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257065#4257065

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257065
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-25 Thread kukeltje
oh, in addition, in 4 the tasks remains open, also not what you want I think. 

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257066#4257066

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257066
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-25 Thread sebastian.s
Thanks for your interesting answer, Ronald. I think for know I use the 
timer/transitition approach because I need I want to visualize the escalation 
in the diagram shown in the console. So it would be necessary to call a 
completeTask() for the old task manually to remove it from the first user's 
task list.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257075#4257075

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257075
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-25 Thread kukeltje
Yes I think you do need that. Would be nice if you made a unit test first to 
test if that really works. I think it does, but not completely sure.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4257102#4257102

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4257102
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user


[jboss-user] [jBPM Users] - Re: Implementing Escalation in jBPM 4.1

2009-09-24 Thread sebastian.s
Okay, I just went over the specific part of the article again and to me it 
seems it is possible. It just seems to me that is a bit too much code for a 
basic BPM-thing as an escaltion is one.

View the original post : 
http://www.jboss.org/index.html?module=bbop=viewtopicp=4256809#4256809

Reply to the post : 
http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4256809
___
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user