@Mario: Could this be something in mvel2-2.1.0.drools16.jar?

With Drools 5.3.0, this works fine:

rule "Detect it"
when
    $start : RawEvent()
    not RawEvent(this != $start, id == $start.id, $start after[0ms, 90s]
this)
then
    System.out.println("detected: " + $start);
end

Moving on to 5.4.0, you get the error "Unable to Analyse Expression this !=
$start &&...", as reported previously by Rob.

@Rob: As a workaround, use
   not $re: RawEvent(eval($re != $start),...

(And I'd recommend using new Random( 12345 ) to obtain repeatable test
outputs.)

-W

On 1 September 2012 20:23, Rob21 <rob.per...@gmail.com> wrote:

> I tried using FireAllRules each time i inserted an object instead of
> FireUntilHalt in another thread. Unfortunately it results in the same error
> message :
>
> Unable to Analyse Expression this != $start && after0.evaluate( $start,
> this
> ):
> [Error: unable to resolve method using strict-mode:
> com.sample.RawEvent.after0()]
> [Near : {... this != $start && after0.evaluate( $start, this ....}]
>              ^ : [Rule name='Detect it']
>
> java.lang.IllegalArgumentException: Could not parse knowledge.
>         at com.sample.DroolsTest.readKnowledgeBase(DroolsTest.java:106)
>         at com.sample.DroolsTest.main(DroolsTest.java:54)
>
>
>
>
> --
> View this message in context:
> http://drools.46999.n3.nabble.com/before-after-behavior-for-negative-pattern-tp4019497p4019503.html
> Sent from the Drools: User forum mailing list archive at Nabble.com.
> _______________________________________________
> rules-users mailing list
> rules-us...@lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>
_______________________________________________
rules-dev mailing list
rules-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-dev

Reply via email to