Expand description

The consumer may define declarative filters that are sent to the producer and evaluated on the producer side before emitting the events.

Consumer filters consists of exclude and include criteria. In short, the exclude criteria are evaluated first and may be overridden by an include criteria. More precisely, they are evaluated according to the following rules:

  • Exclude criteria are evaluated first.
  • If no matching exclude criteria the event is emitted.
  • If an exclude criteria is matching the include criteria are evaluated.
  • If no matching include criteria the event is discarded.
  • If matching include criteria the event is emitted.

The exclude criteria can be a combination of:

  • ExcludeTags - exclude events with any of the given tags
  • ExcludeRegexEntityIds - exclude events for entities with entity ids matching the given regular expressions
  • ExcludeEntityIds - exclude events for entities with the given entity ids

To exclude all events you can use ExcludeRegexEntityIds with .*.

The include criteria can be a combination of:

  • IncludeTopics - include events with any of the given matching topics
  • IncludeTags - include events with any of the given tags
  • IncludeRegexEntityIds - include events for entities with entity ids matching the given regular expressions
  • IncludeEntityIds - include events for entities with the given entity ids

Structs

Enums

  • Exclude criteria are evaluated first. If no matching exclude criteria the event is emitted. If an exclude criteria is matching the include criteria are evaluated. If no matching include criteria the event is discarded. If matching include criteria the event is emitted.

Functions

  • Exclude events from all entity ids, convenience for combining with for example a topic filter to include only events matching the topic filter.