Skip to content

Add flag to enable KLOG verbosity levels #8706

@rh-hemartin

Description

@rh-hemartin

Problem
I had problems with the ApiServerSource pod that required me to change the code to enable verbosity on the k8s tooling usin klog. I had to introduce this block of code to the cmd of the adapter:

var fs flag.FlagSet
klog.InitFlags(&fs)
err := fs.Set("v", "7")
if err != nil {
	return fmt.Errorf("error setting klog level to '%s': %s", klogLevel, err)
}

It would be nice to have a way to set this klog verbosity level, probably via the config-logging ConfigMap on knative-eventing too keep everything consistent.

Persona:

Event Consumer

Exit Criteria
A measurable (binary) test that would indicate that the problem has been resolved.

Time Estimate (optional):

1-2 days depending on the development of tests (not sure if it is possible to test the level klog is at).

Additional context (optional)
Add any other context about the feature request here.

Metadata

Metadata

Assignees

Type

No type

Projects

Status

Backlog

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions