bbgo: fix graceful shutdown call

This commit is contained in:
c9s 2023-02-08 17:30:33 +08:00
parent 829704eda3
commit 3c69556424
No known key found for this signature in database
GPG Key ID: 7385E7E464CB0A54

View File

@ -30,5 +30,6 @@ func OnShutdown(ctx context.Context, f ShutdownHandler) {
func Shutdown(shutdownCtx context.Context) {
logrus.Infof("shutting down...")
defaultIsolation.gracefulShutdown.Shutdown(shutdownCtx)
isolatedContext := GetIsolationFromContext(shutdownCtx)
isolatedContext.gracefulShutdown.Shutdown(shutdownCtx)
}