I\'ve been working for some time with aws java API with not so many problems. Currently I\'m using the library 1.5.2 version.
When I\'m iterating the objects inside a f
Check if HttpResponseHandler is closing connections from the pool. AmazonHttpClient has the paramter 'leaveHttpConnectionOpen' which indicates that the connection should be closed or not.
I've found that S3Object opens a connection for each object. That are not liberated even if the object is garbage collected so it is needed to execute object.close(), in order to liberate the connection to the pool.
So the corrected code would be:
for (S3ObjectSummary objectSummary : current.getObjectSummaries()) {
S3Object object = s3.getObject(new GetObjectRequest(bucketName, objectSummary.getKey()));
System.out.println(object.getKey());
object.close();
}