[
https://jira.jboss.org/jira/browse/JBRULES-1966?page=com.atlassian.jira.p...
]
Shahad Ahmed commented on JBRULES-1966:
---------------------------------------
I was testing the fixes made to the Action tasks in 5.0.0. CR1, and although the issue
appears to be fixed for the Action task, it does not appears to be fixed for the other
tasks, Human Task, Email. Log and Event Wait mentioned in the original JIRA details. In
fact things seem to have become even worse for these nodes as if you edit an existing
action in any of these tasks the edit is ignored once you close the Action Editor dialog.
My tests were made on Drools 5.0.0. CR1 under Windows XP SP3 running Eclipse Version:
3.4.1Build id: M20080911-1700, and using Sun Java JRE 1.5.0_15
To reproduce (do not use Event Wait reproduce, as it has another related bug described
further below):
1. Add a new Human Task node to a ruleflow.
2. Select the "On Entry Actions" property for the new node in the eclipse
properties pane, and open the "Edit Actions" dialog.
3. Click the Add button to open the "Action Editor". Enter some code in the
Action Editor e.g. System.out.println("Unedited"); and then click Ok to close
the Action Editor.
4. Click Ok to close the "Edit Actions" editor.
5. Save the Ruleflow file, which should be dirty at this point with a (*) beside its tab
name.
6. Select the Human Task node you just edited and then select the "On Entry
Actions" property for the node in the eclipse properties pane, and open the
"Edit Actions" dialog.
7. Click the Edit button to open the "Action Editor". Modify the existing code
in the Action Editor e.g. change the action to System.out.println("Edited"); and
then click Ok to close the Action Editor.
8. In the Edit Actions dialog you will see that the edited action will still say
System.out.println("Unedited") i.e. the change you just made has not been
applied. If you now click Ok to close the dialog the action is still set as the old value
System.out.println("Unedited"); in the eclipse properties pane, and the file has
not been marked as dirty - in other words, the edit you just made has not been
recognised.
Furthermore if you add a new action to an Event Wait node and save it, the save is not
committed to the file (this is on top of not being able to edit an existing action
described above)
To reproduce:
1. Add a new "Event Wait" task node to a ruleflow - do no add any new properties
to the new node just yet, as the order in which things are added is important.
2. Select the "On Entry Actions" property for the new node in the eclipse
properties pane, and open the "Edit Actions" dialog.
3. Click the Add button to open the "Action Editor". Enter some code in the
Action Editor e.g. System.out.println("Unedited"); and then click Ok to close
the Action Editor.
4. Click Ok to close the "Edit Actions" editor.
5. Save the Ruleflow file, which should be dirty at this point with a (*) beside its tab
name.
6. Close the ruleflow file and then reopen the file.
7. Select the Event Wait node you just edited and then select the "On Entry
Actions" property for the node in the eclipse properties pane. You will see that the
action you added previously is gone! In other words, the new action you added was not
saved in step 5.
If you first set and save the Constraint property of the "Event Wait" node
between step 1 and 2 above (i.e. before adding the On Entry Action), then the changes to
the On Entry Action is saved (i.e. the second bug above above does not occur in that
case).
Editing existing ruleflow Action node not detected as a file change
in eclipse plugin
-------------------------------------------------------------------------------------
Key: JBRULES-1966
URL:
https://jira.jboss.org/jira/browse/JBRULES-1966
Project: JBoss Drools
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: drools-eclipse, drools-eclipse (expert), drools-eclipse (flow)
Affects Versions: 5.0.0.M5
Environment: Windows XP SP3, Sun JRE 1.5
Reporter: Shahad Ahmed
Assignee: Kris Verlaenen
Fix For: 5.0.0.CR1
I've found the following bug in the Ruleflow editor within the drools 5.0M5 eclipse
plugin.
If you edit an already existing action in an Action node of a ruleflow file then the edit
is not detected as a change and the ruleflow file is not marked as dirty (i.e. no asterisk
appears beside the ruleflow file name in it's editor tab). The change is shown in the
properties tab, but is not saved to file, so that if you close the file then the change is
not saved.
The same problem occurs if you edit an existing "On Entry Actions" or "On
Exit Actions" property in the following node types: Event Wait, Human Task, Email,
Log
To reproduce:
1. Create a new ruleflow file consisting of a Start, Action and End node all connected
together - do not save the file just yet.
2. Edit the Action node and add the following action:
System.out.println("Hello");
3. Close the Action editor by clicking ok and save the ruleflow file.
4. Now open the Action node editor and edit the action to System.out.println("Hello
World"); then click ok to close the Action editor.
5. At this point the change shows up against the Action property in the eclipse
properties tab, but the Ruleflow editor tab does not show the file as changed. If you
close the file now and reopen it then the changes to the Action are lost and the Action
will still be System.out.println("Hello");
A workaround is to move a node in the ruleflow after an edit to make the Ruleflow file
dirty and then save it.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira