Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

mesos 1.5.0: attempt to solve panic #86

Merged
merged 1 commit into from
Oct 26, 2018
Merged

Conversation

DeviaVir
Copy link
Contributor

I kept seeing this error everytime prometheus tried to scrape /metrics:

# docker logs -f system-mesos-exporter
panic: interface conversion: prometheus.Collector is *prometheus.GaugeVec, not *main.settableCounterVec

goroutine 18 [running]:
main.newMasterCollector.func20(0xc42019c330, 0x8ac000, 0xc42000e120, 0x0, 0x0)
        /go/src/github.com/mesosphere/mesos_exporter/master.go:419 +0x6f7
main.(*metricCollector).Collect(0xc420051cc0, 0xc4200668a0)
        /go/src/github.com/mesosphere/mesos_exporter/common.go:295 +0x1e7
github.com/mesosphere/mesos_exporter/vendor/github.com/prometheus/client_golang/prometheus.(*Registry).Gather.func2(0xc420026b10, 0xc4200668a0, 0x8ac200, 0xc420051cc0)
        /go/src/github.com/mesosphere/mesos_exporter/vendor/github.com/prometheus/client_golang/prometheus/registry.go:383 +0x61
created by github.com/mesosphere/mesos_exporter/vendor/github.com/prometheus/client_golang/prometheus.(*Registry).Gather
        /go/src/github.com/mesosphere/mesos_exporter/vendor/github.com/prometheus/client_golang/prometheus/registry.go:381 +0x302

After testing with this change the error went away and the mesos_exporter seems to be stable on master.
I tested this against mesos 1.5.0.

@jpeach jpeach merged commit b7229d4 into mesos:master Oct 26, 2018
jpeach added a commit that referenced this pull request Oct 26, 2018
ryodocx pushed a commit to ryodocx/mesos_exporter that referenced this pull request Mar 18, 2019
mesos 1.5.0: attempt to solve panic
ryodocx pushed a commit to ryodocx/mesos_exporter that referenced this pull request Mar 18, 2019
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants