Skip to content

deps: remove aws-sdk-go-cache library#526

Open
tekenstam wants to merge 3 commits intomasterfrom
deps/remove-aws-sdk-go-cache
Open

deps: remove aws-sdk-go-cache library#526
tekenstam wants to merge 3 commits intomasterfrom
deps/remove-aws-sdk-go-cache

Conversation

@tekenstam
Copy link
Member

Summary

  • Removes keikoproj/aws-sdk-go-cache from instance-manager as part of the AWS SDK v1 deprecation effort (closes chore: deprecate and remove aws-sdk-go-cache dependency #525)
  • Drops the cacheCfg parameter from all five GetAws*Client constructors and removes all cache.AddCaching, SetCacheTTL, and SetExcludeFlushing calls
  • Removes all TTL constants and cache config constants from aws.go, and removes cacheCollector Prometheus registration from main.go
  • Runs go mod tidy to drop aws-sdk-go-cache, karlseguin/ccache/v2, and golang/glog

The existing RetryLogger with throttle metrics and custom backoff delays is preserved unchanged. AWS SDK v1's built-in retry logic handles rate limiting without the cache layer.

Test plan

  • go build ./... passes
  • go test ./... passes (all existing tests green)
  • go vet ./... passes
  • No aws-sdk-go-cache imports remain in source files

🤖 Generated with Claude Code

@tekenstam tekenstam requested review from a team as code owners March 23, 2026 16:17
Remove keikoproj/aws-sdk-go-cache from instance-manager as part of the
AWS SDK v1 deprecation effort. The library provided response caching for
AWS SDK v1 sessions to mitigate rate limiting, but this is no longer
needed:

- AWS SDK v1 is EOL with no v2 equivalent for the cache library
- AWS SDK v2's built-in adaptive retry/token-bucket rate limiting covers
  the same concern
- Rate limiting has not been a practical issue in production

Changes:
- Remove cacheCfg parameter from all five GetAws*Client constructors
- Remove cache.AddCaching, SetCacheTTL, and SetExcludeFlushing calls
- Remove cache-hit logging handlers from all client constructors
- Remove all TTL constants and cache config constants from aws.go
- Remove cacheCollector Prometheus registration from main.go
- Run go mod tidy to drop aws-sdk-go-cache, ccache/v2, and golang/glog

The existing RetryLogger with throttle metrics and custom backoff delays
is preserved unchanged.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Todd Ekenstam <todd_ekenstam@intuit.com>
@tekenstam tekenstam force-pushed the deps/remove-aws-sdk-go-cache branch from 8ed2476 to dba766d Compare March 23, 2026 16:19
@codecov-commenter
Copy link

codecov-commenter commented Mar 23, 2026

Codecov Report

❌ Patch coverage is 0% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 47.76%. Comparing base (f2facaa) to head (dbbf705).

Files with missing lines Patch % Lines
controllers/providers/aws/autoscaling.go 0.00% 1 Missing ⚠️
controllers/providers/aws/ec2.go 0.00% 1 Missing ⚠️
controllers/providers/aws/eks.go 0.00% 1 Missing ⚠️
controllers/providers/aws/iam.go 0.00% 1 Missing ⚠️
controllers/providers/aws/ssm.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #526      +/-   ##
==========================================
+ Coverage   46.89%   47.76%   +0.86%     
==========================================
  Files          40       40              
  Lines        5879     5816      -63     
==========================================
+ Hits         2757     2778      +21     
+ Misses       2964     2878      -86     
- Partials      158      160       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Todd Ekenstam and others added 2 commits March 23, 2026 09:24
Add coverage for NewRetryLogger and RetryRules to verify the retry
mechanism works correctly now that aws-sdk-go-cache has been removed
and RetryLogger is the sole rate-limit resilience layer.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Todd Ekenstam <todd_ekenstam@intuit.com>
Brings in Go 1.26, K8s 1.33 client-go, and keikoproj libs updates
from master (#521). Resolved go.mod/go.sum conflicts by applying
master's dependency updates while keeping aws-sdk-go-cache removed
(the purpose of this PR).

Signed-off-by: Todd Ekenstam <todd_ekenstam@intuit.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

chore: deprecate and remove aws-sdk-go-cache dependency

2 participants