fix(GODT-3125): Heartbeat crash on exit

Ensure that the heartbeat background task is stopped before we close
the users as it accesses data within these instances.

Additionally, we also make sure that when telemetry is disabled, we stop
the background task.

Finally, `HeartbeatManager` now specifies what the desired interval is
so we can better configure the test cases.
This commit is contained in:
Leander Beernaert
2023-11-16 11:05:40 +01:00
parent ea1c2534df
commit 5a434fafbc
13 changed files with 146 additions and 60 deletions

View File

@ -113,6 +113,7 @@ func withBridge(
crashHandler,
reporter,
imap.DefaultEpochUIDValidityGenerator(),
nil,
// The logging stuff.
c.String(flagLogIMAP) == "client" || c.String(flagLogIMAP) == "all",