-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
[add_kubernetes_metadata][Metricset state_namespace] Fix namespace filter #39934
[add_kubernetes_metadata][Metricset state_namespace] Fix namespace filter #39934
Conversation
Signed-off-by: constanca <[email protected]>
Signed-off-by: constanca <[email protected]>
This pull request does not have a backport label.
To fixup this pull request, you need to add the backport labels for the needed
|
Signed-off-by: constanca <[email protected]>
Signed-off-by: constanca <[email protected]>
Signed-off-by: constanca <[email protected]>
Signed-off-by: constanca <[email protected]>
Signed-off-by: constanca <[email protected]>
Signed-off-by: constanca <[email protected]>
The lint errors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for that! Just address the changelog comment.
Signed-off-by: constanca <[email protected]>
Proposed commit message
This PR:
add_kubernetes_metadata
watchers.state_namespace
to also considernamespace
filter like all the other namespaced resources.Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.Related issues
Relates to #38978.
How to test locally
Learn how to run your own filebeat here. In next section, I explain my tests.
Results
I have a cluster with two namespaces:
default
andkube-system
.This is an example of filestream using the processor filtered by namespace `default`.
The documents fields annotated with data coming from the processor need to be coming from pods inside
default
namespace. Checking in discover I can see:And:
So only pods from
default
get annotated as expected.If I now remove the namespace from the processor and leave it like this:
I can see all documents get annotated with metadata: