Skip to content

Stickiness support for source_ip broke valid configurations for NLB #15603

@alex1x

Description

@alex1x

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform CLI and Terraform AWS Provider Version

0.13.1
3.10

Affected Resource(s)

  • aws_lb_target_group

Terraform Configuration Files

Before this was merged, I used blocks like

  stickiness {
    type    = "lb_cookie"
    enabled = false
  }

because due to a previous bug in order to disable stickiness you had to set lb_cookie as your type, even though it wasn't appropriate for the NLB (was the only available one), because the config otherwise complained that type was not set, even though the only desired effect was to disable stickiness.

These configurations worked fine up to 3.10 where they fail with InvalidConfigurationRequest: Stickiness type 'lb_cookie' is not supported for target groups with the TCP protocol, even though enabled is (still) set to false. I think it shouldn't complain about the stickiness type when enabled is set to false.

Expected Behavior

When stickiness block is configured as enabled = false it doesn't complain about the type of stickiness.

Actual Behavior

Terraform fails with Stickiness type 'lb_cookie' is not supported for target groups with the TCP protocol

Steps to Reproduce

Add this block

  stickiness {
    type    = "lb_cookie"
    enabled = false
  }

to a NLB target group.

References

Metadata

Metadata

Assignees

Labels

bugAddresses a defect in current functionality.partition/aws-us-govPertains to the aws-us-gov partition.service/elbv2Issues and PRs that pertain to the elbv2 service.

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions