Unexpected high memory usage caused by CircularEventConsumer

Author: david0Created Jan 28, 2025Updated Aug 14, 2026
Labelsneeds investigation

We used the resilience4j retry in a spring boot app and got very surprised by seeing it running OOM in E2E testing.

The main task needs ~300MB but to our surprise it went OOM after a while because it needed ~3GB in overall.

It turned out that was caused by the CircularEventConsumer for the actuator endpoints, which we have not even included. (There was barely any retry happening, mostly ignored events have eaten up the memory...)

It would be definitely good if there would be an global opt-in for that feature or at least a global opt-out to safe us from further trouble caused by this feature.

Source: resilience4j/resilience4j