func (l *LoadManager) Stop() {
	for _, ac := range l.mainQueues {
		ac.Stop()
	}
	l.suspiciousQueue.Stop()
}
Stop prevents future resource acquisitions.
package load_manager
import (
	"context"
	ac "github.com/dropbox/load_management/admission_control"
	"github.com/dropbox/load_management/scorecard"
)
const suspiciousQueueName = "suspicious"
const hardReject = uint(0)
type LoadManager struct {
	Scorecard       scorecard.Scorecard
	CanaryScorecard scorecard.Scorecard
	baseTags []scorecard.Tag
	mainQueues      map[string]ac.AdmissionController
	suspiciousQueue ac.AdmissionController
}
func NewLoadManager(
	mainQueues map[string]ac.AdmissionController,
	suspiciousQueue ac.AdmissionController,
	primaryScorecard scorecard.Scorecard,
	canaryScorecard scorecard.Scorecard,  
	baseTags []scorecard.Tag) *LoadManager {
	if canaryScorecard == nil {
		canaryScorecard = scorecard.NewScorecard(scorecard.NoRules())
	}
	return &LoadManager{
		mainQueues:      mainQueues,
		suspiciousQueue: suspiciousQueue,
		Scorecard:       primaryScorecard,
		CanaryScorecard: canaryScorecard,
		baseTags:        baseTags,
	}
}
func (l *LoadManager) GetResource(
	ctx context.Context,
	queueName string,
	tags []scorecard.Tag) *Resource {
	resource := l.getResourceInternal(ctx, queueName, tags)
	if resource.Acquired() {
		return resource
	}
	if resource.QueueInfo.Ticket == nil {
		return resource
	}
	if resource.Suspicious() && resource.TrackingInfo.Violated.Capacity == hardReject {
		return resource
	}
	ticket := l.suspiciousQueue.AdmitOne()
	resource.QueueInfo = QueueInfo{
		Name:     suspiciousQueueName,
		Capacity: l.suspiciousQueue.Capacity(),
		Ticket:   ticket,
	}
	if ticket != nil {
		resource.acquired = true
	}
	return resource
}
func (l *LoadManager) GetResourceStrict(
	ctx context.Context,
	queueName string,
	tags []scorecard.Tag) *Resource {
	return l.getResourceInternal(ctx, queueName, tags)
}
func (l *LoadManager) getResourceInternal(
	ctx context.Context,
	queueName string,
	tags []scorecard.Tag) *Resource {
	resource := &Resource{}
	mainQueue, ok := l.mainQueues[queueName]
	if !ok {
		return resource
	}
	ticket := mainQueue.AdmitOne()
	resource.QueueInfo = QueueInfo{
		Name:     queueName,
		Capacity: mainQueue.Capacity(),
		Ticket:   ticket,
	}
	if ticket == nil {
		return resource
	}
	combinedTags := make([]scorecard.Tag, 0, len(tags)+len(l.baseTags))
	combinedTags = append(combinedTags, tags...)
	combinedTags = append(combinedTags, l.baseTags...)
	resource.TrackingInfo = l.Scorecard.TrackRequest(combinedTags)
	if !resource.TrackingInfo.Tracked {
		resource.QueueInfo.Ticket.Release()
		return resource
	}
	resource.acquired = true
	resource.CanaryTrackingInfo = l.CanaryScorecard.TrackRequest(tags)
	return resource
}