I agree it's easy to create task instances at runtime and that's the way I'm
using when the implementation requires such feature. But it's a bit different... I was
talking about Task (not task instance). Also the default implementation of the Task
instance is that its properties are copied from the Task definition when it is created...
I know we don't have to follow the default implementation, JBPM is flexible enough for
that. But my point is more about the logic of domain model.
Let's take an example, I have an "Approval task node" that handles the
approval from two departments: HR and Accounting. When I design this by using the GPD, I
will create two Tasks and at runtime one Task instance will be created for each Task.
Now if I want to do this at runtime by using a rule file (or a delegation class), one way
would be to create a default Task definition for this node when designing my process and
then at runtime my rules will create two Task instances (one for HR and one for
Accounting) for the same Task definition.
For the same idea, which is 2 Tasks one for HR and one for Accounting (at least in the BA
point of view) I'm not using the same objects of my domain model to implement it.
I'm just wondering if this is ok.... ? Yes, the implementation works fine in both
cases but what if one day I'm stuck because I found out I can do some specific
reporting in one case but not in the other case since the implementation is different ?
View the original post :
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4215546#...
Reply to the post :
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&a...