Skip to content
This repository has been archived by the owner on Mar 9, 2022. It is now read-only.

Prometheus protocol support #54

Merged
merged 7 commits into from
Mar 21, 2018
Merged

Conversation

mjs
Copy link
Contributor

@mjs mjs commented Mar 20, 2018

This pull request implements lightweight functionality for parsing, collecting and emitting Prometheus protocol metric lines. This is implemented inside influx-spout instead of using the official packages because the official APIs and data structures don't fit our monitor use case well and they pull in a significant amount of unnecessary code.

This functionality will be used in the upcoming monitor component (see #29) to receive and collect operational metrics from the various influx-spout components and make them available to Prometheus.

Noteworthy:

  • filter.fastParseInt has been moved to convert.ToInt as it was useful for the prometheus protocol code
  • testify has been updated to 1.2.1 so that we have access to some useful new assertion helpers (ElementsMatch in particular)

mjs added 7 commits March 20, 2018 13:33
Metrics will get to the monitor component using the Promethesus
protocol.
This has been extracted so that it can be used outside of the filter
package.
These are going to be need from multiple places within influx-spout.
There's some newer assertion helpers which are quite
useful (particularly ElementsMatch).
This data structure holds a collection of metrics, allowing for
updates which override earlier versions of a metric.
@mjs mjs requested a review from oplehto March 20, 2018 10:09
Copy link
Contributor

@oplehto oplehto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@oplehto oplehto merged commit a910bad into jumptrading:master Mar 21, 2018
@mjs mjs deleted the prometheus-protocol branch March 21, 2018 02:35
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants