Skip to content

Cannot restore default for Unhealthy target connection termination #4648

@Moulick

Description

@Moulick

Bug Description
Cannot disable "Unhealthy target connection termination" once enabled via service.beta.kubernetes.io/aws-load-balancer-target-group-attributes

Steps to Reproduce

  1. Set service.beta.kubernetes.io/aws-load-balancer-target-group-attributes: target_health_state.unhealthy.connection_termination.enabled=false,target_health_state.unhealthy.draining_interval_seconds=30
  2. Check that the attributes have been updated in the NLB listeners
  3. Set service.beta.kubernetes.io/aws-load-balancer-target-group-attributes: target_health_state.unhealthy.connection_termination.enabled=true to restore "Unhealthy target connection termination" to the default value of On
  4. Error!

Expected Behavior
"Unhealthy target connection termination" is restored to default value of on

Actual Behavior
Controller produces error logs

{
  "level": "error",
  "ts": "2026-03-27T10:44:15Z",
  "msg": "Reconciler error",
  "controller": "service",
  "namespace": "<redacted>",
  "name": "<redacted>",
  "reconcileID": "fb74de70-370f-4699-a8cf-73ef7109bfd3",
  "error": "operation error Elastic Load Balancing v2: ModifyTargetGroupAttributes, https response error StatusCode: 400, RequestID: 6f933ac7-86fb-4cef-87cf-744255993e14, 
InvalidConfigurationRequest: You cannot have both 'target_health_state.unhealthy.connection_termination.enabled' and 'target_health_state.unhealthy.draining_interval_seconds' enabled on a target group"
}

Regression
Not sure

Current Workarounds

ClickOps

Environment

  • AWS Load Balancer controller version: v3.1.0
  • Kubernetes version: v1.33.8-eks-3a10415
  • Using EKS (yes/no), if so version?: Yes v1.33.8-eks-3a10415
  • Using Service or Ingress: Service
  • AWS region: eu-west-1

Contribution Intention (Optional)

  • Yes, I'm willing to submit a PR to fix this issue
  • No, I cannot work on a PR at this time

Additional Context

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions