deadtrickster / prometheus_rabbitmq_exporter

Prometheus.io exporter as a RabbitMQ Managment Plugin plugin
MIT License
291 stars 72 forks source link

Unnecessary manual dependency management steps #53

Closed michaelklishin closed 6 years ago

michaelklishin commented 6 years ago

According to the README, this is how the plugin should be enabled:

 rabbitmq-plugins enable accept
 rabbitmq-plugins enable prometheus
 rabbitmq-plugins enable prometheus_cowboy
 rabbitmq-plugins enable prometheus_httpd
 rabbitmq-plugins enable prometheus_rabbitmq_exporter

As of RabbitMQ 3.7.0 — which has been around for some 9 months now — dependencies such as prometheus_cowboy will not show up in the rabbitmq-plugins list unless they explicitly depend on the rabbit app.

Assuming correct dependency declaration in those projects, is it really necessary to ask the user to enable them explicitly, especially if only prometheus_rabbitmq_exporter would show up on the list?

deadtrickster commented 6 years ago

yes, people seems to be confused with this. But is enabling just prometheus_rabbitmq_exporter enough for 3.6.x? shouldn't I note that for this branch the rest of the plugins has to be enabled?

michaelklishin commented 6 years ago

As long as the plugin lists its dependencies (as in OTP apps) correctly, it should be.

gerhard commented 6 years ago

I can confirm that simply enabling prometheus_rabbitmq_exporter plugin in 3.6.x is sufficient.

deadtrickster commented 6 years ago

ok, thanks guys, cleaned up the readme!

gerhard commented 6 years ago

Having learned from rabbitmq/rabbitmq-website#583, rabbitmq-plugins enable prometheus_rabbitmq_exporter will only work as expected if the RabbitMQ node will be restarted, or when the node is not running and the --offline flag is used.

prometheus_cowboy & prometheus_httpd need to be enabled explicitly if the prometheus_rabbitmq_exporter plugin is enabled while the RabbitMQ node is running. If the node is restarted, these dependent applications will be started implicitly.

For full context, see rabbitmq/rabbitmq-website#583