Skip to content
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

Allow notifiers to receive metrics regardless of consumer group status #341

Open
gustavosoares opened this issue Jan 30, 2018 · 3 comments

Comments

@gustavosoares
Copy link

We currently have a working fork where we implemented two additional notifiers: one to push metrics to AWS CloudWatch [1] and another one to push metrics to dogstatsd 2.

Long story short, here at Vend we have a containerised driven architecture leveraged on AWS ECS and we wanted a way to be able to autoscale our consumers based on consumer lag. AWS Application autoscaling does not work well with sparse metric, which means that we need to push every single metric to cloudwatch regardless of the consumer status. As of [2], we push all metrics to dogstatsd so we can plot nice consumer lag graphs and also to create some monitors that may eventually trigger pagerduty if a consumer lag goes over a defined threshold.

Having said that ^^, at the moment there is no elegant way to enable ShowAll per notifier. Since we don't care about any other notifier we simply added ShowAll: True to https://github.com/linkedin/Burrow/blob/master/core/internal/notifier/coordinator.go#L375

					go func(sendCluster string, sendConsumer string) {
						nc.App.EvaluatorChannel <- &protocol.EvaluatorRequest{
							Reply:   nc.evaluatorResponse,
							Cluster: sendCluster,
							Group:   sendConsumer,
							ShowAll: true,
						}
					}(cluster, consumer)

The aforementioned approach is not ideal should we wish to push those two custom notifiers to upstream and on top of that it makes merging off upstream a bit cumbersome sometimes.

Please advise on what the best approach would be to address the above scenario.

@StevenACoffman
Copy link

In Kubernetes, using the Custom Metrics Adapter for Prometheus means we can horizontally autoscale consumers on arbitrary metrics that we already collect with Prometheus, such as consumer lag using Burrow. I'm not sure if anyone has already done this, but I'm looking for examples, and this is the closest mention I've been able to find.

@daodennis-zz
Copy link
Contributor

daodennis-zz commented Feb 9, 2018 via email

@nickdevp
Copy link

This seems like a bug instead of an enhancement. Notifier configuration has a 'threshold' property, which already indicates if StatusOK messages should be sent out. Shouldn't the threshold property be used in the evaluation request 'ShowAll' flag? IE: ShowAll = (threshold == StatusOK)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants