[JBoss JIRA] Created: (JBRULES-2248) Drools Expert User Guide errors
by Karsten Thoms (JIRA)
Drools Expert User Guide errors
-------------------------------
Key: JBRULES-2248
URL: https://jira.jboss.org/jira/browse/JBRULES-2248
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: drools-docs
Affects Versions: 5.0.1.FINAL
Reporter: Karsten Thoms
Assignee: Mark Proctor
Priority: Trivial
Some minor issues I found when following the User Guide:
Improvement: Variable 'kbase' is not introduced in the first example. Add declaration and instantiation to example in 2.1.1.
Rule "Status output when things are ok"
error:
not Sprinkler( on === true )
correct:
not Sprinkler( on == true )
ERROR
if ( kbuilder.hasErrors() ) {
System.err.println( builder.getErrors().toString() );
}
CORRECT
if ( kbuilder.hasErrors() ) {
System.err.println( kbuilder.getErrors().toString() );
}
--
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
15 years, 1 month
[JBoss JIRA] Created: (JBRULES-2763) Event declaration using fqn
by Samuli Saarinen (JIRA)
Event declaration using fqn
---------------------------
Key: JBRULES-2763
URL: https://jira.jboss.org/browse/JBRULES-2763
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Environment: Java 1.6
Drools 5.1.1
Reporter: Samuli Saarinen
Assignee: Mark Proctor
I'm trying to create event declaration using fqn in the declaration but
for some reason it doesn't work. I have the following rule:
package com.test.pkg
declare com.test.Event1
@role(event)
@expires(2s)
end
compiling it produces the following error:
[6,11]: [ERR 103] Line 6:11 rule 'end_key' failed predicate:
{(validateIdentifierKey(DroolsSoftKeywords.END))}? in com
But if I change it as follows:
package com.test.pkg
import com.test.Event1
declare Event1
@role(event)
@expires(2s)
end
Everything works as expected...
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 1 month
[JBoss JIRA] Created: (JBRULES-2734) NPE loading changeset
by Tommy Odom (JIRA)
NPE loading changeset
---------------------
Key: JBRULES-2734
URL: https://jira.jboss.org/browse/JBRULES-2734
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: drools-core (expert)
Affects Versions: 5.1.1.FINAL
Reporter: Tommy Odom
Assignee: Mark Proctor
We are receiving a NPE when drools is attempting to load the deltas from guvnor in our webapp. This used to work fine in 5.0 but we recently upgraded to 5.1 and started receiving this error after we create a new snapshot in guvnor.
The output from our application server log is:
KnowledgeAgent applying ChangeSet
KnowledgeAgent performing an incremental build of the ChangeSet
no visitor implementation for : class org.drools.ruleflow.core.RuleFlowProcess : org.drools.ruleflow.core.RuleFlowProcess@30012e
Exception in thread "Thread-36"
org.drools.RuntimeDroolsException: java.lang.reflect.InvocationTargetException : [R
ule name=Project Part Custom Finishing Cost, agendaGroup=MAIN, salience=0, no-loop=false] at org.drools.core.util.ReflectiveVisitor.visit(ReflectiveVisitor.java:56)
at org.drools.agent.impl.BinaryResourceDiffProducerImpl.diff(BinaryResourceDiffProducerImpl.java:63)
at org.drools.agent.impl.KnowledgeAgentImpl.incrementalBuildResources(KnowledgeAgentImpl.java:785) at org.drools.agent.impl.KnowledgeAgentImpl.buildKnowledgeBase(KnowledgeAgentImpl.java:586)
at org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:185)
at org.drools.agent.impl.KnowledgeAgentImpl$ChangeSetNotificationDetector.run(KnowledgeAgentImpl.java:1106) at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597) at org.drools.core.util.ReflectiveVisitor.visit(ReflectiveVisitor.java:47)
... 6 more
Caused by: java.lang.NullPointerException at org.drools.rule.EvalCondition.equals(EvalCondition.java:169)
at org.drools.rule.GroupElement.equals(GroupElement.java:273)
at org.drools.agent.impl.BinaryResourceDiffProducerImpl.compareRules(BinaryResourceDiffProducerImpl.java:258)
at org.drools.agent.impl.BinaryResourceDiffProducerImpl.visitRule(BinaryResourceDiffProducerImpl.java:117)
... 11 more
The rule that it mentions in the error is:
dialect "java"
ruleflow-group "finishing-price"
when
$pp : ProjectPart(finishTime > 0)
eval(salesChannelId != 4 && includeFinishing)
then
double finishingRate = 1;
double customFinishingCost = $pp.getQuantity() * $pp.getFinishTime() * finishingRate;
addToProjectFinishingCost($pp.getProject(), customFinishingCost);
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 1 month
[JBoss JIRA] Created: (JBRULES-3003) restriction evaluation returns 'false' for "trueField != falseField"
by Wolfgang Laun (JIRA)
restriction evaluation returns 'false' for "trueField != falseField"
--------------------------------------------------------------------
Key: JBRULES-3003
URL: https://issues.jboss.org/browse/JBRULES-3003
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: drools-compiler (expert)
Affects Versions: 5.2.0.M2
Reporter: Wolfgang Laun
Assignee: Mark Proctor
Priority: Critical
Fix For: 5.2.0.CR1
Comparing two boolean fields using != appears to return always false
public class Customer {
boolean tenthSaleFree = true;
boolean goldCard = false;
// ...
}
With some customers containing boolean fields as initialized:
rule this_does_not_fire
when
$c: Customer( tenthSaleFree != goldCard )
then
end
rule this_works
when
Customer( tenthSaleFree == ( ! goldCard ) )
then
end
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 1 month
[JBoss JIRA] Created: (JBRULES-2981) NPE on rule evaluation
by Roman Novak (JIRA)
NPE on rule evaluation
----------------------
Key: JBRULES-2981
URL: https://issues.jboss.org/browse/JBRULES-2981
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: drools-core (expert)
Affects Versions: 5.2.0.M2
Environment: <properties>
<drools.version>5.2.0.M2</drools.version>
<drools.planner.version>5.2.0.M2</drools.planner.version>
</properties>
<dependency>
<groupId>org.drools</groupId>
<artifactId>drools-core</artifactId>
<version>${drools.version}</version>
</dependency>
<dependency>
<groupId>org.drools</groupId>
<artifactId>knowledge-api</artifactId>
<version>${drools.version}</version>
</dependency>
<dependency>
<groupId>org.drools.planner</groupId>
<artifactId>drools-planner-core</artifactId>
<version>${drools.planner.version}</version>
</dependency>
Reporter: Roman Novak
Assignee: Mark Proctor
Priority: Critical
The following Rule worked in Version 5.2.0.M1 of drools-core and drools-api.
It fails with NPE (s. details below) in Version 5.2.0.M2 of drools-core and knowledge-api.
Tested with drools-planner-core 5.1.0 and 5.2.0.M2 => both work.
Dialect in DRL file is "java".
import org.joda.time.Interval;
public class MediumBookingOpt implements Serializable {
private static final long serialVersionUID = 5616820300463695243L;
private Long mediId;
private Interval timeInterval;
...
DRL FILE:
...
dialect "java"
...
query "queryMediumBookingExistsAfter"
$mbo1: MediumBookingOpt ();
not MediumBookingOpt( mediId == $mbo1.mediId,
eval(timeInterval.isAfter($mbo1.getTimeInterval()))
)
end
org.drools.RuntimeDroolsException: Exception executing predicate timeInterval.isAfter($mbo1.getTimeInterval())
at org.drools.rule.PredicateConstraint.isAllowedCachedLeft(PredicateConstraint.java:321)
at org.drools.common.DoubleBetaConstraints.isAllowedCachedLeft(DoubleBetaConstraints.java:168)
at org.drools.reteoo.NotNode.assertLeftTuple(NotNode.java:85)
at org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:189)
at org.drools.reteoo.SingleLeftTupleSinkAdapter.propagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:64)
at org.drools.reteoo.JoinNode.assertLeftTuple(JoinNode.java:100)
at org.drools.reteoo.SingleLeftTupleSinkAdapter.doPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:189)
at org.drools.reteoo.SingleLeftTupleSinkAdapter.createAndPropagateAssertLeftTuple(SingleLeftTupleSinkAdapter.java:138)
at org.drools.reteoo.LeftInputAdapterNode.assertObject(LeftInputAdapterNode.java:141)
at org.drools.reteoo.SingleObjectSinkAdapter.propagateAssertObject(SingleObjectSinkAdapter.java:59)
at org.drools.reteoo.CompositeObjectSinkAdapter.propagateAssertObject(CompositeObjectSinkAdapter.java:360)
at org.drools.reteoo.ObjectTypeNode.assertObject(ObjectTypeNode.java:185)
at org.drools.reteoo.EntryPointNode.assertObject(EntryPointNode.java:143)
at org.drools.common.NamedEntryPoint.insert(NamedEntryPoint.java:332)
at org.drools.common.AbstractWorkingMemory.insert(AbstractWorkingMemory.java:917)
at org.drools.reteoo.ReteooWorkingMemory.getQueryResults(ReteooWorkingMemory.java:164)
<SNIP>
at org.drools.planner.core.move.factory.CachedMoveFactory.solvingStarted(CachedMoveFactory.java:36)
at org.drools.planner.core.localsearch.decider.selector.MoveFactorySelector.solvingStarted(MoveFactorySelector.java:55)
at org.drools.planner.core.localsearch.decider.selector.CompositeSelector.solvingStarted(CompositeSelector.java:55)
at org.drools.planner.core.localsearch.decider.DefaultDecider.solvingStarted(DefaultDecider.java:94)
at org.drools.planner.core.localsearch.DefaultLocalSearchSolver.solvingStarted(DefaultLocalSearchSolver.java:119)
at org.drools.planner.core.localsearch.DefaultLocalSearchSolver.solveImplementation(DefaultLocalSearchSolver.java:67)
at org.drools.planner.core.solver.AbstractSolver.solve(AbstractSolver.java:120)
<SNIP>
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
at org.springframework.test.context.junit4.statements.RunBeforeTestMethodCallbacks.evaluate(RunBeforeTestMethodCallbacks.java:74)
at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31)
at org.springframework.test.context.junit4.statements.RunAfterTestMethodCallbacks.evaluate(RunAfterTestMethodCallbacks.java:82)
at org.springframework.test.context.junit4.statements.SpringRepeat.evaluate(SpringRepeat.java:72)
at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:240)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:44)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:180)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:41)
at org.junit.runners.ParentRunner$1.evaluate(ParentRunner.java:173)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31)
at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)
at org.junit.runners.ParentRunner.run(ParentRunner.java:220)
at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:180)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: java.lang.NullPointerException
at org.drools.base.mvel.MVELPredicateExpression.evaluate(MVELPredicateExpression.java:82)
at org.drools.rule.PredicateConstraint.isAllowedCachedLeft(PredicateConstraint.java:314)
... 60 more
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 1 month
[JBoss JIRA] Created: (AS7-795) Upgrade to JBossTS 4.15
by Scott Marlow (JIRA)
Upgrade to JBossTS 4.15
-----------------------
Key: AS7-795
URL: https://issues.jboss.org/browse/AS7-795
Project: Application Server 7
Issue Type: Task
Reporter: Scott Marlow
Assignee: Jason Greene
Fix For: 7.0.0.CR1
>From recent email exchange: "JBossTS 4.15 is faster than 4.14. JBossTS 4.15 does have the new HornetQ journal based objectstore which is much, much faster." The faster journal needs to be configured to be on by default or AS7 needs configuration changes to allow it to be enabled.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 1 month
[JBoss JIRA] Created: (JBRULES-2589) running HonestPolitician from a Maven created eclipse project for drools-examples-drl => NoClassDefFoundError: XStream
by Jean-Marc Vanel (JIRA)
running HonestPolitician from a Maven created eclipse project for drools-examples-drl => NoClassDefFoundError: XStream
----------------------------------------------------------------------------------------------------------------------
Key: JBRULES-2589
URL: https://jira.jboss.org/browse/JBRULES-2589
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Affects Versions: FUTURE
Environment: % uname -a
Linux jmv-desktop 2.6.32-23-generic #37-Ubuntu SMP Fri Jun 11 08:03:28 UTC 2010 x86_64 GNU/Linux
% java -version
java version "1.6.0_20"
Java(TM) SE Runtime Environment (build 1.6.0_20-b02)
Java HotSpot(TM) 64-Bit Server VM (build 16.3-b01, mixed mode)
Reporter: Jean-Marc Vanel
Assignee: Mark Proctor
I made an eclipse project using Maven from drools-trunk/drools-examples/drools-examples-drl , and when running the class HonestPoliticianExample,
I have a NoClassDefFoundError: com/thoughtworks/xstream/XStream
The stack is :
Exception in thread "main" java.lang.NoClassDefFoundError: com/thoughtworks/xstream/XStream
at org.drools.audit.KnowledgeRuntimeLoggerProviderImpl.newFileLogger(KnowledgeRuntimeLoggerProviderImpl.java:10)
at org.drools.logger.KnowledgeRuntimeLoggerFactory.newFileLogger(KnowledgeRuntimeLoggerFactory.java:37)
at org.drools.examples.HonestPoliticianExample.main(HonestPoliticianExample.java:35)
The dependency com.thoughtworks.xstream is in drools-compiler/pom.xml , but only at the scope test !?!
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 1 month