-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Closed
Labels
Description
Component(s)
pkg/stanza
/pkg/stanza/operator/parser/container
What happened?
Description
Container logs processed by the OpenTelemetry Collector's container parser are being truncated at exactly 1,638,466 bytes (~1.56 MiB) when using multiline log recombination.
Steps to Reproduce
I use this config for log recombine logs multilines but I still found the split log
receivers:
filelog:
include:
- /var/log/pods/*/*/*.log
operators:
- id: container-parser
type: container
- id: recombine-multiline
type: recombine
combine_field: body
combine_with: ""
is_last_entry: body matches "\\n$"
source_identifier: attributes["log.file.path"]
max_batch_size: 10000
- id: trim-trailing-newline
type: regex_replace
field: body
regex: "[\n]+$"
replace_with: ""
start_at: end
max_log_size: 10MiB
storage: file_storageExpected Result
It should recombine logs that larger than 1.56 MiB
Actual Result
it just split the logs because of hard limit on this defaultMaxBatchSize of container parser
Collector version
v0.138.0
Environment information
Environment
OS: (e.g., "Ubuntu 20.04")
Compiler(if manually compiled): (e.g., "go 14.2")
OpenTelemetry Collector configuration
receivers:
filelog:
include:
- /var/log/pods/*/*/*.log
operators:
- id: container-parser
type: container
- id: recombine-multiline
type: recombine
combine_field: body
combine_with: ""
is_last_entry: body matches "\\n$"
source_identifier: attributes["log.file.path"]
max_batch_size: 10000
- id: trim-trailing-newline
type: regex_replace
field: body
regex: "[\n]+$"
replace_with: ""
start_at: end
max_log_size: 10MiB
storage: file_storageLog output
Additional context
No response
Tip
React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it. Learn more here.
Reactions are currently unavailable