cmd

package
v0.0.0-...-c669420 Latest Latest
Warning

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

Go to latest
Published: Dec 28, 2023 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ListGroups

func ListGroups(admin sarama.ClusterAdmin) func(c *gin.Context)

ListGroups godoc @Summary List Kafka consumer groups @Description Get a list of all consumer groups from the Kafka cluster. @Tags kafka @Accept json @Produce json @Success 200 {object} map[string]string "OK: Map of consumer group names to their respective protocol types." @Failure 400 {string} string "Bad Request: Error message if unable to list groups." @Router /groups [get]

func ListTopic

func ListTopic(admin sarama.ClusterAdmin) func(c *gin.Context)

ListTopics godoc @Summary List Kafka topics @Description get list of all Kafka topics from the cluster @Tags kafka @Accept json @Produce json @Success 200 {object} map[string]TopicDetail "List of Kafka topics" @Failure 400 {string} string "Bad Request when listing topics fails" @Router /topics [get]

Types

type TopicDetail

type TopicDetail struct {
	// NumPartitions contains the number of partitions to create in the topic, or
	// -1 if we are either specifying a manual partition assignment or using the
	// default partitions.
	NumPartitions int32
	// ReplicationFactor contains the number of replicas to create for each
	// partition in the topic, or -1 if we are either specifying a manual
	// partition assignment or using the default replication factor.
	ReplicationFactor int16
	// ReplicaAssignment contains the manual partition assignment, or the empty
	// array if we are using automatic assignment.
	ReplicaAssignment map[int32][]int32
	// ConfigEntries contains the custom topic configurations to set.
	ConfigEntries map[string]*string
}

Jump to

Keyboard shortcuts

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