-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Add input to collect http data using any parser #813
Comments
I don't know whether I understand you correct or not, but you want Telegraf call HTTP endpoints that return data formatted according to InfluxDB's line protocol? You could use the exec input plugin.
|
Yes. I'm sure it sounds odd at first blush, but I'll point out that telegraf is useful beyond collection and forwarding of metrics. It's the best so far, IMO, at providing a metrics router that allows external tools to intermingle data that most services or libraries don't want or need to be concerned with. For instance, we use ansible to drop data into the telegraf include dirs that merges inventory data like machines groups, tags, state, and other k/v data into metrics as they flow through--sub in any other config management or service discovery for similar approaches. I was originally looking to heka for it's general purpose message router to mix in arbitrary data, but telegraf reads and writes to so many of the systems we use and in a metrics format that makes the most sense. Given this approach, it makes sense for services to choose the influx line format regardless of whether they choose to push or pull. something like [[inputs.httpprobe]]
data_format = "influx"
servers = [
"http://my.service.com/_stats"
] I'm happy to whip up a PR in the next week if it sounds like an acceptable idea. |
I don't quite understand this line:
An input plugin fetches metrics from a source every once in a while. I think this is what you mean with 'pull'. The A service input plugin is a special type of input plugin which runs in the background. This type of plugin can be used by externel tools to push metrics to. An example is the TCP Listener. This service input plugin listens on a port for metrics. Would this plugin, or a new HTTP Listener plugin, solve your problem? |
On Wed, Mar 9, 2016 at 1:32 AM Auke Willem Oosterhoff <
Sorry, in my case, 'service' means a server we at imgix authored and want
|
this seems fine to me, basically you want the httpjson plugin to be able to scrape any data format, correct? You should be able to take the httpjson plugin, rename it something like |
Yeah, that sounds good. Something like |
I think we should just name this |
We have services that have implemented native influxdb data formats and expose them at scrapable endpoints. Instead of pushing these values directly to influxdb, we want telegraf to grab them which gives us all the flexibility that telegraf provides: prometheus scrape endpoint, kafka push, nsq, or push to influxdb.
Is there no way to scrape influx's native format?
The text was updated successfully, but these errors were encountered: