mirror of
https://github.com/Icinga/icinga2.git
synced 2025-04-08 17:05:25 +02:00
LivestatusQuery#Execute(): take CheckResultProducer::Ptr
This commit is contained in:
parent
0f5714fda6
commit
657850c74b
@ -193,7 +193,7 @@ void LivestatusListener::ClientHandler(const Socket::Ptr& client)
|
||||
break;
|
||||
|
||||
LivestatusQuery::Ptr query = new LivestatusQuery(lines, GetCompatLogPath());
|
||||
if (!query->Execute(stream))
|
||||
if (!query->Execute(this, stream))
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -621,7 +621,7 @@ void LivestatusQuery::PrintFixed16(const Stream::Ptr& stream, int code, const St
|
||||
}
|
||||
}
|
||||
|
||||
bool LivestatusQuery::Execute(const Stream::Ptr& stream)
|
||||
bool LivestatusQuery::Execute(const CheckResultProducer::Ptr& producer, const Stream::Ptr& stream)
|
||||
{
|
||||
try {
|
||||
Log(LogNotice, "LivestatusQuery")
|
||||
@ -630,7 +630,7 @@ bool LivestatusQuery::Execute(const Stream::Ptr& stream)
|
||||
if (m_Verb == "GET")
|
||||
ExecuteGetHelper(stream);
|
||||
else if (m_Verb == "COMMAND")
|
||||
ExecuteCommandHelper(stream);
|
||||
ExecuteCommandHelper(producer, stream);
|
||||
else if (m_Verb == "ERROR")
|
||||
ExecuteErrorHelper(stream);
|
||||
else
|
||||
|
@ -34,7 +34,7 @@ public:
|
||||
|
||||
LivestatusQuery(const std::vector<String>& lines, const String& compat_log_path);
|
||||
|
||||
bool Execute(const Stream::Ptr& stream);
|
||||
bool Execute(const CheckResultProducer::Ptr& producer, const Stream::Ptr& stream);
|
||||
|
||||
static int GetExternalCommands();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user