-
-
Notifications
You must be signed in to change notification settings - Fork 101
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
Cluster gets recreated(deleted then created) for the latest version v2.3.0 #93
Comments
set additional variable and it will work as before
|
Still the same behaviour after added those vars...It tdeletes the cluster and the security group, and tries to create them again. This means downtime and maybe lost of data...right? module.test-kafka-cluster.module.msk_cluster.aws_msk_cluster.default[0] must be replaced-/+ resource "aws_msk_cluster" "default" { module.test-kafka-cluster.module.msk_cluster.module.broker_security_group.aws_security_group.default[0] will be destroyed(because aws_security_group.default is not in configuration)
|
Some extra work needed. I figured it out. You need to add moved block so terraform sees that there is rename of a security group module (which forces cluster recreation later).
Also you need the block that @dmitriy-lukyanchikov mentioned. In my case I need to set description of sg as well (as default one changed and that also forcing recreation)
As a result only my Sorry guys but this should be mentioned in the 2.0.0 release notes. It's not easy to figure it out without some debugging. |
Hello, indeed, you're right. I did everything of the above and it avoided the deletion of the cluster and the SG. Thank you for that. module.test-kafka-cluster.module.msk_cluster.aws_msk_configuration.config[0] must be replaced+/- resource "aws_msk_configuration" "config" { |
I'm glad that my codehelped you :) About this aws_msk_configuration - quick look shows that they added join with
Because |
Describe the Bug
When trying to upgrade kafka module to current latest version, it has an unexpected behaviour. It deletes the current kafka cluster, and try to recreate it. Also, the Security Group gets deleted and recreated with same rules. The only difference is that it changes its name from "default" to "cbd":
module.test-kafka-cluster.module.msk_cluster.module.security_group.aws_security_group.cbd[0] will be created
}
}
module.test-kafka-cluster.module.msk_cluster.module.security_group.random_id.rule_change_forces_new_security_group[0] will be created
module.test-kafka-cluster.module.msk_cluster.module.broker_security_group.aws_security_group.default[0] will be destroyed
(because aws_security_group.default is not in configuration)
arn = "arn:aws:ec2:AWS-AZ:AWS-ACCOUNT-ID:security-group/sg-SG-ID" -> null
description = "MSK broker access" -> null
module.test-kafka-cluster.module.msk_cluster.aws_msk_cluster.default[0] must be replaced
-/+ resource "aws_msk_cluster" "default" {
Expected Behavior
Upgrade should've been smooth, and the attempt of deleting and creating again the kafka cluster should never happen.
Steps to Reproduce
Tried to upgrade from kafka module from version v1.3.1 to v2.3.0.
Screenshots
No response
Environment
No response
Additional Context
No response
The text was updated successfully, but these errors were encountered: