Remove IOException never thrown in S3Resource methods #1108
Labels
component: s3
S3 integration related issue
type: enhancement
Smaller enhancement in existing integration
Milestone
Type: Feature
Is your feature request related to a problem? Please describe.
Several methods of the S3Resource object throw IOExceptions in their signature. But Exception is never thrown in those methods.
Use cases where this is a problem :
I use
listObject()
method inS3Template
. I want to usecontentLength
orlastModified
fields ofS3Resource
to sort the list, but I need to catch IOException in the comparator.Maybe I missed something but I think that we can remove them.
Describe the solution you'd like
Remove IOException declaration in method signatures in
S3Resource
.I know that
S3Resource
inheritsAbstractResource
. So I don't know if it is a problem for you to remove the exception in someS3Resource
methods. Moreover, most uses ofS3Resource
are made via theS3Template
, so there's no reference to the parent class.If it is ok for you, you can assign me the ticket, I can make a PR quickly.
Additional context
Some examples :
The text was updated successfully, but these errors were encountered: