Skip to content

isInExtendedSupport silently accepts zero LifecycleSupportStartDate #1315

Closed

Description

@cristim

Summary

After PR #1234, isInExtendedSupport (cmd/multi_service_engine_versions.go:399-416) treats a zero LifecycleSupportEndDate as "open-ended" (intentional, for engines whose end-of-extended-support has not yet been published). But it also treats a zero LifecycleSupportStartDate permissively — now.Before(time.Time{}) is false, so the start gate is skipped. Combined, an extended-support lifecycle entry with both dates absent in the AWS response will be classified as currently in extended support, with no log line surfacing that the data was anomalous.

In practice this is unlikely (the RDS API normally returns both dates when it returns the lifecycle name), but if it does occur:

  • false-positive: instance is dropped from the recommendation count even though we have no evidence the support window is currently active,
  • silent — the responsible code path has no logging when the input is suspicious.

Per feedback_no_silent_fallbacks.md, an anomalous SDK payload on a money-relevant path should fail loud (or at minimum log + metric) rather than be coerced to a default.

Suggested fix

In isInExtendedSupport, when LifecycleSupportName == OpenSourceRdsExtendedSupport AND LifecycleSupportStartDate.IsZero():

  • emit a structured warn log identifying the engine/version,
  • skip the entry (treat as "unknown lifecycle window") rather than implicitly accepting it.

Optional: also surface the count via a metric so missing-date payloads are observable.

Why not in #1234

Pre-existing behaviour; the PR's scope is the missing end-date check. Adding loud handling for missing start-date is adjacent but not the same defect.

Acceptance criteria

  • Extended-support entry with LifecycleSupportStartDate.IsZero() no longer returns true silently.
  • A structured log line is emitted with engine + major version when the anomaly is observed.
  • Unit test covers the "name == extended, start zero, end zero" and "name == extended, start zero, end future" inputs against the new policy.

Triage

  • priority/p3
  • severity/low (degenerate AWS payload; not observed in practice)
  • urgency/eventually
  • impact/few
  • effort/xs
  • type/bug
  • triaged

Related: PR #1234, feedback_no_silent_fallbacks.md.

Activity

  1. IAmJSD commented on Oct 16, 2026

    @IAmJSD
    Collaborator

    Claiming: working on this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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