Skip to content

feat(aws): stable-usage estimator to unlock the EC2 Instance SP base layer #31

Closed

Description

@cristim

From the LeanerCloud/cloud-commitments-cli#1340/#1347 design reviews: providers/aws/ladder.GetUsageBaseline deliberately returns StableUSDPerHour nil (no honest estimator), which makes the allocation engine route ALL core gap to the flex layer (Compute SPs). The base layer (EC2 Instance SPs, the highest-discount instrument) is therefore inert in v1 - safe, but leaves the Compute-SP-vs-EC2-Instance-SP discount delta unclaimed.

Build a real stable-usage estimator: e.g. per-family EC2 usage from CE GetSavingsPlansPurchaseRecommendation for the EC2Instance plan type (AWS already computes stable hourly commitment recommendations), or a family-level low-water percentile over instance-family usage. Output feeds UsageBaseline.StableUSDPerHour with documented semantics (post-buffer-fraction per the pkg/ladder contract).

Activity

  1. cristim commented on Oct 17, 2026

    @cristim
    MemberAuthor

    Decision needed (one line): which estimator should feed StableUSDPerHour for the EC2 Instance SP base layer: a per-family Cost Explorer GetSavingsPlansPurchaseRecommendation for EC2_INSTANCE_SP, or a family-level low-water percentile? Today GetUsageBaseline (providers/aws/ladder/baseline.go ~:122-129) returns nil, so allocate.go routes all core gap to the flex layer. Either estimator must produce the post-buffer-fraction value the pkg/ladder contract requires. Safe default: keep nil (already fail-closed). Marking status/needs-info.

  2. cristim commented on Nov 5, 2026

    @cristim
    MemberAuthor

    Owner decision (2026-11-05): Option C. Keep nil (no base layer) until #349 lands; all gap keeps routing to Compute SPs. This issue stays open as the explicit tracking item. Blocked by go#349 (#349). Next: resume once go#349 lands.

  3. added
    status/blockedBlocked on something external
    and removed
    status/needs-infoAwaiting clarification from the asker
    status/blockedBlocked on something external
    on Nov 5, 2026
  4. cristim commented on Nov 9, 2026

    @cristim
    MemberAuthor

    Claiming: building the stable-usage estimator for UsageBaseline.StableUSDPerHour as one PR. The 2026-11-05 owner decision (hold until #349) is satisfied, #349 closed on 2026-11-06, so I removed status/blocked. The estimator is opt-in behind a new AWSLadder buffer-fraction option, so behaviour is unchanged until a caller sets it. [claude-cc-platform-2]

  5. self-assigned this
    on Nov 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions