diff --git a/components/perfdata/graphitewriter.cpp b/components/perfdata/graphitewriter.cpp index 331f62084..3adc0357e 100644 --- a/components/perfdata/graphitewriter.cpp +++ b/components/perfdata/graphitewriter.cpp @@ -169,10 +169,13 @@ void GraphiteWriter::SendPerfdata(const String& prefix, const CheckResult::Ptr& void GraphiteWriter::SendMetric(const String& prefix, const String& name, double value) { std::ostringstream msgbuf; - msgbuf << prefix << "." << name << " " << Convert::ToString(value) << " " << static_cast(Utility::GetTime()) << "\n"; + msgbuf << prefix << "." << name << " " << Convert::ToString(value) << " " << static_cast(Utility::GetTime()); + Log(LogDebug, "GraphiteWriter", "Add to metric list:'" + msgbuf.str() + "'."); + + // do not send \n to debug log + msgbuf << "\n"; String metric = msgbuf.str(); - Log(LogDebug, "GraphiteWriter", "GraphiteWriter: Add to metric list:'" + metric + "'."); ObjectLock olock(this);