[jboss-jira] [JBoss JIRA] (DROOLS-758) GuidedDecisionTreeModelUnmarshallingVisitor doesn't support unmarshalling of oneline rules
Tibor Zimányi (JIRA)
issues at jboss.org
Wed Apr 8 08:47:18 EDT 2015
Tibor Zimányi created DROOLS-758:
------------------------------------
Summary: GuidedDecisionTreeModelUnmarshallingVisitor doesn't support unmarshalling of oneline rules
Key: DROOLS-758
URL: https://issues.jboss.org/browse/DROOLS-758
Project: Drools
Issue Type: Bug
Reporter: Tibor Zimányi
Assignee: Mark Proctor
Priority: Minor
Method visit() from GuidedDecisionTreeModelUnmarshallingVisitor doesn't support rules, that are written in one line. According to documentation [1] (Block 7.1.2), rule can be written without line separators. Also depending on line separators introduce problems with rules from DRL files that are written on operating systems with different line separator that is on a system where drools engine runs (this can be seen running GuidedDecisionTreeDRLPersistenceUnmarshallingMessagesTest in Windows environment).
The problematic part of the code: [2]
But there are also other places, where there is parsing line by line used. I.e. [3].
Rules should be parsed by keywords without depending on line separator or generally on lines.
[1] https://docs.jboss.org/drools/release/6.1.0.Final/drools-docs/html_single/#d0e5357
[2] https://github.com/droolsjbpm/drools/blob/007148f6e910a4706f6a20862abc002f4eef8c78/drools-workbench-models/drools-workbench-models-guided-dtree/src/main/java/org/drools/workbench/models/guided/dtree/backend/GuidedDecisionTreeModelUnmarshallingVisitor.java#L138
[3] https://github.com/droolsjbpm/drools/blob/9019854d3427a6079eeea19f548a102a2353276b/drools-workbench-models/drools-workbench-models-commons/src/main/java/org/drools/workbench/models/commons/backend/rule/RuleModelDRLPersistenceImpl.java#L1953
--
This message was sent by Atlassian JIRA
(v6.3.11#6341)
More information about the jboss-jira
mailing list