Skip to content

Stateful processors wrapped in conditionals aren't cleaned up #46575

@swiatekm

Description

@swiatekm

Some processors are stateful, and have a Close method defined, which must be called to release resources they may be holding. However, if they exist within a condition, they get wrapped in a conditional processor, neither of which have Close defined. As a result, we may be leaking resources from these processors after the pipeline is closed.

This probably affects standalone Beats less, as global processors get cleaned up via the process exiting. To trigger this bug in practice, you'd need to have a conditional stateful processor in a local pipeline, and reload the config enough times for the leak to be visible. We noticed it in global processors for beat receivers, because there, cleanup without the process exiting is much more frequent.

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