From 194262a10075f88ac83890da802e2d598ec1458f Mon Sep 17 00:00:00 2001 From: Sachin Kale Date: Mon, 3 Jul 2023 21:18:44 +0530 Subject: [PATCH] Address PR comments Signed-off-by: Sachin Kale --- .../java/org/opensearch/repositories/s3/S3BlobContainer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/repository-s3/src/main/java/org/opensearch/repositories/s3/S3BlobContainer.java b/plugins/repository-s3/src/main/java/org/opensearch/repositories/s3/S3BlobContainer.java index 8e88d053901d6..49ebce77a59ad 100644 --- a/plugins/repository-s3/src/main/java/org/opensearch/repositories/s3/S3BlobContainer.java +++ b/plugins/repository-s3/src/main/java/org/opensearch/repositories/s3/S3BlobContainer.java @@ -320,7 +320,7 @@ public void listBlobsByPrefixInSortedOrder( .map(s3Object -> new PlainBlobMetadata(s3Object.key().substring(keyPath.length()), s3Object.size())) .collect(Collectors.toList()); listener.onResponse(blobs.subList(0, Math.min(limit, blobs.size()))); - } catch (final SdkException e) { + } catch (final Exception e) { listener.onFailure(new IOException("Exception when listing blobs by prefix [" + prefix + "]", e)); } }