Github user d2r commented on a diff in the pull request:
https://github.com/apache/storm/pull/2925#discussion_r240366381
--- Diff:
storm-client/src/jvm/org/apache/storm/dependency/DependencyUploader.java ---
@@ -154,11 +154,22 @@ private boolean uploadDependencyToBlobStore(String
key, File dependency)
acls.add(new AccessControl(AccessControlType.OTHER,
BlobStoreAclHandler.READ));
- AtomicOutputStream blob = getBlobStore().createBlob(key, new
SettableBlobMeta(acls));
- Files.copy(dependency.toPath(), blob);
- blob.close();
+ AtomicOutputStream blob = null;
+ try {
+ blob = getBlobStore().createBlob(key, new
SettableBlobMeta(acls));
+ Files.copy(dependency.toPath(), blob);
+ blob.close();
- uploadNew = true;
+ uploadNew = true;
--- End diff --
Actually we probably want to remove the call to `close`, since it will
happen in the `finally` block now.
---