From 06a3c4a93522a73c7940d7bd2413a01aad685f88 Mon Sep 17 00:00:00 2001 From: Stewart Webb Date: Mon, 15 Jul 2024 19:56:16 +1000 Subject: [PATCH] in_opentelemetry: Propogate tag in http2 metrics and trace handlers Signed-off-by: Stewart Webb --- plugins/in_opentelemetry/opentelemetry_prot.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/in_opentelemetry/opentelemetry_prot.c b/plugins/in_opentelemetry/opentelemetry_prot.c index bfab3d02145..7b89902bf29 100644 --- a/plugins/in_opentelemetry/opentelemetry_prot.c +++ b/plugins/in_opentelemetry/opentelemetry_prot.c @@ -2242,7 +2242,7 @@ static int process_payload_metrics_ng(struct flb_opentelemetry *ctx, cfl_list_foreach(iterator, &decoded_contexts) { context = cfl_list_entry(iterator, struct cmt, _head); - result = flb_input_metrics_append(ctx->ins, NULL, 0, context); + result = flb_input_metrics_append(ctx->ins, tag, cfl_sds_len(tag), context); if (result != 0) { flb_plg_debug(ctx->ins, "could not ingest metrics context : %d", result); @@ -2301,7 +2301,7 @@ static int process_payload_traces_proto_ng(struct flb_opentelemetry *ctx, } if (result == 0) { - result = flb_input_trace_append(ctx->ins, NULL, 0, decoded_context); + result = flb_input_trace_append(ctx->ins, tag, cfl_sds_len(tag), decoded_context); ctr_decode_opentelemetry_destroy(decoded_context); } else {