Skip to content

Long lines are unexpectedly split into multiple OTEL Log records #35042

Closed
@cwegener

Description

@cwegener

Component(s)

pkg/stanza/fileconsumer, receiver/filelog

What happened?

Description

When using the filelog receiver, any lines that are longer than the default buffer size (16KB) will be split into multiple log records instead of one single log record.

Steps to Reproduce

  1. Create simple default filelog receiver config
  2. Ingest a file that has a line length that is greater than 16KB)

Expected Result

Lines longer than 16KB gets emitted as one single OTEL Log record

Actual Result

Lines longer than 16KB get emitted as multiple OTEL Log records, each record getting split at the 16KB boundary.

Collector version

v0.108.0

Environment information

Environment

OS: Archlinux
Compiler(if manually compiled): go 1.23.0

OpenTelemetry Collector configuration

receivers:
  filelog:
    start_at: beginning
    include:
      - "/tmp/metrics_101089747.json"

exporters:
  debug:
    verbosity: detailed
service:
  pipelines:
    logs/raw:
      receivers:
        - filelog
      exporters:
        - debug

Log output

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions