You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@storm.apache.org by bo...@apache.org on 2016/01/06 22:07:29 UTC
[1/4] storm git commit: added backward compatibility method for File
Download
Repository: storm
Updated Branches:
refs/heads/master 7f49cba37 -> c7cb25d99
added backward compatibility method for File Download
long line, moving it to next line
indentation
auth exception
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/547ad08d
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/547ad08d
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/547ad08d
Branch: refs/heads/master
Commit: 547ad08d34ea5c0dbd9cc339c1a4a9d4803ed763
Parents: 5689085
Author: Sanket <sc...@untilservice-lm>
Authored: Wed Dec 16 17:07:12 2015 -0600
Committer: Sanket <sc...@untilservice-lm>
Committed: Fri Dec 18 13:24:38 2015 -0600
----------------------------------------------------------------------
storm-core/src/clj/backtype/storm/daemon/nimbus.clj | 12 ++++++------
.../src/jvm/backtype/storm/blobstore/BlobStore.java | 4 ++--
storm-core/src/storm.thrift | 3 ++-
3 files changed, 10 insertions(+), 9 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/storm/blob/547ad08d/storm-core/src/clj/backtype/storm/daemon/nimbus.clj
----------------------------------------------------------------------
diff --git a/storm-core/src/clj/backtype/storm/daemon/nimbus.clj b/storm-core/src/clj/backtype/storm/daemon/nimbus.clj
index f97d386..8f4c730 100644
--- a/storm-core/src/clj/backtype/storm/daemon/nimbus.clj
+++ b/storm-core/src/clj/backtype/storm/daemon/nimbus.clj
@@ -1716,15 +1716,15 @@
(.remove uploaders location)
))
- (^String beginFileDownload [this ^String file]
- (mark! nimbus:num-beginFileDownload-calls)
+ (^String beginFileDownload
+ [this ^String file]
(check-authorization! nimbus nil nil "fileDownload")
- (check-file-access (:conf nimbus) file)
- (let [is (BufferFileInputStream. file)
+ (let [is (BufferInputStream. (.getBlob (:blob-store nimbus) file nil)
+ ^Integer (Utils/getInt (conf STORM-BLOBSTORE-INPUTSTREAM-BUFFER-SIZE-BYTES)
+ (int 65536)))
id (uuid)]
(.put (:downloaders nimbus) id is)
- id
- ))
+ id))
(^ByteBuffer downloadChunk [this ^String id]
(mark! nimbus:num-downloadChunk-calls)
http://git-wip-us.apache.org/repos/asf/storm/blob/547ad08d/storm-core/src/jvm/backtype/storm/blobstore/BlobStore.java
----------------------------------------------------------------------
diff --git a/storm-core/src/jvm/backtype/storm/blobstore/BlobStore.java b/storm-core/src/jvm/backtype/storm/blobstore/BlobStore.java
index 2eba1d9..16a408e 100644
--- a/storm-core/src/jvm/backtype/storm/blobstore/BlobStore.java
+++ b/storm-core/src/jvm/backtype/storm/blobstore/BlobStore.java
@@ -193,10 +193,10 @@ public abstract class BlobStore implements Shutdownable {
* Validates key checking for potentially harmful patterns
* @param key Key for the blob.
*/
- public static final void validateKey(String key) {
+ public static final void validateKey(String key) throws AuthorizationException {
if (StringUtils.isEmpty(key) || "..".equals(key) || ".".equals(key) || !KEY_PATTERN.matcher(key).matches()) {
LOG.error("'{}' does not appear to be valid {}", key, KEY_PATTERN);
- throw new IllegalArgumentException(key+" does not appear to be a valid blob key");
+ throw new AuthorizationException(key+" does not appear to be a valid blob key");
}
}
http://git-wip-us.apache.org/repos/asf/storm/blob/547ad08d/storm-core/src/storm.thrift
----------------------------------------------------------------------
diff --git a/storm-core/src/storm.thrift b/storm-core/src/storm.thrift
index 08be005..849ae74 100644
--- a/storm-core/src/storm.thrift
+++ b/storm-core/src/storm.thrift
@@ -629,7 +629,8 @@ service Nimbus {
string beginFileUpload() throws (1: AuthorizationException aze);
void uploadChunk(1: string location, 2: binary chunk) throws (1: AuthorizationException aze);
void finishFileUpload(1: string location) throws (1: AuthorizationException aze);
-
+
+ //@deprecated beginBlobDownload does that
string beginFileDownload(1: string file) throws (1: AuthorizationException aze);
//can stop downloading chunks when receive 0-length byte array back
binary downloadChunk(1: string id) throws (1: AuthorizationException aze);
[4/4] storm git commit: Added STORM-1396 to Changelog
Posted by bo...@apache.org.
Added STORM-1396 to Changelog
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/c7cb25d9
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/c7cb25d9
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/c7cb25d9
Branch: refs/heads/master
Commit: c7cb25d997899e815a0d1f68c49a399914c9a173
Parents: 1e2a583
Author: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Authored: Wed Jan 6 14:58:15 2016 -0600
Committer: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Committed: Wed Jan 6 14:58:15 2016 -0600
----------------------------------------------------------------------
CHANGELOG.md | 1 +
1 file changed, 1 insertion(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/storm/blob/c7cb25d9/CHANGELOG.md
----------------------------------------------------------------------
diff --git a/CHANGELOG.md b/CHANGELOG.md
index bdad287..7711a2f 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,4 +1,5 @@
## 0.11.0
+ * STORM-1396: Added backward compatibility method for File Download
* STORM-695: storm CLI tool reports zero exit code on error scenario
* STORM-1416: Documentation for state store
* STORM-1426: keep backtype.storm.tuple.AddressedTuple and delete duplicated backtype.storm.messaging.AddressedTuple
[3/4] storm git commit: Merge branch 'blob-back-compatibility' of
https://github.com/redsanket/storm into STORM-1396
Posted by bo...@apache.org.
Merge branch 'blob-back-compatibility' of https://github.com/redsanket/storm into STORM-1396
STORM-1396: Added backward compatibility method for File Download
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/1e2a583f
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/1e2a583f
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/1e2a583f
Branch: refs/heads/master
Commit: 1e2a583ff805935396f50c79e122b7688cc6e156
Parents: 7f49cba 2a77093
Author: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Authored: Wed Jan 6 14:57:48 2016 -0600
Committer: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Committed: Wed Jan 6 14:57:48 2016 -0600
----------------------------------------------------------------------
storm-core/src/clj/backtype/storm/daemon/nimbus.clj | 11 ++++++-----
.../src/jvm/backtype/storm/blobstore/BlobStore.java | 4 ++--
storm-core/src/storm.thrift | 3 ++-
3 files changed, 10 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/storm/blob/1e2a583f/storm-core/src/clj/backtype/storm/daemon/nimbus.clj
----------------------------------------------------------------------
[2/4] storm git commit: adding back accidentally deleted metrics
Posted by bo...@apache.org.
adding back accidentally deleted metrics
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/2a770938
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/2a770938
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/2a770938
Branch: refs/heads/master
Commit: 2a7709383567b90be9bb347201db19c2a692f4db
Parents: 547ad08
Author: Sanket <sc...@untilservice-lm>
Authored: Tue Jan 5 15:26:51 2016 -0600
Committer: Sanket <sc...@untilservice-lm>
Committed: Tue Jan 5 15:26:51 2016 -0600
----------------------------------------------------------------------
storm-core/src/clj/backtype/storm/daemon/nimbus.clj | 1 +
1 file changed, 1 insertion(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/storm/blob/2a770938/storm-core/src/clj/backtype/storm/daemon/nimbus.clj
----------------------------------------------------------------------
diff --git a/storm-core/src/clj/backtype/storm/daemon/nimbus.clj b/storm-core/src/clj/backtype/storm/daemon/nimbus.clj
index 8f4c730..0667d49 100644
--- a/storm-core/src/clj/backtype/storm/daemon/nimbus.clj
+++ b/storm-core/src/clj/backtype/storm/daemon/nimbus.clj
@@ -1718,6 +1718,7 @@
(^String beginFileDownload
[this ^String file]
+ (mark! nimbus:num-beginFileDownload-calls)
(check-authorization! nimbus nil nil "fileDownload")
(let [is (BufferInputStream. (.getBlob (:blob-store nimbus) file nil)
^Integer (Utils/getInt (conf STORM-BLOBSTORE-INPUTSTREAM-BUFFER-SIZE-BYTES)