beyla
beyla copied to clipboard
Beyla crashes when some Kubernetes properties are missing
There's en edge case where Kubernetes decoration is enabled but the value of InformersSyncTimeout is not set (time out 0). Beyla logs this error, but the execution continues leading to this panic:
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x18 pc=0x59c435b]
github.com/grafana/beyla/pkg/internal/transform/kube.(*Database).OwnerPodInfo(0x0, 0xf0000dff)
/go/pkg/mod/github.com/grafana/[email protected]/pkg/internal/transform/kube/db.go:66 +0x1b
github.com/grafana/beyla/pkg/transform.(*metadataDecorator).do(0xc002fd99e0?, 0xc006685d40)
/go/pkg/mod/github.com/grafana/[email protected]/pkg/transform/k8s.go:100 +0x28
github.com/grafana/beyla/pkg/transform.(*metadataDecorator).nodeLoop(0xc002fd9670, 0xc00317ee40, 0xc0032b8660)
/go/pkg/mod/github.com/grafana/[email protected]/pkg/transform/k8s.go:92 +0x14b
github.com/mariomac/pipes/pkg/node.(*Middle[...]).start.func1()
/go/pkg/mod/github.com/mariomac/[email protected]/pkg/node/node.go:185 +0x3b
created by github.com/mariomac/pipes/pkg/node.(*Middle[...]).start in goroutine 373
/go/pkg/mod/github.com/mariomac/[email protected]/pkg/node/node.go:184 +0x259
I encounter the same issue when enabling the Kubernetes Metadata decoration (through Grafana Alloy) on a local Colima Kubernetes Cluster.
@mschmidt291 this will be fixed in the next Alloy version!
is there a workaround for this ?
Any update or workaround for this it is effecting all the go services running on kubernetes.
Any update or workaround for this it is effecting all the go services running on kubernetes.
Can you describe the scenario/config where this is happening? thanks