Skip to content
This repository has been archived by the owner on Aug 31, 2022. It is now read-only.

Filtering not done properly on Type #80

Closed
aronneagu opened this issue Aug 17, 2020 · 1 comment
Closed

Filtering not done properly on Type #80

aronneagu opened this issue Aug 17, 2020 · 1 comment

Comments

@aronneagu
Copy link

aronneagu commented Aug 17, 2020

I am trying to get only the events of Warning type, but somehow the config below also prints out Normal events

I have the following config

---
apiVersion: v1
kind: ConfigMap
metadata:
  name: event-exporter-cfg
  namespace: monitoring
data:
  config.yaml: |
    #logLevel: debug
    logLevel: error
    route:
      routes:
        - match:
          - type: "Warning"
          - receiver: "dump"
    receivers:
      - name: "dump"
        file:
          path: "/dev/stdout"

I am seeing events also that have type=Normal. Am I doing something wrong, or the filtering doesn't work as expected?

Using version opsgenie/kubernetes-event-exporter:0.8
Kube version

Client Version: version.Info{Major:"1", Minor:"18", GitVersion:"v1.18.2", GitCommit:"52c56ce7a8272c798dbc29846288d7cd9fbae032", GitTreeState:"clean", BuildDate:"2020-04-16T11:56:40Z", GoVersion:"go1.13.9", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"17", GitVersion:"v1.17.7", GitCommit:"5737fe2e0b8e92698351a853b0d07f9c39b96736", GitTreeState:"clean", BuildDate:"2020-06-24T19:54:11Z", GoVersion:"go1.13.6", Compiler:"gc", Platform:"linux/amd64"}
@mustafaakin
Copy link
Contributor

It's a problem with YAML and lack of validation.

Each of the following is another leaf on the tree:

      - type: "Warning"
      - receiver: "dump"

Warning has no reciever.
Receiver has no filter, that's why.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants