libbeat pipeline clients do not detect when all events have been acknowledged
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 12.7k
- Forks
- 5k
- Avg merge
- 2d 1h
- Merged PRs (30d)
- 370
Description
In Beats receivers, and sometimes in standalone Beats, the libbeat queue is stopped before the Beater is signalled to shut down. This means that there is an interval where the queue begins rejecting events from the clients, but the clients themselves (and the inputs that own them) are still active. This will manifest as Publish calls that trigger AddEvent(event, true) on any event listeners, but then afterwards call DroppedOnPublish on any client listeners when the event can't be added to the queue. Because the pipeline client's helper that tracks outstanding events listens for AddEvent but not DroppedOnPublish, when this happens (which it frequently will as long as events are being published at least ~once a second), the client will continue to think the dropped events are unacknowledged even if all real events receive acknowledgments.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the libbeat queue shutdown path through the Beater, then inspect the pipeline client's outstanding-event helper and its AddEvent and DroppedOnPublish listeners. Reproduce shutdown while events are being published and verify that rejected events no longer remain counted as unacknowledged once all real events receive acknowledgments.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100