Skip to content

out_logdna: remove promoted known keys#11755

Merged
lecaros merged 2 commits intomasterfrom
lecaros-logdna-remove-known-keys
May 5, 2026
Merged

out_logdna: remove promoted known keys#11755
lecaros merged 2 commits intomasterfrom
lecaros-logdna-remove-known-keys

Conversation

@lecaros
Copy link
Copy Markdown
Contributor

@lecaros lecaros commented Apr 28, 2026

The out_logdna plugin promotes certain record keys (meta, level/severity, file, app) to top-level fields in the ingest payload, but also serializes the entire record — including those same keys — as JSON into the line field. This causes Mezmo to display duplicate entries (e.g. both meta and _meta) in the log viewer.

This PR adds a new boolean option exclude_promoted_keys (default: false) that, when enabled, strips the promoted keys from the line body. The default preserves backward compatibility.

Addresses #11754

Testing
Before we can approve your change; please submit the following in a comment:

  • Example configuration file for the change
  • Debug log output from testing the change
  • Attached Valgrind output that shows no leaks or memory corruption was found
Logs

valgrind --leak-check=yes $FBIT_HOME/fluent-bit -c config.yml
==108281== Memcheck, a memory error detector
==108281== Copyright (C) 2002-2022, and GNU GPL'd, by Julian Seward et al.
==108281== Using Valgrind-3.19.0 and LibVEX; rerun with -h for copyright info
==108281== Command: /home/lecaros/fluent-bit/build/bin/fluent-bit -c config.yml
==108281==
Fluent Bit v5.0.4
* Copyright (C) 2015-2026 The Fluent Bit Authors
* Fluent Bit is a CNCF graduated project under the Fluent organization
* https://fluentbit.io

______ _                  _    ______ _ _           _____  _____
|  ___| |                | |   | ___ (_) |         |  ___||  _  |
| |_  | |_   _  ___ _ __ | |_  | |_/ /_| |_  __   _|___ \ | |/' |
|  _| | | | | |/ _ \ '_ \| __| | ___ \ | __| \ \ / /   \ \|  /| |
| |   | | |_| |  __/ | | | |_  | |_/ / | |_   \ V //\__/ /\ |_/ /
\_|   |_|\__,_|\___|_| |_|\__| \____/|_|\__|   \_/ \____(_)\___/


[2026/04/28 15:35:48.678] [ info] [fluent bit] version=5.0.4, commit=69dd8871b6, pid=108281
[2026/04/28 15:35:48.742] [ info] [storage] ver=1.5.4, type=memory, sync=normal, checksum=off, max_chunks_up=128
[2026/04/28 15:35:48.743] [ info] [simd    ] disabled
[2026/04/28 15:35:48.744] [ info] [cmetrics] version=2.1.2
[2026/04/28 15:35:48.744] [ info] [ctraces ] version=0.7.1
[2026/04/28 15:35:48.777] [ info] [input:dummy:dummy.0] initializing
[2026/04/28 15:35:48.778] [ info] [input:dummy:dummy.0] storage_strategy='memory' (memory only)
[2026/04/28 15:35:49.748] [ info] [output:logdna:logdna.1] configured, hostname=(null)
[2026/04/28 15:35:49.761] [ info] [sp] stream processor started
[2026/04/28 15:35:49.766] [ info] [engine] Shutdown Grace Period=5, Shutdown Input Grace Period=2
[2026/04/28 15:35:49.785] [ info] [output:stdout:stdout.0] worker #0 started
==108281== Warning: client switching stacks?  SP change: 0x5ead998 --> 0x55a7180
==108281==          to suppress, use: --max-stackframe=9463832 or greater
==108281== Warning: client switching stacks?  SP change: 0x55a7068 --> 0x5ead998
==108281==          to suppress, use: --max-stackframe=9464112 or greater
==108281== Warning: client switching stacks?  SP change: 0x6f2faf8 --> 0x55ad530
==108281==          to suppress, use: --max-stackframe=26748360 or greater
==108281==          further instances of this message will not be shown.
[0] dummy.0: [[1777390552.079481297, {}], {"message"=>"dummy", "meta"=>{"kubernetes"=>{"container_hash"=>"deadbeef", "pod_name"=>"demo-pod", "container_name"=>"demo-container", "docker_id"=>"a000000000000000000000000000000000000000000000000000000000000000", "annotations"=>{"kubernetes.io/limit-ranger"=>"LimitRanger plugin set: cpu, memory for the namespace"}, "pod_id"=>"11111111-1111-1111-1111-111111111111", "namespace_name"=>"demo-namespace", "host"=>"demo-node", "container_image"=>"docker.io/library/demo:1.0", "pod_ip"=>"10.0.0.1", "labels"=>{"app.kubernetes.io/name"=>"demo", "app.kubernetes.io/instance"=>"demo-pod"}}}, "other_field"=>"other_value"}]
[2026/04/28 15:35:53.409] [error] [output:logdna:logdna.1] no upstream connections available
[2026/04/28 15:35:53.435] [ warn] [engine] failed to flush chunk '108281-1777390552.192489882.flb', retry in 11 seconds: task_id=0, input=dummy.0 > output=logdna.1 (out_id=1)
^C[2026/04/28 15:35:54] [engine] caught signal (SIGINT)
[2026/04/28 15:35:54.714] [ warn] [engine] service will shutdown in max 5 seconds
[2026/04/28 15:35:54.719] [ info] [engine] pausing all inputs..
[2026/04/28 15:35:54.721] [ info] [input] pausing dummy.0
[2026/04/28 15:35:54.736] [error] [output:logdna:logdna.1] no upstream connections available
[2026/04/28 15:35:54.741] [error] [engine] chunk '108281-1777390552.192489882.flb' cannot be retried: task_id=0, input=dummy.0 > output=logdna.1
[2026/04/28 15:35:55.079] [ info] [engine] service has stopped (0 pending tasks)
[2026/04/28 15:35:55.079] [ info] [input] pausing dummy.0
[2026/04/28 15:35:55.097] [ info] [output:stdout:stdout.0] thread worker #0 stopping...
[2026/04/28 15:35:55.105] [ info] [output:stdout:stdout.0] thread worker #0 stopped
==108281==
==108281== HEAP SUMMARY:
==108281==     in use at exit: 0 bytes in 0 blocks
==108281==   total heap usage: 13,215 allocs, 13,215 frees, 2,641,090 bytes allocated
==108281==
==108281== All heap blocks were freed -- no leaks are possible
==108281==
==108281== For lists of detected and suppressed errors, rerun with: -s
==108281== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)

Config:

service:
  flush: 1
  log_level: info

pipeline:
  inputs:
      tag: test
      dummy: '{"message":"hello","meta":{"env":"prod"},"level":"info","app":"myapp"}'

  outputs:
    - name: logdna
      match: test
      logdna_host: logs.logdna.com
      api_key: YOUR_API_KEY
      hostname: test-host
      exclude_promoted_keys: true

Test output:

$ ./bin/flb-rt-out_logdna
Test non_duplication...                         [ OK ]
Test data_completeness...                       [ OK ]
Test severity_promoted_as_level...              [ OK ]
Test default_app...                             [ OK ]
Test no_primary_keys...                         [ OK ]
Test payload_structure...                       [ OK ]
Test backward_compat...                         [ OK ]
Test lifecycle...                               [ OK ]
SUCCESS: All unit tests have passed.

If this is a change to packaging of containers or native binaries then please confirm it works for all targets.

  • [N/A] Run local packaging test showing all targets (including any new ones) build.
  • [N/A] Set ok-package-test label to test for all targets (requires maintainer to do).

Documentation

Backporting

  • Backport to latest stable release.


    Fluent Bit is licensed under Apache 2.0, by submitting this pull request I understand that this code will be released under the terms of that license.

Summary by CodeRabbit

  • New Features

    • Added option to exclude promoted primary keys (meta, level/severity, app) from the escaped "line", promoting them to top-level to avoid duplication and reduce payload noise.
    • Payload composition now places only non-primary data into the escaped "line".
    • Exposes a formatter test callback to retrieve composed payloads for testing.
  • Tests

    • Added runtime tests verifying payload structure, key promotion/exclusion behavior, severity/level semantics, backward compatibility, and lifecycle stability.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 28, 2026

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

The LogDNA output plugin adds an exclude_promoted_keys config and changes payload composition to optionally exclude promoted primary keys from the JSON "line" body by packing non-promoted pairs into a separate buffer. A test_formatter callback and runtime tests for these behaviors were added.

Changes

Cohort / File(s) Summary
LogDNA plugin implementation
plugins/out_logdna/logdna.c, plugins/out_logdna/logdna.h
Added exclude_promoted_keys to struct flb_logdna; extended record_append_primary_keys to accept an optional packer for non-primary pairs; logdna_compose_payload conditionally builds/uses a separate msgpack buffer and converts only non-promoted pairs to JSON for the "line" field; registered .test_formatter.callback = cb_logdna_format_test.
Runtime tests & build
tests/runtime/out_logdna.c, tests/runtime/CMakeLists.txt
Added comprehensive runtime tests exercising promotion, exclusion, precedence, defaulting, payload structure, backward compatibility, and lifecycle; updated CMakeLists to include the new test program.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Poem

🐰 I hop through msgpack, tidy and bright,
I lift top keys out into the light,
The rest curl safe inside their line,
Tests count my hops and say "design!"
A rabbit cheers: payloads just right.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 16.67% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically summarizes the main change: adding functionality to remove/exclude promoted keys from the LogDNA output payload.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch lecaros-logdna-remove-known-keys

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 69dd8871b6

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread plugins/out_logdna/logdna.c Outdated
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
plugins/out_logdna/logdna.c (1)

251-271: ⚠️ Potential issue | 🔴 Critical

Guard unpack/JSON conversion failures before using line_json.

At line 254, msgpack_unpack_next() result is not checked; at line 268, strlen(line_json) dereferences without verifying the JSON conversion succeeded. Both can fail (returning error codes or NULL), causing crashes on malformed input or memory allocation failure.

Proposed fix
         if (ctx->exclude_promoted_keys) {
             msgpack_unpacked_init(&mp_line_result);
             off = 0;
-            msgpack_unpack_next(&mp_line_result,
-                                mp_line_sbuf.data, mp_line_sbuf.size, &off);
+            ret = msgpack_unpack_next(&mp_line_result,
+                                      mp_line_sbuf.data, mp_line_sbuf.size, &off);
+            if (ret != MSGPACK_UNPACK_SUCCESS) {
+                msgpack_unpacked_destroy(&mp_line_result);
+                msgpack_sbuffer_destroy(&mp_line_sbuf);
+                flb_plg_error(ctx->ins, "could not unpack filtered line payload");
+                flb_log_event_decoder_destroy(&log_decoder);
+                msgpack_sbuffer_destroy(&mp_sbuf);
+                return NULL;
+            }
 
             line_json = flb_msgpack_to_json_str(1024, &mp_line_result.data,
                                                 config->json_escape_unicode);
             msgpack_unpacked_destroy(&mp_line_result);
             msgpack_sbuffer_destroy(&mp_line_sbuf);
         } else {
             line_json = flb_msgpack_to_json_str(1024, log_event.body,
                                                 config->json_escape_unicode);
         }
 
+        if (!line_json) {
+            flb_plg_error(ctx->ins, "could not serialize line payload");
+            flb_log_event_decoder_destroy(&log_decoder);
+            msgpack_sbuffer_destroy(&mp_sbuf);
+            return NULL;
+        }
+
         len = strlen(line_json);
🧹 Nitpick comments (1)
tests/runtime/out_logdna.c (1)

98-606: Consider extracting a shared test harness helper.

Setup/start/push/wait/assert/stop/destroy is repeated across many tests; a small helper would reduce drift and simplify future additions.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/runtime/out_logdna.c` around lines 98 - 606, Many tests repeat the
identical lifecycle (clear_output_num; flb_create + flb_service_set; flb_input +
flb_input_set; flb_output + flb_output_set; flb_output_set_test; flb_start;
flb_lib_push; sleep + assert get_output_num; flb_stop; flb_destroy); extract a
small helper (e.g., run_logdna_test or execute_test_flow) that accepts the JSON
payload, the formatter callback (cb_check_*), output config args (like
"exclude_promoted_keys"), and any expected-wait duration, and moves the common
sequence into that helper using the existing symbols flb_create,
flb_service_set, flb_input, flb_input_set, flb_output, flb_output_set,
flb_output_set_test, flb_start, flb_lib_push,
clear_output_num/get_output_num/set_output_num, flb_stop and flb_destroy;
replace each flb_test_* function body with a single call to the helper passing
the proper JSON and callback to reduce duplication and keep per-test differences
minimal.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@plugins/out_logdna/logdna.c`:
- Around line 658-662: Update the config help text for the FLB_CONFIG_MAP_BOOL
entry named "exclude_promoted_keys" (in struct flb_logdna) to explicitly mention
that it also excludes the promoted "severity" field (promoted as "level"); keep
the rest of the description but add ", severity (promoted as level)" or
equivalent phrasing so the behavior is clear to users.

---

Nitpick comments:
In `@tests/runtime/out_logdna.c`:
- Around line 98-606: Many tests repeat the identical lifecycle
(clear_output_num; flb_create + flb_service_set; flb_input + flb_input_set;
flb_output + flb_output_set; flb_output_set_test; flb_start; flb_lib_push; sleep
+ assert get_output_num; flb_stop; flb_destroy); extract a small helper (e.g.,
run_logdna_test or execute_test_flow) that accepts the JSON payload, the
formatter callback (cb_check_*), output config args (like
"exclude_promoted_keys"), and any expected-wait duration, and moves the common
sequence into that helper using the existing symbols flb_create,
flb_service_set, flb_input, flb_input_set, flb_output, flb_output_set,
flb_output_set_test, flb_start, flb_lib_push,
clear_output_num/get_output_num/set_output_num, flb_stop and flb_destroy;
replace each flb_test_* function body with a single call to the helper passing
the proper JSON and callback to reduce duplication and keep per-test differences
minimal.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 4f3df5f1-449e-4b6b-bfba-8d3613d74181

📥 Commits

Reviewing files that changed from the base of the PR and between 7a27254 and 69dd887.

📒 Files selected for processing (4)
  • plugins/out_logdna/logdna.c
  • plugins/out_logdna/logdna.h
  • tests/runtime/CMakeLists.txt
  • tests/runtime/out_logdna.c

Comment thread plugins/out_logdna/logdna.c
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (2)
tests/runtime/out_logdna.c (2)

133-137: Replace fixed sleep(...) with a bounded poll helper to reduce flakiness and runtime.

Using fixed sleeps can be brittle on slow/fast CI and adds avoidable delay. A short polling loop with timeout (e.g., check get_output_num() every 100ms) makes these tests more deterministic.

Also applies to: 234-238, 305-309, 369-373, 451-455, 518-522, 598-602, 642-644

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/runtime/out_logdna.c` around lines 133 - 137, Replace the fixed
sleep(2) with a bounded polling helper that repeatedly checks get_output_num()
(e.g., every 100ms) until a short timeout (e.g., 2–5s) and then asserts via
TEST_CHECK/TEST_MSG if no output; add a helper function (e.g.,
poll_until_output_or_timeout) used in place of sleep calls so the test uses
get_output_num() as the success condition and returns early on success to reduce
flakiness; make sure to update all similar occurrences that currently sleep and
then call TEST_CHECK/TEST_MSG to use this helper.

98-141: Consider extracting a shared test harness for setup/start/push/assert/teardown.

The repeated boilerplate makes maintenance harder and increases the chance of drift between scenarios. A helper that accepts input JSON, output options, and formatter callback would keep these cases concise and consistent.

Also applies to: 199-242, 270-313, 335-377, 417-459, 484-526, 564-606

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/runtime/out_logdna.c` around lines 98 - 141, Extract the repeated
setup/start/push/assert/teardown sequence in tests like flb_test_non_duplication
into a shared helper (e.g., run_logdna_test) that encapsulates flb_create +
flb_service_set, flb_input/flb_input_set, flb_output/flb_output_set,
flb_output_set_test, flb_start, flb_lib_push, sleep/assert via get_output_num,
and flb_stop/flb_destroy; change each test to call this helper with parameters
for input JSON, output options (api_key, exclude_promoted_keys, match, etc.),
and the formatter callback (cb_check_non_duplication) so all boilerplate is
centralized and tests only pass the differing inputs and assertions.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@tests/runtime/out_logdna.c`:
- Around line 133-137: Replace the fixed sleep(2) with a bounded polling helper
that repeatedly checks get_output_num() (e.g., every 100ms) until a short
timeout (e.g., 2–5s) and then asserts via TEST_CHECK/TEST_MSG if no output; add
a helper function (e.g., poll_until_output_or_timeout) used in place of sleep
calls so the test uses get_output_num() as the success condition and returns
early on success to reduce flakiness; make sure to update all similar
occurrences that currently sleep and then call TEST_CHECK/TEST_MSG to use this
helper.
- Around line 98-141: Extract the repeated setup/start/push/assert/teardown
sequence in tests like flb_test_non_duplication into a shared helper (e.g.,
run_logdna_test) that encapsulates flb_create + flb_service_set,
flb_input/flb_input_set, flb_output/flb_output_set, flb_output_set_test,
flb_start, flb_lib_push, sleep/assert via get_output_num, and
flb_stop/flb_destroy; change each test to call this helper with parameters for
input JSON, output options (api_key, exclude_promoted_keys, match, etc.), and
the formatter callback (cb_check_non_duplication) so all boilerplate is
centralized and tests only pass the differing inputs and assertions.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: fd868599-11eb-459c-8190-6347d36c83de

📥 Commits

Reviewing files that changed from the base of the PR and between 69dd887 and ec331c9.

📒 Files selected for processing (4)
  • plugins/out_logdna/logdna.c
  • plugins/out_logdna/logdna.h
  • tests/runtime/CMakeLists.txt
  • tests/runtime/out_logdna.c
🚧 Files skipped from review as they are similar to previous changes (3)
  • plugins/out_logdna/logdna.h
  • tests/runtime/CMakeLists.txt
  • plugins/out_logdna/logdna.c

Comment thread tests/runtime/out_logdna.c
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

♻️ Duplicate comments (1)
tests/runtime/out_logdna.c (1)

68-76: ⚠️ Potential issue | 🟠 Major

Top-level key assertions can false-pass due escaped line content.

strstr(json, "\"meta\":") / \"level\" / \"app\" / \"file\" can match inside escaped "line" JSON, so promotion regressions may be missed (e.g., no real top-level key, but escaped key still present in line).

Suggested hardening
+static int contains_unescaped_token(const char *json, const char *token)
+{
+    const char *p;
+    size_t len;
+
+    p = json;
+    len = strlen(token);
+
+    while ((p = strstr(p, token)) != NULL) {
+        if (p == json || *(p - 1) != '\\') {
+            return FLB_TRUE;
+        }
+        p += len;
+    }
+
+    return FLB_FALSE;
+}
...
-    if (!TEST_CHECK(strstr(json, "\"meta\":") != NULL)) {
+    if (!TEST_CHECK(contains_unescaped_token(json, "\"meta\":"))) {
         TEST_MSG("missing top-level meta: %s", json);
     }
-    if (!TEST_CHECK(strstr(json, "\"level\":") != NULL)) {
+    if (!TEST_CHECK(contains_unescaped_token(json, "\"level\":"))) {
         TEST_MSG("missing top-level level: %s", json);
     }

Also applies to: 163-174, 539-547

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tests/runtime/out_logdna.c` around lines 68 - 76, The assertions use
strstr(json, "\"meta\":") / "\"level\"" / "\"app\"" which can match inside an
escaped "line" value and false-pass; replace these raw substring checks by
parsing the JSON and asserting top-level keys exist (e.g., cJSON_Parse or the
project’s JSON helper to get the root object and verify
cJSON_GetObjectItem(root, "meta"), "level", "app", "file" are non-NULL), then
free the parsed object and fail the test if any top-level key is missing; update
all occurrences noted (the shown block and the duplicate locations) and
reference the json variable when replacing the checks.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Duplicate comments:
In `@tests/runtime/out_logdna.c`:
- Around line 68-76: The assertions use strstr(json, "\"meta\":") / "\"level\""
/ "\"app\"" which can match inside an escaped "line" value and false-pass;
replace these raw substring checks by parsing the JSON and asserting top-level
keys exist (e.g., cJSON_Parse or the project’s JSON helper to get the root
object and verify cJSON_GetObjectItem(root, "meta"), "level", "app", "file" are
non-NULL), then free the parsed object and fail the test if any top-level key is
missing; update all occurrences noted (the shown block and the duplicate
locations) and reference the json variable when replacing the checks.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 61988e71-d2e4-460b-96e9-992b976a31da

📥 Commits

Reviewing files that changed from the base of the PR and between ae0c138 and eefbd5d.

📒 Files selected for processing (4)
  • plugins/out_logdna/logdna.c
  • plugins/out_logdna/logdna.h
  • tests/runtime/CMakeLists.txt
  • tests/runtime/out_logdna.c
🚧 Files skipped from review as they are similar to previous changes (1)
  • plugins/out_logdna/logdna.c

@cosmo0920
Copy link
Copy Markdown
Contributor

Hi lecaros!
Thanks for detailed work.
But we need to split to commit an implementation commit and an adding unit testing commit.
So, could you split your commit into the following two commits?

out_logdna: remove promoted keys from line field
tests: runtiem: Add out_logdna unit test

lecaros added 2 commits April 30, 2026 10:06
Signed-off-by: lecaros <lecaros@chronosphere.io>
Signed-off-by: lecaros <lecaros@chronosphere.io>
@cosmo0920 cosmo0920 added this to the Fluent Bit v5.0.4 milestone Apr 30, 2026
@lecaros lecaros merged commit eae3ebf into master May 5, 2026
75 of 78 checks passed
@lecaros lecaros deleted the lecaros-logdna-remove-known-keys branch May 5, 2026 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants