[jboss-jira] [JBoss JIRA] (DROOLS-869) Fundamental equal syntax doesn't work
Marco Rietveld (JIRA)
issues at jboss.org
Mon Aug 3 13:03:06 EDT 2015
[ https://issues.jboss.org/browse/DROOLS-869?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marco Rietveld moved JBPM-4545 to DROOLS-869:
---------------------------------------------
Project: Drools (was: jBPM)
Key: DROOLS-869 (was: JBPM-4545)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Affects Version/s: 5.5.0.Final
(was: jBPM 5.4)
> Fundamental equal syntax doesn't work
> --------------------------------------
>
> Key: DROOLS-869
> URL: https://issues.jboss.org/browse/DROOLS-869
> Project: Drools
> Issue Type: Bug
> Affects Versions: 5.5.0.Final
> Environment: Linux version 2.6.32-431.29.2.el6.x86_64 (mockbuild at x86-026.build.eng.bos.redhat.com) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-4) (GCC) ) #1 SMP Sun Jul 27 15:55:46 EDT 2014
> JDK1.8.0_31
> Drools 5.4.0.Final
> Tomcat 7.0.2
> Reporter: Johnny Wang
> Assignee: Kris Verlaenen
>
> Waybill object has tpStatus is string "KILL",
> but
> $wb: Waybill( tpStatus == "KILL" ) // this one doesn't work
> eval($wb.getTpStatus().equals( CarStatus.TP_STATUS_KILL ) ) // this one works well.
>
> exact web application works fine on windows tomcat server.failed on linux tomcat server.
> public static final String TP_STATUS_KILL = "KILL";
> public class Waybill {
> private String wbSn;
> private int wbVrsn;
> private String tpStatus; ...
> }
> Other classes are not relavant here.
> test result :
> 8 :E[020793-AEX],[5367233007-3], R[Car_Started_UpdateVrsnAndWbStatus]
> 9 :E[020793-AEX],[5367233007-3], R[Car_Started_TpStatus_Kill_test_1]
> the rules are :
> rule "Car_Started_UpdateVrsnAndWbStatus"
> ruleflow-group "ProcessWaybillFeed"
> no-loop
> when
> $s:RuleStateMachine( wbStatus == WaybillMsgStatus.Check_CarMoving)
> $w: ItcpWaybill(inDb ==false)
> $cl:CarLocation( wb!=null, wb.wbSn == $w.wbSn )
> $w1:ItcpWaybill( wbSn == $w.wbSn, wbVrsn == $w.wbVrsn, inDb ==true )
>
> then
> Waybill wb2 = new Waybill();
> wb2.setId("9999");
> wb2.setWbSn($cl.getWb().getWbSn());
> wb2.setTpStatus("KILL");
> insert (wb2);
> modify($s) {
> setWbStatus(WaybillMsgStatus.Car_Started )
> }
> end
> //======================================================
> //Kill TEST
> //======================================================
> rule "Car_Started_TpStatus_Kill_test_0"
> ruleflow-group "ProcessWaybillFeed"
> salience 300
> no-loop
> when
> $s:RuleStateMachine( wbStatus == WaybillMsgStatus.Car_Started)
> $w: ItcpWaybill()
> $cl:CarLocation( eqNr == $w.eqNr, eqInit == $w.eqInit, $wb0:wb, $wb0!=null , wb.wbSn== $w.wbSn )
> $wb: Waybill( tpStatus == "KILL" )
> eval($wb.getTpStatus().equals( CarStatus.TP_STATUS_KILL ) )
> then
> end
> rule "Car_Started_TpStatus_Kill_test_1"
> ruleflow-group "ProcessWaybillFeed"
> salience 300
> no-loop
> when
> $s:RuleStateMachine( wbStatus == WaybillMsgStatus.Car_Started)
> $w: ItcpWaybill(inDb ==false)
> $cl:CarLocation( eqNr == $w.eqNr, eqInit == $w.eqInit, $wb0:wb, $wb0!=null , wb.wbSn== $w.wbSn, wb.tpStatus == CarStatus.TP_STATUS_KILL )
> $wb: Waybill( wbSn == $wb0.wbSn )
> eval($wb.getTpStatus().equals( CarStatus.TP_STATUS_KILL ) )
> then
> end
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
More information about the jboss-jira
mailing list