Skip to content

Log file collector based on v2 input API #20243

@urso

Description

@urso

Implement an alternative log file collector (Name: logfile) for use with the agent based on the v2 input API.

The v2 input API allows file state to be stored in a generic key-value store, while requiring the Input type to implement all required logic for state and ACK handling. A generic implementation for stateful inputs is available in the filebeat/input/v2/input-cursor package (currently requires a static set of sources only).

Tasks

Phase 1 (feature-parity)

  • create a special stateful input for the new logfile
  • add harvesters to an input dynamically
  • watch for file events
    • create an interface that is responsible for watching changes in the input files
    • refactor the current scanner so it implements the new interface

Missing features

  • JSON reader
    • add it again
    • rename it to NDJSON
  • multiline reader
  • configurable cleaner options

Phase 2 (enhancements)

Inputs based on log

Marking it GA

- [ ] remove log input in 8.x

Related: #15324

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