[omniNotify] Filter Evaluation Problems

Cameron Rochester Cameron.Rochester at Ripple-Systems.com
Thu May 29 09:29:16 BST 2003


No need to send you the code :)

$Name == 'Value' worked.

It is a bit concerning that $.Name == 'Value' does not work as this is an
acceptable constraint as defined by the OMG spec.

I hope that the $Name == 'Value' syntax works with the TAO Notification
service :)

Cheers!
Cameron

-----Original Message-----
From: Robert E. Gruber [mailto:gruber at research.att.com]
Sent: Wednesday, May 28, 2003 9:05 PM
To: Cameron Rochester; omninotify-list at omniorb-support.com
Cc: Robert E. Gruber
Subject: Re: [omniNotify] Filter Evaluation Problems


If you send me your supplier/consumer code I will try it out and see what is
happening.

BTW you could also write

$Name == 'Value'

for the constraint expression.

-- Bob



----- Original Message -----
From: "Cameron Rochester" <Cameron.Rochester at Ripple-Systems.com>
To: <omninotify-list at omniorb-support.com>
Sent: Wednesday, May 28, 2003 5:12 AM
Subject: [omniNotify] Filter Evaluation Problems


> Hi all,
>
> I am having some problems with omniNotify 2.0. It does not seem to
evaluate
> my filters correctly - either that or I don't know how to use it...
>
> --- I am sending events of the following ---
>
> //
> // Fixed Header
> //
> event->header.fixed_header.event_type.domain_name = CORBA::string_dup(
"Foo"
> );
> event->header.fixed_header.event_type.type_name = CORBA::string_dup( "Bar"
> );
>
> //
> // Filterable Data
> //
> event->filterable_data.length( 1 );
> event->filterable_data[0].name = CORBA::string_dup( "Name" );
> event->filterable_data[0].value <<= "Value";
>
>
> --- I create a subscriber with the following Filter attached to the proxy
> ---
>
> CosNotification::EventTypeSeq seq;
> seq.length(1);
> seq[0].domain_name = "Foo";
> seq[0].type_name = "Bar";
>
> CosNotifyFilter::ConstraintExpSeq expression;
> expression.length(1);
> expression[0].event_types = seq;
> expression[0].constraint_expr = "( $.header.filterable_data(Name) ==
'Value'
> )";
>
> --- I have also tried to no avail ---
> // this
> expression[0].constraint_expr = "$.header.filterable_data(Name) == 'Value'
> ";
> // or
> expression[0].constraint_expr = "( $.Name) == 'Value' )";
> //or
> expression[0].constraint_expr = "$.Name == 'Value' ";
>
> ---
>
> Now, I have been using the TAO Notification Service up to now without any
> problems with these constraints. (Took me a while to figure out a number
of
> the differences between omniNotify & TAO - such as filters correctly
> implementing attach_callback for subscription_change notifications in
> omniNotify)
>
> If I *don't* specify the constraint (ie: set it to 'true') and still
specify
> the domain_name and type_name, I receive the events just fine....
>
> I have tried turning on the debug options in the omniNotify configuration
> file but I don't seem to get any output to either stderr or to a log file
> (the log file is created, it just isn't populated)
>
> Any ideas - should the above constraint work?
>
> Cheers
> Cameron
>
>
>
>
> _______________________________________________
> omninotify-list mailing list
> omninotify-list at omniorb-support.com
> http://www.omniorb-support.com/mailman/listinfo/omninotify-list
>



More information about the omninotify-list mailing list