MCPcopy Create free account
hub / github.com/Icinga/icinga2 / ExceptionHandler

Method ExceptionHandler

lib/perfdata/graphitewriter.cpp:147–159  ·  view source on GitHub ↗

* Exception handler for the WQ. * * Closes the connection if connected. * * @param exp Exception pointer */

Source from the content-addressed store, hash-verified

145 * @param exp Exception pointer
146 */
147void GraphiteWriter::ExceptionHandler(boost::exception_ptr exp)
148{
149 Log(LogCritical, "GraphiteWriter", "Exception during Graphite operation: Verify that your backend is operational!");
150
151 Log(LogDebug, "GraphiteWriter")
152 << "Exception during Graphite operation: " << DiagnosticInformation(std::move(exp));
153
154 if (GetConnected()) {
155 m_Stream->close();
156
157 SetConnected(false);
158 }
159}
160
161/**
162 * Reconnect method, stops when the feature is paused in HA zones.

Callers

nothing calls this directly

Calls 2

LogClass · 0.85
closeMethod · 0.80

Tested by

no test coverage detected