Aurelien DARRAGON 9561b9fb69 BUG/MINOR: sink: add tempo between 2 connection attempts for sft servers
When the connection for sink_forward_{oc}_applet fails or a previous one
is destroyed, the sft->appctx is instantly released.

However process_sink_forward_task(), which may run at any time, iterates
over all known sfts and tries to create sessions for orphan ones.

It means that instantly after sft->appctx is destroyed, a new one will
be created, thus a new connection attempt will be made.

It can be an issue with tcp log-servers or sink servers, because if the
server is unavailable, process_sink_forward() will keep looping without
any temporisation until the applet survives (ie: connection succeeds),
which results in unexpected CPU usage on the threads responsible for
that task.

Instead, we add a tempo logic so that a delay of 1second is applied
between two retries. Of course the initial attempt is not delayed.

This could be backported to all stable versions.
2025-02-21 11:22:35 +01:00
..
2023-08-01 10:49:06 +02:00
2024-04-05 15:40:42 +02:00
2024-05-16 10:31:17 +02:00
2024-11-29 07:22:32 +01:00
2022-04-22 15:45:47 +02:00
2024-12-10 16:04:11 +01:00
2024-12-10 16:04:11 +01:00
2022-11-29 15:14:39 +01:00
2024-10-24 16:12:46 +02:00
2025-01-30 18:12:40 +01:00
2024-12-12 11:19:10 +01:00
2024-07-12 15:27:04 +02:00
2024-08-07 15:40:52 +02:00