[rules-users] Script Task BUG????

Yaniv Itzhaki iyaniv at gmail.com
Mon Oct 11 10:34:33 EDT 2010


yes, I am running a loop over my rules and flow files and call the
method kbuilder.add(ResourceFactory.newFileResource(file),
type);

my process ids are: mainFlow, phase1 and phase2


2010/10/10 Mauricio Salatino <salaboy at gmail.com>

> are you doing
> kbuilder.add(ResourceFactory.newFileResource(file), typ
>
> for each process file?
>
> you mention that you have the IDs -> (5, 31 and 33).
> Those are generated when you create a new process instance.
> but when you start your process flow with:
> ksession.startProcess(<ID here>).
> Can you share with us the IDs for the three processes?
> You can look inside the xml of the process definition (inside the process
> tag to answer that question).
> Greetings.
>
> 2010/10/10 esteban.aliverti at gmail.com <esteban.aliverti at gmail.com>
>
>> It would be possible to have a minimum maven test project so we can take a
>> look?
>>
>> Best,
>>
>> XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
>>
>> Esteban Aliverti
>> - Developer @ http://www.plugtree.com
>> - Blog @ http://ilesteban.wordpress.com
>>
>>
>> 2010/10/10 Yaniv Itzhaki <iyaniv at gmail.com>
>>
>>> What do you mean by "add all your process definition into the kbase"? I
>>> am doing the following:
>>> kbuilder.add(ResourceFactory.newFileResource(file), type);
>>>
>>> kb = KnowledgeBaseFactory.newKnowledgeBase();
>>>  kb.addKnowledgePackages(kbuilder.getKnowledgePackages());
>>>
>>>
>>> 2010/10/10 Mauricio Salatino <salaboy at gmail.com>
>>>
>>> Hi man. are you sure that you add all your process definition into the
>>>> kbase?
>>>> Sounds like all your processes have the same process ID. and you are
>>>> executing the last one only.
>>>> Greetings.
>>>>
>>>> 2010/10/10 esteban.aliverti at gmail.com <esteban.aliverti at gmail.com>
>>>>
>>>> It sounds like a bug to me. Which version of drools are you using? And
>>>>> which are the ids of the action nodes?
>>>>>
>>>>> Best,
>>>>>
>>>>> XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
>>>>>
>>>>> Esteban Aliverti
>>>>> - Developer @ http://www.plugtree.com
>>>>> - Blog @ http://ilesteban.wordpress.com
>>>>>
>>>>>
>>>>> 2010/10/10 Yaniv Itzhaki <iyaniv at gmail.com>
>>>>>
>>>>>>  Hi,
>>>>>>
>>>>>> I am experiencing a strange bug (or feature???). I added a script task
>>>>>> (name="A") in my main process which just running System.out.println("Script
>>>>>> A");
>>>>>> I also added another script task (name="B") in my sub-process which is
>>>>>> running System.out.println("Script B");
>>>>>> But, when I am running the process I get the following  output:
>>>>>> Script B
>>>>>> Script B
>>>>>>
>>>>>> I continued to test this issue and added another script
>>>>>> task (name="C") with System.out.println("Script C"); in another sub-process
>>>>>> and I get:
>>>>>> Script C
>>>>>> Script C
>>>>>> Script C
>>>>>>
>>>>>> If I add the line for every script System.out.println("Script X
>>>>>> "+context.getNodeInstance().getNodeName()) I get the following:
>>>>>>  Script C A
>>>>>> Script C B
>>>>>> Script C C
>>>>>>
>>>>>> Is it normal? how come I have this behavior???
>>>>>>
>>>>>> Yaniv
>>>>>>
>>>>>> _______________________________________________
>>>>>> rules-users mailing list
>>>>>> rules-users at lists.jboss.org
>>>>>> https://lists.jboss.org/mailman/listinfo/rules-users
>>>>>>
>>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> rules-users mailing list
>>>>> rules-users at lists.jboss.org
>>>>> https://lists.jboss.org/mailman/listinfo/rules-users
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>>  - CTO @ http://www.plugtree.com
>>>>  - MyJourney @ http://salaboy.wordpress.com
>>>>  - Co-Founder @ http://www.jbug.com.ar
>>>>
>>>>  - Salatino "Salaboy" Mauricio -
>>>>
>>>> _______________________________________________
>>>> rules-users mailing list
>>>> rules-users at lists.jboss.org
>>>> https://lists.jboss.org/mailman/listinfo/rules-users
>>>>
>>>>
>>>
>>> _______________________________________________
>>> rules-users mailing list
>>> rules-users at lists.jboss.org
>>> https://lists.jboss.org/mailman/listinfo/rules-users
>>>
>>>
>>
>> _______________________________________________
>> rules-users mailing list
>> rules-users at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/rules-users
>>
>>
>
>
> --
>  - CTO @ http://www.plugtree.com
>  - MyJourney @ http://salaboy.wordpress.com
>  - Co-Founder @ http://www.jbug.com.ar
>
>  - Salatino "Salaboy" Mauricio -
>
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20101011/6c69bac2/attachment.html 


More information about the rules-users mailing list