using namespace icinga;
+std::atomic<bool> ApiListener::m_UpdatedObjectAuthority (false);
+
void ApiListener::UpdateObjectAuthority()
{
/* Always run this, even if there is no 'api' feature enabled. */
object->SetAuthority(authority);
}
}
+
+ m_UpdatedObjectAuthority.store(true);
}
#include "base/tcpsocket.hpp"
#include "base/tlsstream.hpp"
#include "base/threadpool.hpp"
+#include <atomic>
#include <boost/asio/ip/tcp.hpp>
#include <boost/asio/spawn.hpp>
#include <boost/asio/ssl/context.hpp>
static String GetDefaultKeyPath();
static String GetDefaultCaPath();
+ static inline
+ bool UpdatedObjectAuthority()
+ {
+ return m_UpdatedObjectAuthority.load();
+ }
+
double GetTlsHandshakeTimeout() const override;
void SetTlsHandshakeTimeout(double value, bool suppress_events, const Value& cookie) override;
Endpoint::Ptr m_LocalEndpoint;
static ApiListener::Ptr m_Instance;
+ static std::atomic<bool> m_UpdatedObjectAuthority;
void ApiTimerHandler();
void ApiReconnectTimerHandler();