From 58601e5d75872e8302b0806347dd1ad942713138 Mon Sep 17 00:00:00 2001 From: Daniel Piddock <30546489+dpiddock@users.noreply.github.com> Date: Sat, 8 Jun 2024 10:32:12 +0200 Subject: [PATCH] Fix for OtlpGrpcExporterOptions in >=1.13.0 (#451) --- instrumentation/nginx/src/otel_ngx_module.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/instrumentation/nginx/src/otel_ngx_module.cpp b/instrumentation/nginx/src/otel_ngx_module.cpp index fa303dcae..c69a545a1 100644 --- a/instrumentation/nginx/src/otel_ngx_module.cpp +++ b/instrumentation/nginx/src/otel_ngx_module.cpp @@ -1021,7 +1021,8 @@ static std::unique_ptr CreateExporter(const OtelNgxAgent switch (conf->exporter.type) { case OtelExporterOTLP: { std::string endpoint = conf->exporter.endpoint; - otlp::OtlpGrpcExporterOptions opts{endpoint}; + otlp::OtlpGrpcExporterOptions opts; + opts.endpoint = endpoint; opts.use_ssl_credentials = conf->exporter.use_ssl_credentials; opts.ssl_credentials_cacert_path = conf->exporter.ssl_credentials_cacert_path; exporter.reset(new otlp::OtlpGrpcExporter(opts));