geotrellis icon indicating copy to clipboard operation
geotrellis copied to clipboard

LayerDeleter does not return information on deleted objects

Open zacdezgeo opened this issue 3 years ago • 1 comments

Description of Request

I have been coming across some difficulties when deleting S3 layers. Having some information on the result of the delete request would be very interesting for implementing additional logic when failures occur.

Proposed Solution

I would like to see the status or even the unsuccessfully deleted objects of the s3Client.deleteObjects request. Something like in the AWS's documentation.

DeleteObjectsResult delObjRes = s3Client.deleteObjects(multiObjectDeleteRequest);
int successfulDeletes = delObjRes.getDeletedObjects().size();

@pomadchin mentionned that all the backends have their corresponding LayerDeleters fand the error encoding should be encoded with all of them.

Describe alternatives you've considered

I am not sure of the direction the effort should take to synchronize all of the backends. I would be happy to contribute to updating the S3 backend.

zacdezgeo avatar Apr 07 '21 13:04 zacdezgeo

I'll add an explicit ref to the comment that triggered this issue creation: https://github.com/locationtech/geotrellis/pull/3372#issuecomment-814891747

Thanks for spending some time to make this one! 🚀

pomadchin avatar Apr 07 '21 13:04 pomadchin