@@ -60,9 +60,7 @@ public AzureBlobContainer(BlobPath path, AzureBlobStore blobStore) {
60
60
public boolean blobExists (String blobName ) {
61
61
try {
62
62
return blobStore .client ().blobExists (blobStore .container (), buildKey (blobName ));
63
- } catch (URISyntaxException e ) {
64
- logger .warn ("can not access [{}] in container {{}}: {}" , blobName , blobStore .container (), e .getMessage ());
65
- } catch (StorageException e ) {
63
+ } catch (URISyntaxException | StorageException e ) {
66
64
logger .warn ("can not access [{}] in container {{}}: {}" , blobName , blobStore .container (), e .getMessage ());
67
65
}
68
66
return false ;
@@ -98,10 +96,7 @@ public OutputStream createOutput(String blobName) throws IOException {
98
96
public void deleteBlob (String blobName ) throws IOException {
99
97
try {
100
98
blobStore .client ().deleteBlob (blobStore .container (), buildKey (blobName ));
101
- } catch (URISyntaxException e ) {
102
- logger .warn ("can not access [{}] in container {{}}: {}" , blobName , blobStore .container (), e .getMessage ());
103
- throw new IOException (e );
104
- } catch (StorageException e ) {
99
+ } catch (URISyntaxException | StorageException e ) {
105
100
logger .warn ("can not access [{}] in container {{}}: {}" , blobName , blobStore .container (), e .getMessage ());
106
101
throw new IOException (e );
107
102
}
@@ -112,13 +107,7 @@ public ImmutableMap<String, BlobMetaData> listBlobsByPrefix(@Nullable String pre
112
107
113
108
try {
114
109
return blobStore .client ().listBlobsByPrefix (blobStore .container (), keyPath , prefix );
115
- } catch (URISyntaxException e ) {
116
- logger .warn ("can not access [{}] in container {{}}: {}" , prefix , blobStore .container (), e .getMessage ());
117
- throw new IOException (e );
118
- } catch (StorageException e ) {
119
- logger .warn ("can not access [{}] in container {{}}: {}" , prefix , blobStore .container (), e .getMessage ());
120
- throw new IOException (e );
121
- } catch (ServiceException e ) {
110
+ } catch (URISyntaxException | StorageException | ServiceException e ) {
122
111
logger .warn ("can not access [{}] in container {{}}: {}" , prefix , blobStore .container (), e .getMessage ());
123
112
throw new IOException (e );
124
113
}
0 commit comments