Skip to content
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

bug: panic during metrics serialisation #427

Open
adriansr opened this issue Apr 11, 2023 · 0 comments
Open

bug: panic during metrics serialisation #427

adriansr opened this issue Apr 11, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@adriansr
Copy link
Contributor

We've observed this panic in synthetic-monitoring-agent v0.14.3:

panic: runtime error: slice bounds out of range [-3:]

goroutine 4069902855 [running]:
github.com/prometheus/prometheus/prompb.(*Label).MarshalToSizedBuffer(0xc01397fd80, {0xc04372a000, 0x19, 0x4334})
	github.com/prometheus/prometheus@v1.8.2-0.20200727090838-6f296594a852/prompb/types.pb.go:767 +0x27b
github.com/prometheus/prometheus/prompb.(*TimeSeries).MarshalToSizedBuffer(0xc0228df500, {0xc04372a000, 0x46, 0x4334})
	github.com/prometheus/prometheus@v1.8.2-0.20200727090838-6f296594a852/prompb/types.pb.go:720 +0x133
github.com/prometheus/prometheus/prompb.(*WriteRequest).MarshalToSizedBuffer(0xc04d9b0100, {0xc04372a000, 0x4334, 0x4334})
	github.com/prometheus/prometheus@v1.8.2-0.20200727090838-6f296594a852/prompb/remote.pb.go:473 +0x127
github.com/prometheus/prometheus/prompb.(*WriteRequest).XXX_Marshal(0x20?, {0xc04372a000, 0xc04d9b0100?, 0x4334}, 0x0?)
	github.com/prometheus/prometheus@v1.8.2-0.20200727090838-6f296594a852/prompb/remote.pb.go:85 +0x37
github.com/gogo/protobuf/proto.Marshal({0xeab0c0, 0xc04d9b0100})
	github.com/gogo/protobuf@v1.3.2/proto/table_marshal.go:2940 +0x144
github.com/grafana/synthetic-monitoring-agent/internal/pkg/prom.buildTimeSeriesWriteRequest({0xc0228df500, 0x56, 0x88}, {0xc0368b2000, 0x2f0, 0x2800})
	github.com/grafana/synthetic-monitoring-agent/internal/pkg/prom/prom.go:134 +0xc9
github.com/grafana/synthetic-monitoring-agent/internal/pkg/prom.SendSamplesWithBackoff({0xeabf20, 0xc04d9a4720}, 0xc046967b48?, {0xc0228df500?, 0xc00007e720?, 0xc04d9b00c0?}, 0xc036847f20)
	github.com/grafana/synthetic-monitoring-agent/internal/pkg/prom/prom.go:111 +0x56
github.com/grafana/synthetic-monitoring-agent/internal/pusher.(*Publisher).pushMetrics(0xc057ffcea0?, {0xeabeb0, 0xc0001ffb80}, 0x0?, {0xc0228df500, 0x56, 0x88})
	github.com/grafana/synthetic-monitoring-agent/internal/pusher/pusher.go:221 +0x130
github.com/grafana/synthetic-monitoring-agent/internal/pusher.(*Publisher).publish(0xc00022a000, {0xeabeb0, 0xc0001ffb80}, {0xeaa430, 0xc004944400})
	github.com/grafana/synthetic-monitoring-agent/internal/pusher/pusher.go:176 +0x83b
created by github.com/grafana/synthetic-monitoring-agent/internal/pusher.(*Publisher).Run
	github.com/grafana/synthetic-monitoring-agent/internal/pusher/pusher.go:131 +0x4a
@adriansr adriansr added the bug Something isn't working label Apr 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant