Skip to content
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

Collapse multiline logs based on a start line. #2971

Closed
wants to merge 2 commits into from

Commits on Nov 20, 2020

  1. Collapse multiline logs based on a start line.

    Summary:
    This is a very simple approach based on grafana#1380 to provide multiline
    or block log entries in promtail.
    
    A `multiline` stage is added to pipelines. This stages matches a start
    line. Once a start line is matched all following lines are appended
    to an entry and "dropped". Once a new start line is matched the former
    block of multilines is send.
    
    This approach has two downside because log entires are not sent until a
    new start line is matched.
    
    1. Lines can linger for a long time. The multiline stage should flush out
       lines if now new start line is matched in a certain time frame.
       However, the current pipeline interface cannot actively push entries.
       So a time based flushing would require a bigger refactoring.
    
    2. If the observed system crashes the last log lines are not sent. Thus
       important information might be lost.
    jeschkies committed Nov 20, 2020
    Configuration menu
    Copy the full SHA
    08a444d View commit details
    Browse the repository at this point in the history
  2. Fix linter issues.

    jeschkies committed Nov 20, 2020
    Configuration menu
    Copy the full SHA
    7be2aec View commit details
    Browse the repository at this point in the history