Repository navigation
feat(aws/recommendations): selectable account scope for Savings Plan recommendations (step 2 of 2) - #360
Merged
Conversation
…recommendations Read RecommendationParams.SPAccountScope (added in #357) when requesting Savings Plan recommendations. Empty and linked request LINKED, payer requests PAYER; any other value is an error, never a silent LINKED fallback. Bumps the pkg pin to cdcdc7f. Closes #356 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
|
Warning Review limit reached
This review includes 3 billable files and costs up to $0.75.
Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing. Or wait 38 minutes for your next included review. View limit details
Comment |
Member
Author
|
Independent review (claude-opus-5-5) of 80b9241: APPROVE Claims checked
Non-blocking
Evidence (fresh clone, this SHA)
|
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.
Closes #356. Step 2 of 2 (step 1: #357, merged as cdcdc7f).
What
getSavingsPlansRecommendations(providers/aws/recommendations/collection_sp.go) requestedAccountScope=LINKEDunconditionally. It now readsRecommendationParams.SPAccountScope: empty orlinked-> LINKED (unchanged default),payer-> PAYER (case-insensitive). Any other value is an error before any API call, never a silent LINKED fallback.providers/aws/go.modbumps thepkgpin to cdcdc7f (GOWORK=off GOPROXY=direct go get ...pkg@cdcdc7f, thengo mod tidy).Evidence
parser_sp_account_scope_test.go:TestSPAccountScope(empty/linked/payer/PAYER -> LINKED/LINKED/PAYER/PAYER, recorded from the SDK request) andTestSPAccountScopeRejectsUnknown(orgerrors, zero requests sent). Without the collection_sp.go change: FAIL (expected "PAYER" actual "LINKED"; unknown value returned no error). With it: PASS. Standalone check:cd providers/aws && GOWORK=off go vet ./... && GOWORK=off go test -short ./...passes;GOWORK=off go build ./...passes in providers/azure, providers/gcp and ci_cd_sanity_tests.Real account (read-only CE call, earlier): PAYER Compute SP 1yr no-upfront 30d returns one rec, $2.787/hr, $166.80/mo, 3.2%; CLI end-to-end is in cli#2185.
Next: cli#2185 bumps its pins to this merge commit.
🤖 Generated with Claude Code