-
Notifications
You must be signed in to change notification settings - Fork 235
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Switch to github.com/aws/aws-sdk-go-v2 #467
base: main
Are you sure you want to change the base?
Conversation
5fa440d
to
6100164
Compare
is this going to be merged soon? there is a timeline for this? |
AWS announced an EOL date for go sdk v1 recently - https://aws.amazon.com/blogs/developer/announcing-end-of-support-for-aws-sdk-for-go-v1-on-july-31-2025/
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't have the capacity to review this more thoroughly at this point but one thing which stands out to me on a quick skim over is the old SDK v1 is still present in go.mod
. It looks like all there's needed to address that is go mod tidy
though.
6100164
to
531a6ec
Compare
@radeksimko Thank you for taking the time to look at the PR. I updated the PR, updating the file |
531a6ec
to
34dcf29
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good, @lebauce. I have a few suggestions
8726138
to
6c5ba2e
Compare
6c5ba2e
to
f2a3da8
Compare
get_s3.go
Outdated
Bucket: aws.String(bucket), | ||
Prefix: aws.String(path), | ||
} | ||
if lastMarker != "" { | ||
req.Marker = aws.String(lastMarker) | ||
req.Delimiter = aws.String(lastMarker) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't have as much experience with AWS SDK as Graham does but I'd think that delimiters are not typically used in the context of pagination. Graham mentioned earlier that we could use the native paginators, as documented at https://aws.github.io/aws-sdk-go-v2/docs/making-requests/#using-paginators
@lebauce have you considered that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@radeksimko Pagination is not supported in the current version if I'm not mistaken. Do we want to implement this in this PR ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@lebauce in this case pagination is making multiple requests to ListObjectsV2
while ContinuationToken
is set (was Marker
in ListObjects
). In aws-sdk-go-v2
, AWS has added the NewListObjectsV2Paginator
that can be used to handle pagination instead of using a for
loop.
I am also very interested in this functionality being added. Can we bubble this up? |
The aws-sdk-go-v2 was announced as general availability
in 2021 and brings few advantages such as not storing
the endpoints list as a global variable, freeing memory.