Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How fix add_kubernetes_metadata in new version 7.7.0? #18481

Closed
davidoceans opened this issue May 13, 2020 · 3 comments · Fixed by #18818
Closed

How fix add_kubernetes_metadata in new version 7.7.0? #18481

davidoceans opened this issue May 13, 2020 · 3 comments · Fixed by #18818
Assignees
Labels
bug Team:Platforms Label for the Integrations - Platforms team

Comments

@davidoceans
Copy link

Hi,

I've update to latest version of filebeat because I would like test the nginx-ingress-controller parser.
docker.elastic.co/beats/filebeat:7.7.0

But I was using this add_kubernetes_metadata.

Sorry could you say me how I should to change it to work properly?

I'm using Kubernetes, and this is a section of my filebeat configmap

    filebeat.inputs:
    - type: container
      paths:
        - /var/log/containers/*.log
      multiline.pattern: '^[[:space:]]+(at|\.{3})\b|^Caused by:'
      multiline.negate: false
      multiline.match: after
      processors:
        - add_kubernetes_metadata:
            in_cluster: true
            host: ${NODE_NAME}
            matchers:
            - logs_path:
                logs_path: "/var/log/containers/"

Thank you very much

@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label May 13, 2020
@andresrc andresrc added the request-discuss Label added to request the creator to create a topic in discuss label May 14, 2020
@andresrc andresrc removed needs_team Indicates that the issue/PR needs a Team:* label request-discuss Label added to request the creator to create a topic in discuss labels May 14, 2020
@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label May 14, 2020
@jsoriano
Copy link
Member

jsoriano commented May 28, 2020

I am reopening this issue because after some internal discussion we consider that this may be considered a regression, caused by #16979. There is a change there that makes the processor ignore indexers and matchers defined in configuration if default_matchers.enabled is not set to false. This could be considered its correct behaviour, but there was not reason to change it, as it has been working for long in a different way. I will revert to the old behaviour and add some testing to avoid unexpectedly changing it in the future.

@jsoriano jsoriano reopened this May 28, 2020
@jsoriano jsoriano added [zube]: In Progress bug Team:Platforms Label for the Integrations - Platforms team and removed needs_team Indicates that the issue/PR needs a Team:* label labels May 28, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations-platforms (Team:Platforms)

@jsoriano
Copy link
Member

By the way, there is a workaround, that is to set default_matchers.enabled to false. It would be like this in the config snippet in the description:

        ...
        - add_kubernetes_metadata:
            in_cluster: true
            host: ${NODE_NAME}
            default_matchers.enabled: false
            matchers:
            - logs_path:
                logs_path: "/var/log/containers/"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Team:Platforms Label for the Integrations - Platforms team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants