diff --git a/go.mod b/go.mod index f85589b4..34f414a6 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module github.com/Mongey/terraform-provider-kafka go 1.12 require ( - github.com/Shopify/sarama v1.22.1-0.20190412022128-c14cccae56fa + github.com/Shopify/sarama v1.22.1 github.com/hashicorp/go-uuid v1.0.1 github.com/hashicorp/hcl v1.0.0 // indirect github.com/hashicorp/terraform v0.12.0 diff --git a/go.sum b/go.sum index e5269801..668c325a 100644 --- a/go.sum +++ b/go.sum @@ -17,6 +17,8 @@ github.com/DataDog/zstd v1.3.6-0.20190409195224-796139022798 h1:2T/jmrHeTezcCM58 github.com/DataDog/zstd v1.3.6-0.20190409195224-796139022798/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= github.com/Shopify/sarama v1.22.1-0.20190412022128-c14cccae56fa h1:UMPk5t5qV+uZE+TtnTJTqvr0y97abIrqnQNFgDY/ymY= github.com/Shopify/sarama v1.22.1-0.20190412022128-c14cccae56fa/go.mod h1:FRzlvRpMFO/639zY1SDxUxkqH97Y0ndM5CbGj6oG3As= +github.com/Shopify/sarama v1.22.1 h1:exyEsKLGyCsDiqpV5Lr4slFi8ev2KiM3cP1KZ6vnCQ0= +github.com/Shopify/sarama v1.22.1/go.mod h1:FRzlvRpMFO/639zY1SDxUxkqH97Y0ndM5CbGj6oG3As= github.com/Shopify/toxiproxy v2.1.4+incompatible h1:TKdv8HiTLgE5wdJuEML90aBgNWsokNbMijUGhmcoBJc= github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI= github.com/Unknwon/com v0.0.0-20151008135407-28b053d5a292/go.mod h1:KYCjqMOeHpNuTOiFQU6WEcTG7poCJrUs0YgyHNtn1no= diff --git a/kafka/config.go b/kafka/config.go index b4db804b..4d233633 100644 --- a/kafka/config.go +++ b/kafka/config.go @@ -30,10 +30,10 @@ func (c *Config) newKafkaConfig() (*sarama.Config, error) { if c.saslEnabled() { switch c.SASLMechanism { case "scram-sha512": - kafkaConfig.Net.SASL.SCRAMClient = &XDGSCRAMClient{HashGeneratorFcn: SHA512} + kafkaConfig.Net.SASL.SCRAMClientGeneratorFunc = func() sarama.SCRAMClient { return &XDGSCRAMClient{HashGeneratorFcn: SHA512} } kafkaConfig.Net.SASL.Mechanism = sarama.SASLMechanism(sarama.SASLTypeSCRAMSHA512) case "scram-sha256": - kafkaConfig.Net.SASL.SCRAMClient = &XDGSCRAMClient{HashGeneratorFcn: SHA256} + kafkaConfig.Net.SASL.SCRAMClientGeneratorFunc = func() sarama.SCRAMClient { return &XDGSCRAMClient{HashGeneratorFcn: SHA256} } kafkaConfig.Net.SASL.Mechanism = sarama.SASLMechanism(sarama.SASLTypeSCRAMSHA256) case "plain": default: