lago icon indicating copy to clipboard operation
lago copied to clipboard

misc(events-processor): Keep track of go routines

Open vincent-pochet opened this issue 1 month ago • 0 comments

Context

This PR is part of the Pre-aggregation epic, it follows https://github.com/getlago/lago/pull/606

The main goal of this feature is to setup a complete aggregation pipeline that will be leveraged to compute the customer usage without re-querying the full set of events.

Description

This PR adds a grecefull shutdown logic to the events_processor, and keeps tracks of go routine to make sure that it waits for the ongoing task to be finished before shutting down the application. It also improves the recovery in case of system failures (panic, unhandled errors...)

vincent-pochet avatar Oct 14 '25 13:10 vincent-pochet