From 1a19c209781763d9dcb568fff52ee025ed92d0e1 Mon Sep 17 00:00:00 2001 From: Conor Mongey Date: Sun, 14 Jan 2018 16:31:17 +0000 Subject: [PATCH] Update for dep change --- kafka/utils.go | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/kafka/utils.go b/kafka/utils.go index 1254c52d..b469d102 100644 --- a/kafka/utils.go +++ b/kafka/utils.go @@ -62,7 +62,7 @@ func ConfigForTopic(topic string, brokers []string) (map[string]string, error) { request := &sarama.DescribeConfigsRequest{ Resources: []*sarama.Resource{ &sarama.Resource{ - T: sarama.TopicResource, + Type: sarama.TopicResource, Name: topic, ConfigNames: []string{"segment.ms"}, }, @@ -121,13 +121,10 @@ func configToResources(topic string, config map[string]*string) []*sarama.AlterC for k, v := range config { res[i] = &sarama.AlterConfigsResource{ - T: sarama.TopicResource, + Type: sarama.TopicResource, Name: topic, - ConfigEntries: []*sarama.ConfigEntryKV{ - &sarama.ConfigEntryKV{ - Name: k, - Value: *v, - }, + ConfigEntries: map[string]*string{ + k: v, }, } i++