Skip to content

internal/tsdb/filter: add support for exact match filtering (without using Regexp) #44

@sebastianco

Description

@sebastianco

Often times one knows the exact metric names or tag values which need to be accepted or blocked. In these cases is more efficient to not use regular expressions but just to lookup the metric name and the tag values of the evaluated point in a map of preconfigured values.

Here is an example of a configuration I've been already using (I named the filter OneOf however I am not 100% pleased with this name):

"Filter": [
    {
     "OneOf": {
       "Metrics": ["metricA", "metricB"],
       "Tags": { "cluster": ["x", "y", "z"], "anotherTag": ["value1", "value2"] }
     },
     "Block": true
    }
 ]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions