You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug @jeschkies Using promtail's docker_sd_config, lines longer than than 64k result in an error that prevents further log lines from being consumed. The error is:
bufio.Scanner: token too long
This occurs because by default bufio.Scanner uses MaxScanTokenSize = 64 * 1024, and lines longer than the buffer will result in the above error.
Started Promtail with docker_sd_config listening for Docker container logs
Start a Docker container which generates log lines longer than 64k bytes
Observe that parsing of the logs for the container fail when parsing long log lines and do not parse further lines
Expected behavior
Promtail parses Docker container log lines longer than 64k without issue.
Environment:
Infrastructure: bare metal
Deployment tool: ansible
Screenshots, Promtail config, or terminal output
From clients/pkg/promtail/targets/docker/targetmanager_test.go when a long log line is added to clients/pkg/promtail/targets/docker/testdata/flog.log and included in the tests:
level=warn msg="finished scanning logs lines with an error" err="bufio.Scanner: token too long"
The text was updated successfully, but these errors were encountered:
Describe the bug
@jeschkies Using promtail's
docker_sd_config
, lines longer than than 64k result in an error that prevents further log lines from being consumed. The error is:This occurs because by default
bufio.Scanner
usesMaxScanTokenSize = 64 * 1024
, and lines longer than the buffer will result in the above error.See #6256 for a potential fix.
To Reproduce
Steps to reproduce the behavior:
docker_sd_config
listening for Docker container logsExpected behavior
Promtail parses Docker container log lines longer than 64k without issue.
Environment:
Screenshots, Promtail config, or terminal output
From
clients/pkg/promtail/targets/docker/targetmanager_test.go
when a long log line is added toclients/pkg/promtail/targets/docker/testdata/flog.log
and included in the tests:The text was updated successfully, but these errors were encountered: