Mongey / terraform-provider-kafka

Terraform provider for managing Apache Kafka Topics + ACLs
MIT License
517 stars 129 forks source link

Unable to run against ACLs created with previous version #59

Closed john-jolet-q2 closed 5 years ago

john-jolet-q2 commented 5 years ago

When using version 0.1.4 and terraform 11, i was able to create topics and ACLs. Attempting to upgrade to 0.2.0 and terraform 12, i'm in a state where my remote state has been upgraded to the 12 format, but a terraform apply fails oddly. Using TRACE level debug, i see this: 2019/06/26 09:04:17 [DEBUG] kafka_acl.Sales43Outbound-create: apply errored, but we're indicating that via the Error pointer rather than returning it: Unknown pattern type filter: '' 2019/06/26 09:04:17 [TRACE] : eval: terraform.EvalWriteState 2019/06/26 09:04:17 [TRACE] EvalWriteState: writing current state object for kafka_acl.Sales43Outbound-create 2019/06/26 09:04:17 [TRACE] : eval: terraform.EvalApplyPost 2019/06/26 09:04:17 [ERROR] : eval: terraform.EvalApplyPost, err: Unknown pattern type filter: '' 2019/06/26 09:04:17 [ERROR] : eval: terraform.EvalSequence, err: Unknown pattern type filter: '' 2019/06/26 09:04:17 [ERROR] : eval: *terraform.EvalOpFilter, err: Unknown pattern type filter: ''

now, on a plan, it says it's going to destroy every acl i have because it needs to add resource_pattern_type_filter = "Literal" to them all. that's fine, except it fails on the destroy and never gets to the create. originally, i did not have that pattern type filter in my terraform at all. so now i'm stuck. can't go forward and can't go back.
job.log

john-jolet-q2 commented 5 years ago

Note that i get the same error using this version of the plugin with terraform 11.

john-jolet-q2 commented 5 years ago

is there any status on this? this is the last remaining terraform we have that i can't use .12 with

Mongey commented 5 years ago

@john-jolet-q2 I can take a look tonight

john-jolet-q2 commented 5 years ago

awesome, thanks.

Mongey commented 5 years ago

@john-jolet-q2 I've got a PR over in #62 that may fix the issue. Could you test the binary from CI?

https://461-103748731-gh.circle-artifacts.com/0/terraform-provider-kafka

https://circleci.com/gh/Mongey/terraform-provider-kafka/461#artifacts/containers/0

john-jolet-q2 commented 5 years ago

that seems to work better, at least on a plan. I need to set some things up to do an apply

john-jolet-q2 commented 5 years ago

This works on an apply as well

Mongey commented 5 years ago

Going to close this out, hopefully #62 fixed this -- if not, I can reopen and re-investigate