-
Notifications
You must be signed in to change notification settings - Fork 107
add feature to configurate promhttp error handling #411
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
base: master
Are you sure you want to change the base?
add feature to configurate promhttp error handling #411
Conversation
Signed-off-by: Nikita Popov <[email protected]>
b5a9fc6
to
9bfc60d
Compare
cc: @SuperQ @kgeckhart |
I'm not sure we should do this, if there are errors, we don't want to silently ignore them. They should be fixed. |
First of all, promlib has that option, and it looks convenient to have it here. And user is able to define how he wants to handle errors. Google API has many errors, which couldn't be fixed as simple, as their support is not an example of the fast or customer-faced approach, we have a lot of examples when they deployed some descriptors in BETA stage and exporter has started to fail. So this setting is a good way to save collecting metrics which can be collected. The problem we are trying to solve is similar to this Also this exporter has metrics to identify such errors, so users still noticed about them only if provided setting is As i mentioned, the default behaviour is still the same. P.S. Now we are using forked version with this setting and everything goes fine, we haven't lose any metrics we expected, the exporter returns it's own metrics in any case and we notified if any problems happened |
The problem is that the linked error is an actual problem. By ignoring errors like that you're not going to get the data you expect. This is a correctness problem that I don't think we want to paper over.
Are you sure about that? Because the linked issue is very likely to be a real problem. |
This is a very bad idea. Partial data is very difficult to track and debug. This is why the default behavior is the way it is. As well as when Prometheus polls targets it treats any non-200 status code or timeout as "no data". This violates "fail fast" principal and is not something we are likely to want to put in an official exporter without some serious discussion. |
Yes. In the Obviously that we can split
I completely agree with that. But as i said above, for us it's not okay to have "no data" when we can have "some non-broken data".
Usually those metrics are broken on Google side and they in some |
Motivation
The current implementation uses PromHTTP's default error handling, which may not suit all deployment scenarios. By allowing customization, users can:
ContinueOnError
) in high-availability environments.Default Behavior