Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upadding support for generic service discovery #4041
Comments
This comment has been minimized.
This comment has been minimized.
|
We already have support for generic service discovery via file_sd_config, it doesn't make sense to have two of them. You can use a cronjob to lay down the file for example. |
brian-brazil
closed this
Apr 4, 2018
This comment has been minimized.
This comment has been minimized.
|
This is mostly an aside but I am interested to note that this has come up here and #1675, #2514, #3602, and #3658. I get that you can automate file_sd_discovery with a cronjob but I think there is actually a use case here, especially for folks in service provider, enterprise, multi-tenant situations. Obviously, Prometheus can't be everything to everyone but occasionally I think there's a persistent pain point that appears that might be worth revisiting. |
This comment has been minimized.
This comment has been minimized.
|
This has been discussed multiple times. We only want one generic way to do things, and have to presume that users have basic infrastructure otherwise we end up expanding being just being a monitoring system. |
This comment has been minimized.
This comment has been minimized.
|
we have discussed this in the group and based on the user's feedback so far http vs file sd doesn't seem to offer much benefits. if your use case is different you can post it in the group and it will be considered. |
This comment has been minimized.
This comment has been minimized.
|
@brian-brazil I guess that it has been discussed so many times is my point. :) And I get the issue of scope creep. Perhaps, in light of the thoughts in https://github.com/prometheus/prometheus/tree/master/discovery, the discussion might be moot in a pluggable SD world? But as I said - an aside. |
This comment has been minimized.
This comment has been minimized.
|
It is pluggable already - via file SD configs. I'm not inclined to add features that could be handled by users by a few lines of shell. |
This comment has been minimized.
This comment has been minimized.
|
@krasi-georgiev I do worry about that though. The previous discussions on this have been shut down pretty fast. I can perhaps see why users with specific use cases might not be so forthcoming. There's a definite "our way or nothing" feel to some of the discussions on Prometheus design. I don't fundamentally have a problem with that approach; a lot of software has been successful because of the adopting that model. Solomon saying no to lots of ideas in early Docker is a good example. :) But it does tend to sometimes stifle discussion or desire to discuss. |
This comment has been minimized.
This comment has been minimized.
|
@brian-brazil Sure. I think Prometheus has a pretty clear idea of who its user is and you're likely correct in assuming folks can solve it that way. I certainly did. :) |
This comment has been minimized.
This comment has been minimized.
It's not really possible to give the same level of explanation the 20th time a discussion comes up versus the 1st. To me this matter was settled years ago. You might have noticed those 5 issues, I've seen all of them. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
@brian-brazil It was a concern more than a critique. I've definitely been in your shoes - there was a time I could remember every ticket logged about Puppet. That view does sometimes assume nothing changes in the meantime about the tool, environments, ecosystems, etc. Then that can sometimes create a fine line between being open to new ideas and dictating "not invented here". But this is the wrong place for that discussion. Definitely involves buying drinks! Cheers. |
This comment has been minimized.
This comment has been minimized.
|
@krasi-georgiev Thanks - interesting read! |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
Anyone who can write a service to expose an HTTP api can make it write to disk instead. |
This comment has been minimized.
This comment has been minimized.
|
@krasi-georgiev of corse it can be solved with file sd and a cron job. it would just have been nice use a http endpoint instead. i wouldn't mind to have spent the time to implement it either. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
ghadishayban
commented
May 29, 2018
Very true @brian-brazil . That's how I've done it for a while. I think a lot of other users see the cron to disk as workable but duct-tapey. File_sd is so close to a data API but I think people would like to point the daemon to http://something/inventory and get out of the business of cron and file manip (especially when running in k8s or AWS Fargate and scraping external inventory) |
This comment has been minimized.
This comment has been minimized.
|
@ghadishayban I started the same discussion a while back and it seems that while your use case is valid other uses suggest file_sd as better suited. Feel free to add your use case to the discussion though. |
This comment has been minimized.
This comment has been minimized.
lock
bot
commented
Mar 22, 2019
|
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
mad01 commentedApr 4, 2018
•
edited
idea
adding support for a generic SD (service discovery) interface like using the same format as
file_sd_configbut as SD over http.usecase
you have a existing SD (service discovery) solution not supported and like to write a small service to bridge yours to still work with prometheus.
implementation
/targetsGETwith a payload of json same asfile_sd_config[ { "targets": [ "node:9104" ], "labels": { "env": "prod", "job": "service" } } ]