Bug 1027120 - Rete tree build error with || operator
Summary: Rete tree build error with || operator
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss BRMS Platform 6
Classification: Retired
Component: Eclipse Tooling
Version: unspecified
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 6.0.0
Assignee: Mario Fusco
QA Contact: Tomas Schlosser
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-11-06 08:16 UTC by Tomas Schlosser
Modified: 2014-08-06 20:20 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-08-06 20:20:23 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker DROOLS-320 0 Major Resolved Drools plugin Rete Tree viewer does not work with timer and || operator. 2014-06-23 19:15:25 UTC

Description Tomas Schlosser 2013-11-06 08:16:26 UTC
Description of problem:
The rete tree can't be built for rules containing timer.

Version-Release number of selected component (if applicable):
BRMS 6.0.0.ER4
JBDS 7.0.1.GA
Drools plugin 6.0.0.201308222359 (and also master as of 2013-11-06)

Steps to Reproduce:
1. create a rule resource with constraints connected by || operator
2. switch rule editor to "Rete Tree"

Actual results:
Rete Tree Build Error!

Expected results:
Rete tree.

Error log from Eclipse:
java.lang.NullPointerException
	at org.drools.eclipse.reteoo.AlphaNodeVertex.getValue(AlphaNodeVertex.java:114)
	at org.drools.eclipse.editors.rete.model.VertexPropertySource.initAlphaNodeProperties(VertexPropertySource.java:296)
	at org.drools.eclipse.editors.rete.model.VertexPropertySource.initProperties(VertexPropertySource.java:186)
	at org.drools.eclipse.editors.rete.model.VertexPropertySource.<init>(VertexPropertySource.java:139)
	at org.drools.eclipse.editors.rete.part.VertexEditPart.activate(VertexEditPart.java:57)
	at org.eclipse.gef.editparts.AbstractEditPart.addChild(AbstractEditPart.java:215)
	at org.eclipse.gef.editparts.AbstractEditPart.refreshChildren(AbstractEditPart.java:781)
	at org.drools.eclipse.editors.rete.part.DiagramEditPart.propertyChange(DiagramEditPart.java:107)
	at java.beans.PropertyChangeSupport.fire(PropertyChangeSupport.java:335)
	at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:327)
	at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:263)
	at org.drools.eclipse.editors.rete.model.ModelElement.firePropertyChange(ModelElement.java:54)
	at org.drools.eclipse.editors.rete.model.ReteGraph.addChild(ReteGraph.java:47)
	at org.drools.eclipse.editors.rete.model.ReteGraph.addAll(ReteGraph.java:91)
	at org.drools.eclipse.editors.rete.ReteViewer.drawGraph(ReteViewer.java:313)
	at org.drools.eclipse.editors.DRLRuleEditor2.setFocus(DRLRuleEditor2.java:257)
	at org.eclipse.ui.part.MultiPageEditorPart.pageChange(MultiPageEditorPart.java:844)
	at org.eclipse.ui.forms.editor.FormEditor.pageChange(FormEditor.java:492)
	at org.eclipse.ui.part.MultiPageEditorPart$2.widgetSelected(MultiPageEditorPart.java:292)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:248)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1392)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1416)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1401)
	at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:1187)
	at org.eclipse.swt.custom.CTabFolder.setSelection(CTabFolder.java:3080)
	at org.eclipse.swt.custom.CTabFolder.onMouse(CTabFolder.java:1772)
	at org.eclipse.swt.custom.CTabFolder$1.handleEvent(CTabFolder.java:279)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1392)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3742)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3363)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1113)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:997)
	at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:138)
	at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:610)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:567)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:124)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:354)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:181)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:606)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:636)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1426)

Comment 1 Kris Verlaenen 2013-11-06 13:45:28 UTC
Edson, could you make sure AlphaNode.getValue() doesn't throw a NPE (it may return null if necessary).

Comment 2 Mario Fusco 2013-12-19 09:12:27 UTC
Fixed by https://github.com/droolsjbpm/droolsjbpm-tools/commit/350b1daf8

Comment 3 Edson Tirelli 2013-12-19 14:31:06 UTC
The fix is done in master. It is very low risk. Can we get a blocker+ to cherry-pick into 6.0.x?

Comment 4 Tomas Schlosser 2014-01-15 11:31:07 UTC
Verified with Drools plugin 6.0.1.Final

Comment 5 Lukáš Petrovický 2014-02-07 16:15:15 UTC
This BZ has been part of the 6.0.0 stream.

Comment 6 JBoss JIRA Server 2014-02-12 08:57:19 UTC
Mario Fusco <mario.fusco> updated the status of jira DROOLS-320 to Resolved


Note You need to log in before you can comment on or make changes to this bug.