pwillie / prometheus-es-adapter

Prometheus remote storage adapter for Elasticsearch
Apache License 2.0
60 stars 31 forks source link

Read sometime fails #25

Open Kanshiroron opened 5 years ago

Kanshiroron commented 5 years ago

Hello,

I've been using this adapter to send and read collected metrics from ElasticSearch. I was creating some Grafana Dashboard when I noticed that some queries/graph were not working properly, and the adapter throws a stacktrace:

es_adapter_infradev_1  | goroutine 16439 [chan send, 3 minutes]:
es_adapter_infradev_1  | github.com/pwillie/prometheus-es-adapter/vendor/gopkg.in/olivere/elastic%2ev6.(*BulkProcessor).Add(...)
es_adapter_infradev_1  |    /go/src/github.com/pwillie/prometheus-es-adapter/vendor/gopkg.in/olivere/elastic.v6/bulk_processor.go:404
es_adapter_infradev_1  | github.com/pwillie/prometheus-es-adapter/pkg/elasticsearch.(*WriteService).Write(0xc00045c1a0, 0xc03eb0a800, 0x5c, 0x80)
es_adapter_infradev_1  |    /go/src/github.com/pwillie/prometheus-es-adapter/pkg/elasticsearch/write.go:91 +0x3b7
es_adapter_infradev_1  | github.com/pwillie/prometheus-es-adapter/pkg/handlers.writeHandler.func1(0xc799a0, 0xc03d105c00, 0xc03eb9c500)
es_adapter_infradev_1  |    /go/src/github.com/pwillie/prometheus-es-adapter/pkg/handlers/adapter.go:34 +0x1cf
es_adapter_infradev_1  | net/http.HandlerFunc.ServeHTTP(0xc000472440, 0xc799a0, 0xc03d105c00, 0xc03eb9c500)
es_adapter_infradev_1  |    /usr/local/go/src/net/http/server.go:1964 +0x44
es_adapter_infradev_1  | net/http.(*ServeMux).ServeHTTP(0xc00020c960, 0xc799a0, 0xc03d105c00, 0xc03eb9c500)
es_adapter_infradev_1  |    /usr/local/go/src/net/http/server.go:2361 +0x127
es_adapter_infradev_1  | github.com/pwillie/prometheus-es-adapter/vendor/github.com/gorilla/handlers.CompressHandlerLevel.func1(0xc799a0, 0xc03d105c00, 0xc03eb9c500)
es_adapter_infradev_1  |    /go/src/github.com/pwillie/prometheus-es-adapter/vendor/github.com/gorilla/handlers/compress.go:146 +0x18c
es_adapter_infradev_1  | net/http.HandlerFunc.ServeHTTP(0xc00045c860, 0xc799a0, 0xc03d105c00, 0xc03eb9c500)
es_adapter_infradev_1  |    /usr/local/go/src/net/http/server.go:1964 +0x44
es_adapter_infradev_1  | github.com/pwillie/prometheus-es-adapter/vendor/github.com/gorilla/handlers.recoveryHandler.ServeHTTP(0xc73de0, 0xc00045c860, 0x0, 0x0, 0x1, 0xc799a0, 0xc03d105c00, 0xc03eb9c500)
es_adapter_infradev_1  |    /go/src/github.com/pwillie/prometheus-es-adapter/vendor/github.com/gorilla/handlers/recovery.go:78 +0xb0
es_adapter_infradev_1  | net/http.serverHandler.ServeHTTP(0xc0003081a0, 0xc799a0, 0xc03d105c00, 0xc03eb9c500)
es_adapter_infradev_1  |    /usr/local/go/src/net/http/server.go:2741 +0xab
es_adapter_infradev_1  | net/http.(*conn).serve(0xc03dc4ebe0, 0xc7a1e0, 0xc03eb58e00)
es_adapter_infradev_1  |    /usr/local/go/src/net/http/server.go:1847 +0x646
es_adapter_infradev_1  | created by net/http.(*Server).Serve
es_adapter_infradev_1  |    /usr/local/go/src/net/http/server.go:2851 +0x2f5

Best,

pwillie commented 5 years ago

This actually looks like an error on write. What version are you using?

Kanshiroron commented 5 years ago

Hey @pwillie, I was using the docker 'latest' version so it should be the last image before the version 6 you released some days ago. Best regards