feat(gcp): add External IP catalog pricing (RC3-023a, #76) - #91
Merged
Conversation
Live-verified against Cloud Billing Catalog API + cloud.google.com/vpc/network-pricing: - External IP Charge on a Standard VM (C054-7F72-A02E): $0.005/hr, global - External IP Charge on a Spot Preemptible VM (4AF8-7C1F-39C4): $0.0025/hr, global Reserved-but-unattached Static IP charges (per-region, ~38 SKU variants) are intentionally out of scope -- a different billing question from an attached external IP.
- Match SKU descriptions via case-insensitive substring (consistent with every other matcher in this file) instead of brittle exact string equality - Remove skuLastNonZeroTierPrice; dispatch to the existing skuPaidPrice/ skuPrice helpers by known vmType instead of a duplicate tier-walker - Collapse redundant rate==0 double-check in the fallback path - Cache the derived standard/spot rates (fetchExternalIPRates) so a caller requesting both terms doesn't re-unmarshal/re-scan the full SKU catalog
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
network/external_ip) toDescribeCatalog, closing the zero-catalog-entry gap for issue RC3-023a (P2, LOWEST-RISK — needs live GCP catalog access): GCP External IP has zero catalog entry #76.cloud.google.com/vpc/network-pricing:C054-7F72-A02E, global scope)4AF8-7C1F-39C4, global scope)/code-reviewpass; all 6 surviving findings (fragile exact-string SKU matching, a duplicated tier-parsing helper, a redundant double-check, and a missing rate cache) were fixed in a follow-up commit.Test plan
go build ./...,go vet ./...,go test ./... -count=1— all packages passCloses #76.