rebalance

package
v0.0.0-...-130f5e9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 25, 2018 License: Apache-2.0 Imports: 3 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AllocateMessageQueueAveragely

type AllocateMessageQueueAveragely struct {
}

func (AllocateMessageQueueAveragely) Allocate

func (strategy AllocateMessageQueueAveragely) Allocate(consumerGroup string, currentCID string, mqAll []*message.MessageQueue, cidAll []string) []*message.MessageQueue

func (AllocateMessageQueueAveragely) GetName

func (strategy AllocateMessageQueueAveragely) GetName() string

type AllocateMessageQueueStrategy

type AllocateMessageQueueStrategy interface {
	// Allocating by consumer id
	// consumerGroup current consumer group
	// currentCID    current consumer id
	// mqAll         message queue set in current topic
	// cidAll        consumer set in current consumer group
	Allocate(
		consumerGroup string,
		currentCID string,
		mqAll []*message.MessageQueue,
		cidAll []string) []*message.MessageQueue
	// Algorithm name
	GetName() string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL