-
Notifications
You must be signed in to change notification settings - Fork 1.7k
in_tail: fix last_processed_bytes calculation #10677
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Fix last_processed_bytes calculation in multiple line scenario. Signed-off-by: zshuang0316 <[email protected]>
Signed-off-by: zshuang0316 <[email protected]>
Signed-off-by: zshuang0316 <[email protected]>
WalkthroughA logic correction was made in the Changes
Sequence Diagram(s)sequenceDiagram
participant TestRunner
participant FluentBitEngine
participant TailInput
participant OutputCollector
TestRunner->>FluentBitEngine: Start engine with multiline parser config
FluentBitEngine->>TailInput: Initialize tail input with offset_key
TestRunner->>TailInput: Write multiline log messages to file
TailInput->>TailInput: Parse logs using multiline-regex parser
TailInput->>OutputCollector: Emit parsed records with offset_key
OutputCollector->>TestRunner: Output records for verification
TestRunner->>TestRunner: Assert offset_key correctness
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Poem
Note ⚡️ Unit Test Generation is now available in beta!Learn more here, or try it out under "Finishing Touches" below. 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (28)
✨ Finishing Touches
🧪 Generate unit tests
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Signed-off-by: zshuang0316 <[email protected]>
Signed-off-by: zshuang0316 <[email protected]>
This value represent the number of bytes processed by process_content() in the last iteration so we can set it the current processed_bytes directly.
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:
If this is a change to packaging of containers or native binaries then please confirm it works for all targets.
ok-package-test
label to test for all targets (requires maintainer to do).Documentation
Backporting
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
Bug Fixes