Questions to persistent streams

Hi
I’m migrating from pooled streaming event processors to persistent streams (PS) and have a few questions:

  • Has anyone already deployed PS in production? If so, what has been your experience?
  • We currently run approximately 70 pooled streaming event processors across multiple applications. What impact would running ~70 PS have on Axon Server’s load and memory footprint?
  • I’ve noticed that shutting down an application takes significantly longer when using PS, as closing the streams introduces delays. Each PS appears to take around 2 seconds to close, and since this happens sequentially, shutdown times can be considerable (e.g., 45 seconds in one of my applications). Is this a known issue?

Would appreciate any insights!

Klaus

1 Like

Hello again.
Since there hasn’t been any response to this post so far, does that mean no one is using Persistent Streams?

Any thoughts on this from AxonIQ?

Thanks
Klaus

A follow-up on this topic:
The slow shutdown behavior seems to be fixed with Axon Framework v4.11.1

Hi Klaus,
We are aware of organizations using persistent streams in production.
Having 70 persistent streams on a single Axon Server node will slightly increase memory usage, due to some caching on Axon Server side. It will also cause some additional CPU usage as Axon Server needs to store the acknowledged positions per stream segment, which would be done in the client for pooled streaming/tracking event processors.
The following properties can be configured in Axon Server:

  • axoniq.axonserver.streams.buffer-progress (default false), buffer the progress acknowledgements per stream segment and only store the latest one after a configured timeout. This reduces the CPU usage for storing the acknowledged posistions. Disadvantage is that if Axon Server would stop unexpectedly, it can resend some events on restart.
  • axoniq.axonserver.streams.buffer-time-millis (default 1000), the time the progress acknowledgments are buffered if buffer-progress is true.
  • axoniq.axonserver.streams.thread-count (default 4), thread pool size for sending events with persistent streams.
  • axoniq.axonserver.streams.segment-close-seconds (default 15), the time a segment waits for pending acknowledgements on close. When Axon Server moves a segment to another client instance it gives the client currently processing the persistent stream segment time to acknowledge any pending actions. This prevents duplicate handling of events during the transfer/closing of the segment. This may cause some delay when stopping Axon Server.

I hope this answers your questions.

Marc

1 Like