We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2488456 commit 8ea9951Copy full SHA for 8ea9951
src/main/java/org/elasticsearch/cloud/azure/blobstore/AbstractAzureBlobContainer.java
@@ -33,6 +33,7 @@
33
import java.io.FileNotFoundException;
34
import java.io.IOException;
35
import java.io.InputStream;
36
+import java.net.HttpURLConnection;
37
import java.net.URISyntaxException;
38
39
/**
@@ -97,7 +98,7 @@ public void run() {
97
98
is.close();
99
listener.onCompleted();
100
} catch (ServiceException e) {
- if (e.getHttpStatusCode() == 404) {
101
+ if (e.getHttpStatusCode() == HttpURLConnection.HTTP_NOT_FOUND) {
102
listener.onFailure(new FileNotFoundException(e.getMessage()));
103
} else {
104
listener.onFailure(e);
0 commit comments