Skip to content

Conversation

@drbugfinder-work
Copy link
Contributor

@drbugfinder-work drbugfinder-work commented Apr 2, 2024

This PR will add functionality to set emitter alias and mem buf limit. The default mem buf limit is 10MB.

Needs #8473 to be applied before taking effect.
(EDIT PR is merged)


Enter [N/A] in the box, if an item is not applicable to your change.

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

  • [N/A] Example configuration file for the change
  • [N/A] Debug log output from testing the change
  • Attached Valgrind output that shows no leaks or memory corruption was found

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

  • [N/A] Documentation required for this feature

Backporting

  • [N/A] 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.

@drbugfinder-work
Copy link
Contributor Author

cc @agup006

This commit will add functionality to set emitter alias and mem buf limit. The default mem buf limit is 10MB

Signed-off-by: Richard Treu <[email protected]>
@drbugfinder-work
Copy link
Contributor Author

root@flb:~/fluent-bit-emitter-limit/fluent-bit/build/bin# valgrind ./flb-rt-filter_log_to_metrics 
==302271== Memcheck, a memory error detector
==302271== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==302271== Using Valgrind-3.15.0 and LibVEX; rerun with -h for copyright info
==302271== Command: ./flb-rt-filter_log_to_metrics
==302271== 
Test counter_k8s...                             [ OK ]
Test counter...                                 [ OK ]
Test counter_k8s_two_tuples...                  [ OK ]
Test gauge...                                   [ OK ]
Test histogram...                               [ OK ]
Test counter_regex...                           [ OK ]
Test regex_empty_label_keys...                  [ OK ]
Test label...                                   [ OK ]
SUCCESS: All unit tests have passed.
==302271== 
==302271== HEAP SUMMARY:
==302271==     in use at exit: 0 bytes in 0 blocks
==302271==   total heap usage: 19,885 allocs, 19,885 frees, 11,297,772 bytes allocated
==302271== 
==302271== All heap blocks were freed -- no leaks are possible
==302271== 
==302271== For lists of detected and suppressed errors, rerun with: -s
==302271== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)

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