Expression

This filter processor applies a custom Javascript expression to filter events. This is ideal when there is a need to fine tune the filtering process to the needs of the use case.

Example

filter:
  expression: "(typeof symbol !== 'undefined' && symbol === 'IBM') ? true : false;"

This will provide all IBM events to the next processors. Note top level StreamEvent attributes are not available within the scripting processing context.

Attributes

AttributeDescriptionData TypeRequired

expression

Javascript expression that returns a boolean value

String

Last updated