Skip to content

Commit

Permalink
improve region forward
Browse files Browse the repository at this point in the history
Signed-off-by: Ryan Leung <[email protected]>
  • Loading branch information
rleungx committed Nov 13, 2023
1 parent 1a0233b commit b8885a7
Show file tree
Hide file tree
Showing 3 changed files with 713 additions and 650 deletions.
6 changes: 3 additions & 3 deletions pkg/schedule/coordinator.go
Original file line number Diff line number Diff line change
Expand Up @@ -372,9 +372,6 @@ func (c *Coordinator) RunUntilStop() {
c.Run()
<-c.ctx.Done()
log.Info("coordinator is stopping")
c.GetSchedulersController().Wait()
c.wg.Wait()
log.Info("coordinator has been stopped")
}

// Run starts coordinator.
Expand Down Expand Up @@ -579,6 +576,9 @@ func (c *Coordinator) waitPluginUnload(pluginPath, schedulerName string, ch chan
// Stop stops the coordinator.
func (c *Coordinator) Stop() {
c.cancel()
c.GetSchedulersController().Wait()
c.wg.Wait()
log.Info("coordinator has been stopped")
}

// GetHotRegionsByType gets hot regions' statistics by RWType.
Expand Down
Loading

0 comments on commit b8885a7

Please sign in to comment.