[Bug]: aws_msk_broker_nodes data source panics for the cluster with kraft mode enabled #38028
Labels
bug
Addresses a defect in current functionality.
crash
Results from or addresses a Terraform crash or kernel panic.
service/kafka
Issues and PRs that pertain to the kafka service.
Milestone
Terraform Core Version
1.5.5
AWS Provider Version
5.52.0
Affected Resource(s)
Data source: aws_msk_broker_nodes
Expected Behavior
It returns the list of cluster nodes
Actual Behavior
panic: runtime error: invalid memory address or nil pointer dereference
Relevant Error/Panic Output Snippet
Terraform Configuration Files
Steps to Reproduce
aws_msk_broker_nodes
data source:Debug Output
No response
Panic Output
No response
Important Factoids
ATM for the kraft clusters AWS API returns empty "CONTROLLER" nodes in addition to broker nodes
But this code cannot handle this situation even though there is already a check to handle
brokerNodeInfo != nil
hereFor clusters with zookeeper aws api returns only broker nodes.
References
No response
Would you like to implement a fix?
Yes
The text was updated successfully, but these errors were encountered: