meta

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Oct 18, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package meta implements metadata structures and related operations.

Package meta implements metadata structures and related operations.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Broker

type Broker struct {
	ID   int32
	Rack string
}

Broker represents a cluster broker.

type Brokers

type Brokers []Broker

Brokers represents a slice of Broker.

func (Brokers) BrokersByRack

func (b Brokers) BrokersByRack() map[string][]int32

BrokersByRack returns a map of brokers by non-empty broker rack ID.

func (Brokers) IDs added in v0.1.0

func (b Brokers) IDs() []int32

IDs returns a slice of the broker IDs.

func (Brokers) Racks

func (b Brokers) Racks() []string

Racks returns a unique, sorted slice of non-empty broker rack IDs.

func (Brokers) RacksByBroker

func (b Brokers) RacksByBroker() map[int32]string

RacksByBroker returns a map of racks by broker ID.

type PartitionReassignment

type PartitionReassignment struct {
	Partition        int32   `json:"partition"`
	Replicas         []int32 `json:"replicas"`
	AddingReplicas   []int32 `json:"addingReplicas"`
	RemovingReplicas []int32 `json:"removingReplicas"`
}

PartitionReassignment represents a partition reassignment.

type PartitionReassignments

type PartitionReassignments []PartitionReassignment

PartitionReassignments represents a slice of PartitionReassignment.

func (PartitionReassignments) Sort

func (p PartitionReassignments) Sort()

Sort sorts by partition ID.

Jump to

Keyboard shortcuts

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