aboutsummaryrefslogtreecommitdiff
path: root/src/zenserver/diag/logging.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/zenserver/diag/logging.cpp')
-rw-r--r--src/zenserver/diag/logging.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/zenserver/diag/logging.cpp b/src/zenserver/diag/logging.cpp
index 50cf62274..90af79651 100644
--- a/src/zenserver/diag/logging.cpp
+++ b/src/zenserver/diag/logging.cpp
@@ -12,6 +12,8 @@
#include <zenutil/logging.h>
#include <zenutil/logging/rotatingfilesink.h>
+#include "otlphttp.h"
+
ZEN_THIRD_PARTY_INCLUDES_START
#include <spdlog/spdlog.h>
ZEN_THIRD_PARTY_INCLUDES_END
@@ -73,6 +75,16 @@ InitializeServerLogging(const ZenServerConfig& InOptions)
spdlog::apply_logger_env_levels(ZenClientLogger);
spdlog::register_logger(ZenClientLogger);
+ //
+
+#if ZEN_WITH_OTEL
+ if (false)
+ {
+ auto OtelSink = std::make_shared<zen::logging::OtelHttpProtobufSink>("http://signoz.localdomain:4318");
+ zen::logging::Default().SpdLogger->sinks().push_back(std::move(OtelSink));
+ }
+#endif
+
FinishInitializeLogging(LogOptions);
const zen::Oid ServerSessionId = zen::GetSessionId();