Open KyriosGN0 opened 1 week ago
Pinging code owners:
receiver/k8sobjects: @dmitryax @hvaghani221 @TylerHelmuth
See Adding Labels via Comments if you do not have permissions to add labels yourself.
You can already set namespaces to scrape here: https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/receiver/k8sobjectsreceiver/README.md?plain=1#L54
Do you want to enhance that option?
@atoulme as far as i understand its a whitelist, i want the option to blacklist namespace
OK, please explain how those 2 options would coexist. Please offer a configuration example.
@atoulme
namespaceWhitelist: [<Regex of namespace in include>]
namespaceBlacklist: [<Regex of namespace to exclude>]
or we could use labels to select which namespaces are exclude/included
as for coexist, we would need to build a list of namespace to watch based on those regex/labels and then pass it to if statement here
i do think its more useful to exclude namespace since in my experience i want to stop watching namespaces with high amount of events
whitelist and blacklist are no longer in use ; typically we use allowlist and denylist. We also try really hard to keep configuration backwards compatible ; there is already a namespaces option taking a list of namespaces. What is the smallest change that will get you what you need?
@atoulme a list of namespace to exclude
Component(s)
receiver/k8sobjects
Is your feature request related to a problem? Please describe.
yes, in our cluster we have seen that in certain namespace that is has a heavy spike pattern and generates around 50k events, this causes our otel daemonset to get killed my oom
Describe the solution you'd like
we would like the optiont to exclude namespace when using the k8sobjects receiver
Describe alternatives you've considered
No response
Additional context
No response