SoftInstigate / restheart

Rapid API Development with MongoDB
https://restheart.org
GNU Affero General Public License v3.0
805 stars 171 forks source link

Prometheus Integration #293

Closed marcelinhov2 closed 6 years ago

marcelinhov2 commented 6 years ago

I tried to plug Prometheus to monitoring my RestHeart API but I'm getting a parse error:

level=warn ts=2018-06-21T21:12:52.174717536Z caller=scrape.go:713 component="scrape manager" scrape_pool="General RestHeart" target=http://xx.xx.xx.xx:80/google/_metrics msg="append failed" err="strconv.ParseFloat: parsing \"milliseconds\": invalid syntax"

Does anyone know how can I fix it?

Thanks guys!

ujibang commented 6 years ago

Hi @lenalebt,

can you help @marcelinhov2 on this?

marcelinhov2 commented 6 years ago

any update?

Thanks!

lenalebt commented 6 years ago

Hi, sorry - somehow that mail got sorted as Spam :(. Yep, here to assist. I need to admit that we're currently using the JSON version and the prometheus version was more like a textbook implementation and direct translation from the JSON version. Having a look at the example I think it's a problem that the units are written as String, and Prometheus only supports numbers - I could have gotten that. I will provide a fix.

mkjsix commented 6 years ago

The fix is available on both 3.4.0-SNAPSHOT and 3.3.7-SNAPSHOT.

marcelinhov2 commented 6 years ago

Great. In time, do you guys have any Grafana Dashboard ready to receive this data?

mkjsix commented 6 years ago

Besides 3.4.0-SNAPSHOT and 3.3.8-SNAPSHOT, this fix is now available in stable release RESTHeart 3.3.7.

As usual, Docker images are available here.

mkjsix commented 6 years ago

@marcelinhov2 about Grafana: sorry but we don't have any dashboard. If you find / build anything please let us know.