Skip to content

Commit 36c4ed7

Browse files
committed
engine: do upstream cleanup after the event loop finished processing events (#2497)
Signed-off-by: Eduardo Silva <eduardo@treasure-data.com>
1 parent 23d6f4a commit 36c4ed7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/flb_engine.c

+2
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ int flb_engine_flush(struct flb_config *config,
8888
return 0;
8989
}
9090

91+
/* Cleanup function that runs every 1.5 second */
9192
static void cb_engine_sched_timer(struct flb_config *ctx, void *data)
9293
{
9394
(void) data;
@@ -626,6 +627,7 @@ int flb_engine_start(struct flb_config *config)
626627
/* Cleanup functions associated to events and timers */
627628
if (config->is_running == FLB_TRUE) {
628629
flb_sched_timer_cleanup(config->sched);
630+
flb_upstream_conn_pending_destroy(config);
629631
}
630632
}
631633
}

0 commit comments

Comments
 (0)