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 2015/09/29 16:18:28 UTC
[1/4] storm git commit: [STORM-123],
add check case for external change of 'now' value.
Repository: storm
Updated Branches:
refs/heads/master ae4b5532e -> ced622433
[STORM-123], add check case for external change of 'now' value.
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/7d528554
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/7d528554
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/7d528554
Branch: refs/heads/master
Commit: 7d5285545a4d4f227f7f8616c2f769f055649560
Parents: 99285bb
Author: ddragan <dm...@gmail.com>
Authored: Fri Sep 25 17:58:07 2015 +0300
Committer: ddragan <dm...@gmail.com>
Committed: Fri Sep 25 17:58:07 2015 +0300
----------------------------------------------------------------------
.../storm-kafka/src/jvm/storm/kafka/KafkaSpout.java | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/storm/blob/7d528554/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java
----------------------------------------------------------------------
diff --git a/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java b/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java
index 1743810..9c34c57 100644
--- a/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java
+++ b/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java
@@ -6,9 +6,9 @@
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
- *
+ * <p/>
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ * <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -154,8 +154,8 @@ public class KafkaSpout extends BaseRichSpout {
}
}
- long now = System.currentTimeMillis();
- if ((now - _lastUpdateMs) > _spoutConfig.stateUpdateIntervalMs) {
+ long diffWithNow = System.currentTimeMillis() - _lastUpdateMs;
+ if (diffWithNow > _spoutConfig.stateUpdateIntervalMs || diffWithNow < 0) {
commit();
}
}
@@ -185,11 +185,11 @@ public class KafkaSpout extends BaseRichSpout {
@Override
public void declareOutputFields(OutputFieldsDeclarer declarer) {
- if (_spoutConfig.topicAsStreamId) {
- declarer.declareStream(_spoutConfig.topic, _spoutConfig.scheme.getOutputFields());
- } else {
+ if (_spoutConfig.topicAsStreamId) {
+ declarer.declareStream(_spoutConfig.topic, _spoutConfig.scheme.getOutputFields());
+ } else {
declarer.declare(_spoutConfig.scheme.getOutputFields());
- }
+ }
}
private void commit() {
[4/4] storm git commit: Added STORM-1069 to Changelog and Readme
Posted by bo...@apache.org.
Added STORM-1069 to Changelog and Readme
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/ced62243
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/ced62243
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/ced62243
Branch: refs/heads/master
Commit: ced622433eaff81d7039d384c3acf5de595b0a70
Parents: 829798e
Author: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Authored: Tue Sep 29 09:08:50 2015 -0500
Committer: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Committed: Tue Sep 29 09:08:50 2015 -0500
----------------------------------------------------------------------
CHANGELOG.md | 1 +
README.markdown | 1 +
2 files changed, 2 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/storm/blob/ced62243/CHANGELOG.md
----------------------------------------------------------------------
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 4ecbed0..a6639f3 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,4 +1,5 @@
## 0.11.0
+ * STORM-1069: add check case for external change of 'now' value.
* STORM-969: HDFS Bolt can end up in an unrecoverable state.
* STORM-1068: Configure request.required.acks to be 1 in KafkaUtilsTest for sync
* STORM-1017: If ignoreZkOffsets set true,KafkaSpout will reset zk offset when recover from failure.
http://git-wip-us.apache.org/repos/asf/storm/blob/ced62243/README.markdown
----------------------------------------------------------------------
diff --git a/README.markdown b/README.markdown
index 90a79c5..4347e30 100644
--- a/README.markdown
+++ b/README.markdown
@@ -232,6 +232,7 @@ under the License.
* Matthias J. Sax ([@mjsax](https://github.com/mjsax))
* Erik Weathers ([@erikdw](https://github.com/erikdw))
* Bryan Shell ([@shellbj](https://github.com/shellbj))
+* Dmytro Dragan ([@3Dragan](https://github.com/3Dragan))
## Acknowledgements
[2/4] storm git commit: add a comment description
Posted by bo...@apache.org.
add a comment description
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/cc082aa9
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/cc082aa9
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/cc082aa9
Branch: refs/heads/master
Commit: cc082aa93e5da92c4c3f635420fabf8bb6e60bf3
Parents: 7d52855
Author: dragan <dm...@gmail.com>
Authored: Fri Sep 25 19:37:50 2015 +0300
Committer: dragan <dm...@gmail.com>
Committed: Fri Sep 25 19:37:50 2015 +0300
----------------------------------------------------------------------
external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java | 5 +++++
1 file changed, 5 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/storm/blob/cc082aa9/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java
----------------------------------------------------------------------
diff --git a/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java b/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java
index 9c34c57..d9f1c52 100644
--- a/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java
+++ b/external/storm-kafka/src/jvm/storm/kafka/KafkaSpout.java
@@ -155,6 +155,11 @@ public class KafkaSpout extends BaseRichSpout {
}
long diffWithNow = System.currentTimeMillis() - _lastUpdateMs;
+
+ /*
+ As far as the System.currentTimeMillis() is dependent on System clock,
+ additional check on negative value of diffWithNow in case of external changes.
+ */
if (diffWithNow > _spoutConfig.stateUpdateIntervalMs || diffWithNow < 0) {
commit();
}
[3/4] storm git commit: Merge branch 'master' of
https://github.com/3Dragan/storm into STORM-1069
Posted by bo...@apache.org.
Merge branch 'master' of https://github.com/3Dragan/storm into STORM-1069
STORM-1069: add check case for external change of 'now' value.
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/829798eb
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/829798eb
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/829798eb
Branch: refs/heads/master
Commit: 829798eb3f5bbe55f283e786095db395946b0e3e
Parents: ae4b553 cc082aa
Author: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Authored: Tue Sep 29 09:07:34 2015 -0500
Committer: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Committed: Tue Sep 29 09:07:34 2015 -0500
----------------------------------------------------------------------
.../src/jvm/storm/kafka/KafkaSpout.java | 21 ++++++++++++--------
1 file changed, 13 insertions(+), 8 deletions(-)
----------------------------------------------------------------------