out_datadog: fix/add error handling for all flb_sds calls
Signed-off-by: Wesley Pettit [email protected]
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:
- [ ] 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
If this is a change to packaging of containers or native binaries then please confirm it works for all targets.
- [ ] Attached local packaging test output showing all targets (including any new ones) build.
Documentation
- [ ] Documentation required for this feature
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.
Valgrind passes:
==26291==
==26291== HEAP SUMMARY:
==26291== in use at exit: 110,402 bytes in 3,763 blocks
==26291== total heap usage: 33,404 allocs, 29,641 frees, 6,283,769 bytes allocated
==26291==
==26291== LEAK SUMMARY:
==26291== definitely lost: 0 bytes in 0 blocks
==26291== indirectly lost: 0 bytes in 0 blocks
==26291== possibly lost: 0 bytes in 0 blocks
==26291== still reachable: 110,402 bytes in 3,763 blocks
==26291== suppressed: 0 bytes in 0 blocks
==26291== Rerun with --leak-check=full to see details of leaked memory
==26291==
==26291== For lists of detected and suppressed errors, rerun with: -s
==26291== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)
With config:
[SERVICE]
Log_Level debug
[INPUT]
Name dummy
Tag dummy
[OUTPUT]
Name datadog
Match *
Host http-intake.logs.datadoghq.com
TLS on
compress gzip
apikey SECRET
dd_service wesley
dd_source test
dd_tags team:logs,foo:bar
Can we please prioritise this PR ? Due to this issue we have been facing regular fluentbit crashes while sending logs to datadog.
@edsiper CI passes except for CIFuzz. This is a bug fix which was causing crashes for a csutomer. Can we please merge?