MCPcopy
hub / github.com/CodisLabs/codis / FillSlots

Method FillSlots

pkg/proxy/proxy.go:249–261  ·  view source on GitHub ↗
(slots []*models.Slot)

Source from the content-addressed store, hash-verified

247}
248
249func (s *Proxy) FillSlots(slots []*models.Slot) error {
250 s.mu.Lock()
251 defer s.mu.Unlock()
252 if s.closed {
253 return ErrClosedProxy
254 }
255 for _, m := range slots {
256 if err := s.router.FillSlot(m); err != nil {
257 return err
258 }
259 }
260 return nil
261}
262
263func (s *Proxy) SwitchMasters(masters map[int]string) error {
264 s.mu.Lock()

Callers 6

TestFillSlotFunction · 0.45
TestStartAndShutdownFunction · 0.45
reinitProxyMethod · 0.45
resyncSlotMappingsMethod · 0.45
AutoOnlineWithFillSlotsFunction · 0.45
handleFillSlotsMethod · 0.45

Calls 1

FillSlotMethod · 0.45

Tested by 2

TestFillSlotFunction · 0.36
TestStartAndShutdownFunction · 0.36