[rules-users] CEP fusion
chris richmond
richmond.cd at gmail.com
Thu Dec 3 20:17:06 EST 2009
my zip file attachment was blocked. I will try to attach the source/rule
files.
modified the standard DroolsTest.java that gets created when you create a
new Drools project.
Thanks,
Chris
On Thu, Dec 3, 2009 at 3:07 PM, chris richmond <richmond.cd at gmail.com>wrote:
> here is my eclipse project with source and rule files. I modified test
> rules/class that gets created with a new drools project in eclipse. I hope
> the .zip file comes through
>
>
>
>
> 2009/12/3 Edson Tirelli <ed.tirelli at gmail.com>
>
>
>> Are you running your application in STREAM mode or CLOUD mode? Delaying
>> "not" is a feature of the STREAM mode. If you are already running in STREAM
>> mode, can you give me an isolated test that I can check?
>>
>> Thanks
>>
>> Edson
>>
>> 2009/12/3 chris richmond <richmond.cd at gmail.com>
>>
>>> Hello,
>>>
>>> I have this test rule that basically fires if a followup reading is not
>>> received with the appropriate value within some time. According to the
>>> fusion docs, simply using:
>>>
>>> *not*( FollowUpReading(value == $val, *this* before[0s,5s] $reading ) )
>>>
>>> should wait 5 seconds before firing, however this does not work unless I
>>> explicitly also set:
>>>
>>> *duration*( 5s )
>>>
>>> and if I do that, it seems to wait the 5 seconds, however it always
>>> follows what I put in the duration value and seems to compeltely ignore the
>>> time tolerances I use here.:
>>>
>>> $reading : DatarReading($val: value)
>>>
>>> *not*( FollowUpReading(value == $val, *this* before[0s,5s] $reading ) )
>>> And if I have different values, it will fire the rule after 2 seconds and
>>> ignore the 5s in the sample below.
>>>
>>> Any ideas?
>>> *
>>>
>>> rule
>>> *"my rule"
>>>
>>> *duration*( 2s )
>>>
>>> *when*
>>>
>>> $reading : DatarReading($val: value)
>>>
>>> *not*( FollowUpReading(value == $val, *this* before[0s,5s] $reading ) )
>>>
>>> *then*
>>>
>>> System.err.println(
>>> "did not receive follow up - reading value: " + $val);
>>>
>>> *
>>>
>>> end
>>>
>>>
>>>
>>>
>>> *
>>>
>>> _______________________________________________
>>> rules-users mailing list
>>> rules-users at lists.jboss.org
>>> https://lists.jboss.org/mailman/listinfo/rules-users
>>>
>>>
>>
>>
>> --
>> Edson Tirelli
>> JBoss Drools Core Development
>> JBoss by Red Hat @ www.jboss.com
>>
>> _______________________________________________
>> rules-users mailing list
>> rules-users at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/rules-users
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20091203/1b962535/attachment.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: DatarReading.java
Type: application/octet-stream
Size: 460 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-users/attachments/20091203/1b962535/attachment.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: DroolsTest.java
Type: application/octet-stream
Size: 3634 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-users/attachments/20091203/1b962535/attachment-0001.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: FollowUpReading.java
Type: application/octet-stream
Size: 466 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-users/attachments/20091203/1b962535/attachment-0002.obj
-------------- next part --------------
A non-text attachment was scrubbed...
Name: FusionTesing.drl
Type: application/octet-stream
Size: 1023 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-users/attachments/20091203/1b962535/attachment-0003.obj
More information about the rules-users
mailing list