diff --git a/plugins/inputs/jolokia2/gatherer.go b/plugins/inputs/jolokia2/gatherer.go index 5b2aa00d8..f24918998 100644 --- a/plugins/inputs/jolokia2/gatherer.go +++ b/plugins/inputs/jolokia2/gatherer.go @@ -88,8 +88,8 @@ func (g *Gatherer) generatePoints(metric Metric, responses []ReadResponse) ([]po case 404: continue default: - errors = append(errors, fmt.Errorf("Unexpected status in response from target %s: %d", - response.RequestTarget, response.Status)) + errors = append(errors, fmt.Errorf("Unexpected status in response from target %s (%q): %d", + response.RequestTarget, response.RequestMbean, response.Status)) continue }