code: func (m *Launcher) Shutdown(ctx context.Context) {
  	m.httpServer.Shutdown(ctx)
  
  	m.logger.Info("Stopping", zap.String("service", "task"))
  	m.scheduler.Stop()
  
  	m.logger.Info("Stopping", zap.String("service", "nats"))
  	m.natsServer.Close()
  
  	m.logger.Info("Stopping", zap.String("service", "bolt"))
  	if err := m.boltClient.Close(); err != nil {
  		m.logger.Info("failed closing bolt", zap.Error(err))
  	}
  
  	m.logger.Info("Stopping", zap.String("service", "query"))
  	if err := m.queryController.Shutdown(ctx); err != nil {
  		m.logger.Info("Failed closing query service", zap.Error(err))
  	}
  
  	m.logger.Info("Stopping", zap.String("service", "storage-engine"))
  	if err := m.engine.Close(); err != nil {
  		m.logger.Error("failed to close engine", zap.Error(err))
  	}
  
  	m.wg.Wait()
  
  	m.logger.Sync()
  }
docs: // Shutdown shuts down the HTTP server and waits for all services to clean up.