Empty K8S labels
What's wrong?
I followed the instructions from the Getting Started section in the README and noticed that Beyla is exposes lots of empty K8S labels even though the example doesn't run on K8S..
Example:
http_server_request_duration_seconds_count{http_request_method="GET",http_response_status_code="200",http_route="/",instance="",job="",k8s_cluster_name="",k8s_container_name="",k8s_cronjob_name="",k8s_daemonset_name="",k8s_deployment_name="",k8s_job_name="",k8s_kind="",k8s_namespace_name="",k8s_node_name="",k8s_owner_name="",k8s_pod_name="",k8s_pod_start_time="",k8s_pod_uid="",k8s_replicaset_name="",k8s_statefulset_name="",server_address="127.0.0.1",server_port="9000",service_name="example-http-service",service_namespace=""} 4
It would be better not to include these labels outside of K8S.
Note that this is low priority: Prometheus treats empty labels the same as missing labels, so it doesn't really matter. It just looks a bit unexpected when you first try Beyla following the Getting Started guide.
Steps to reproduce
From the Getting Started section in the README:
go run ./examples/example-http-service.go
export BEYLA_PROMETHEUS_PORT=9400
export BEYLA_OPEN_PORT=8080
sudo -E ./beyla
System information
No response
Software version
Version=main Revision=d25005ab5
Configuration
Logs
Thanks for looking into this @marctc!
Can you please provide more detail on the resolution of this issue? For example, please provide one of the following:
- An OBI or Beyla PR that resolved this issue.
- A test in OBI or Beyla that proves this issue is no longer present.
- A set of manual steps that you've taken that confirms the resolution of this issue if a test is difficult to construct.
Thanks @grcevski. This issue was fixed since this https://github.com/open-telemetry/opentelemetry-ebpf-instrumentation/pull/681 was added to Beyla.