Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ConfigResourceType to match the protocol and server. #1551

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 6 additions & 10 deletions config_resource_type.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,16 @@ package sarama
//ConfigResourceType is a type for config resource
type ConfigResourceType int8

// Taken from :
// https://cwiki.apache.org/confluence/display/KAFKA/KIP-133%3A+Describe+and+Alter+Configs+Admin+APIs#KIP-133:DescribeandAlterConfigsAdminAPIs-WireFormattypes
// Note that the ResourceType described here is only accurate for ACLs:
// https://cwiki.apache.org/confluence/display/KAFKA/KIP-133%3A+Describe+and+Alter+Configs+Admin+APIs#KIP-133:DescribeandAlterConfigsAdminAPIs-WireFormattypes
// See the following for the ConfigResource type that is used for Describe and Alter Config operations.
// https://github.com/apache/kafka/blob/2.3/clients/src/main/java/org/apache/kafka/common/config/ConfigResource.java#L36

const (
//UnknownResource constant type
UnknownResource ConfigResourceType = iota
//AnyResource constant type
AnyResource
//TopicResource constant type
TopicResource
//GroupResource constant type
GroupResource
//ClusterResource constant type
ClusterResource
TopicResource = 2
//BrokerResource constant type
BrokerResource
BrokerResource = 4
)