Remove FF_USE_LEGACY_KUBERNETES_EXECUTION_STRATEGY

Description

  • Flag: FF_USE_LEGACY_KUBERNETES_EXECUTION_STRATEGY
  • Current category: Legacy switch-back, the default is already right

Introduced by:

Flip history:

  • 2020-03-10: Introduced with default true (exec mode)
  • 2021-06-14: Default changed to false via !2955 (merged) (attach mode became default)
  • No reverts: Flag has been stable at false for 5.2 years

Open issues referencing the flag:

  • #27976 (closed) - Parent tracking issue (opened 2021-06-10)
  • Historical issues requiring legacy mode (all resolved):
    • #27099 (closed) - Log formatting issues
    • #29667 - Build failures
    • Windows Server 2019 build hangs (resolved in 14.2+)

Author contacted?: No.

  • Original MR !1775 (merged) introduced attach strategy to solve #4119 (closed)
  • Attach became default in 2021 after successful rollout
  • Support team (comment from 2023) noted customers relied on flag as workaround, but all blocking issues now resolved

Verdict: Categorization confirmed — REMOVE

Evidence:

  1. Default has been correct (attach mode) for 5.2 years — longest in this category
  2. All known customer issues requiring legacy mode are resolved
  3. No recent escalations requiring exec mode
  4. Legacy code path adds significant maintenance burden
  5. Attach mode is the only actively maintained execution strategy

Action:

What was removed:

  • Feature flag definition in helpers/featureflags/flags.go
  • Legacy exec mode code paths in executors/kubernetes/kubernetes.go
  • shouldUseStartupProbe() logic (startup probes only existed in exec mode)
  • Conditional scripts volume mounting (always needed in attach mode)
  • Conditional permissions init container (always needed in attach mode)
  • Exec mode integration tests
  • Documentation references

Testing:

  • ✅ Unit tests pass: make test
  • ✅ Integration tests pass: make integration_k8s
  • ✅ No functionality regression

⚠️ Removal caveat: Grepped for both FF_USE_LEGACY_KUBERNETES_EXECUTION_STRATEGY literal string and UseLegacyKubernetesExecutionStrategy Go identifier to ensure complete removal.

📝 Epic table updated: Row for FF_USE_LEGACY_KUBERNETES_EXECUTION_STRATEGY in epic #23127 marked as 🚧 with this issue link.

Edited by Ashvin Sharma