You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Slave lag zero (and other zero values) not picked up by collectd? #14
I figured it out why slave lag 0 was not being sent.
492 def dispatch_value(prefix, key, value, type, type_instance=None):
493 if not type_instance:
494 type_instance = key
495
496 log_verbose('Sending value: %s/%s=%s' % (prefix, type_instance, value))
497 if not value:
498 return
499 try:
500 value = int(value)
501 except ValueError:
502 value = float(value)
503
504 val = collectd.Values(plugin='mysql', plugin_instance=prefix)
505 val.type = type
506 val.type_instance = type_instance
507 val.values = [value]
508 val.dispatch()
Line 497, value 0 is caught and a return is issued, causing metrics (slave_lag) with values of 0 to not be sent. If I comment out 497 and 498, the value goes through.
Activity
msims-okta commentedon Dec 15, 2016
I figured it out why slave lag 0 was not being sent.
Line 497, value 0 is caught and a return is issued, causing metrics (slave_lag) with values of 0 to not be sent. If I comment out 497 and 498, the value goes through.
cswingler commentedon Dec 19, 2016
I submitted PR #17 to help address this earlier today
msims-okta commentedon Dec 27, 2016
Ok cool. I haven't had time to figure out why it was getting caught there, though.
Edit: Never mind I see your PR and get it now.