Skip to content

feat(gcp): retain checked catalog commitment currency - #412

Merged
cristim merged 1 commit into
mainfrom
feat/gcp-commitment-currency
Oct 15, 2026
Merged

cristim merged 1 commit into
mainfrom
feat/gcp-commitment-currency

Conversation

@cristim

@cristim cristim commented Oct 15, 2026

Copy link
Copy Markdown
Member

Fresh Compute Engine, Cloud SQL and Memorystore recommendations now retain CommitmentCurrency from the checked billing catalog beside their known commitment amounts. Catalog failures, missing/mixed currencies and unusable SQL/Redis prices keep the field unknown. Recommender savings currency remains separate.

Pin the GCP module's minimum shared package to the published contract from #410 so standalone consumers receive the field without workspace replacements. The amount, scorer and offering behavior from #408 is unchanged.

Validation: Go 1.26.9 standalone GCP race suite and build, golangci-lint 2.10.1, and normal commit hooks pass. New fixture assertions compile and fail on the parent producer code, then pass after the assignments. EUR catalog prices with JPY Recommender savings yield EUR commitment currency; invalid catalog and scaling paths are covered. An owned scratch USD-default mutation fails all three services' EUR assertions. These are injected SDK fixtures, not live cloud acceptance.

Closes #411
Refs #124

Copy the checked pricing currency beside known commitment amounts.
Leave failed or incomplete catalog prices unknown and keep savings
currency separate. Pin the published shared contract for standalone use.

Closes #411
@cristim cristim added priority/p2 Backlog-worthy severity/medium Moderate harm triaged Item has been triaged urgency/this-sprint Within the current sprint impact/many Affects most users effort/s Hours type/feat New capability labels Oct 15, 2026
@coderabbitai

coderabbitai Bot commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

  • Run on-demand review

This review includes 10 billable files and costs up to $2.50.

  • Ask an admin to make reviews automatic

Open in CodeRabbit

Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing.

Or wait 7 minutes for your next included review.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 61 included PR review attempts over the past 7 days set your current allowance at 1 review per hour.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Repository: LeanerCloud/cloud-commitments-go/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: 69d0c904-2630-441d-8028-316e5756e18a
📥 Commits

Reviewing files that changed from the base of the PR and between 498b74f and 09730be.

⛔ Files ignored due to path filters: 1
  • providers/gcp/go.sum is excluded by !**/*.sum
📒 Files selected for processing: 10
  • providers/gcp/go.mod
  • providers/gcp/services/cloudsql/client.go
  • providers/gcp/services/cloudsql/client_test.go
  • providers/gcp/services/cloudsql/pricing_currency_test.go
  • providers/gcp/services/computeengine/client.go
  • providers/gcp/services/computeengine/client_test.go
  • providers/gcp/services/computeengine/pricing_test.go
  • providers/gcp/services/memorystore/client.go
  • providers/gcp/services/memorystore/client_test.go
  • providers/gcp/services/memorystore/pricing_currency_test.go
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

@cristim

cristim commented Oct 15, 2026

Copy link
Copy Markdown
Member Author

Independent cold verification: TWO retained adversarial passes, no actionable findings at exact head 09730be3fc053ccaea08c28e3fb41178ab4748f5, tree 4e63e0c3f7521c45a17c73dec3d3d3124ff8053f, base 498b74f31f01aca9b2c795d1dce9d85c790eabea.

The independent verifier traced catalog validation and all three actual public GetRecommendations producers through the published common module, real scaling/resizing, JSON transport, break-even/scorer/reporter and offering quotes. EUR catalog prices with deliberately different JPY Recommender savings retained EUR commitment currency. Missing/mixed/negative/failed pricing stayed unknown. Monthly cashflows and quote totals stayed unchanged.

The independent fixtures fail on the exact parent producers at intended runtime currency assertions, with only the published dependency overlaid so the new field compiles. A separate scratch mutation fabricating USD also fails all three services; restored sources pass and match the reviewed commit. Full standalone GCP race suite, build and pinned golangci-lint2.10.1 pass with ambient credentials disabled. Normal author hooks also pass.

Evidence is synthetic SDK/catalog fixture data exercising actual production and published common code on macOS. No live cloud economics or account acceptance is claimed. Savings/baseline currency and platform compatibility/persistence are separate work under #124. The shared allocator migration must be adopted properly before platform pins advance.

Cold receipt SHA256: b4512f19c7576df6c8634d41a9b562af6bc8582084e4e30bd867da2e80bb07b0.

@cristim

cristim commented Oct 15, 2026

Copy link
Copy Markdown
Member Author

Final merge gate at reviewed head 09730be: required CI and pre-commit succeeded, merge state CLEAN/MERGEABLE, no review threads, exact independent two-pass verdict and local producer verification recorded above. CR waived: quota, adversarial review + local verification + green CI. No manual quota retry or bypass. This ships a standalone GCP producer; platform dependency adoption remains separate under #124.

@cristim
cristim merged commit c2a461a into main Oct 15, 2026
15 checks passed
@cristim

cristim commented Oct 15, 2026

Copy link
Copy Markdown
Member Author

Merged normally in #412 at c2a461a801e3541860893f62a05e825364ac74a2; the merged tree is exactly the independently reviewed tree 4e63e0c3f7521c45a17c73dec3d3d3124ff8053f.

Published GCP module v0.0.0-20261015095304-c2a461a801e3 resolves to that origin commit. Its downloaded Compute Engine, Cloud SQL and Memorystore currency/cashflow regression tests pass with race detection and ambient credentials disabled. These cover EUR catalog versus JPY savings, missing/mixed/failed/negative pricing, monthly cashflows, scaling, break-even/scorer and retained offering totals.

A clean external module initially requiring only that GCP version naturally selected shared pkg v0.0.0-20261015085730-498b74f31f01. After normal tidy, its actual common JSON/scaling consumer passes legacy/new currency, unknown monthly and known-zero monthly/pointer-isolation cases. No replacement or workspace was used.

Main pre-commit run38716233126 passed; main build/test run38716233119 remains watched. Fixture/library evidence proves the published producer contract, not live cloud prices or platform adoption. Remaining currency/platform work stays under #124. No new GCP follow-up issues surfaced beyond existing #399, #406 and #407.

@cristim
cristim deleted the feat/gcp-commitment-currency branch October 15, 2026 09:59
@cristim

cristim commented Oct 15, 2026

Copy link
Copy Markdown
Member Author

Final post-merge result: main build/test run38716233119 completed successfully at c2a461a, and main pre-commit run38716233126 also passed. Published GCP producer and natural dependency consumer verification passed as recorded above. Merged worktree and both feature refs have been cleaned up. This GCP producer leaf is complete; platform adoption remains separate under #124.

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

Labels

effort/s Hours impact/many Affects most users priority/p2 Backlog-worthy severity/medium Moderate harm triaged Item has been triaged type/feat New capability urgency/this-sprint Within the current sprint

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(gcp): retain checked catalog commitment currency

1 participant