Github user harshach commented on a diff in the pull request:
https://github.com/apache/incubator-storm/pull/177#discussion_r17091417
--- Diff: examples/storm-starter/multilang/resources/asyncSplitsentence.js
---
@@ -0,0 +1,32 @@
+/**
+ * Example for async bolt. Receives sentence and breaks it into words.
+ *
+ */
+
+
+var storm = require('./storm');
+var BasicBolt = storm.BasicBolt;
+
+function SplitSentenceBolt() {
+ BasicBolt.call(this);
+};
+
+SplitSentenceBolt.prototype = Object.create(BasicBolt.prototype);
+SplitSentenceBolt.prototype.constructor = SplitSentenceBolt;
+
+SplitSentenceBolt.prototype.process = function(tup, done) {
+ var self = this;
+
+ // Here setTimeout is not really needed, we use it to demonstrate
asynchronous code in the process method:
+ setTimeout(function() {
+ var words = tup.values[0].split(" ");
+ words.forEach(function(word) {
+ self.emit({tuple: [word], anchorTupleId: tup.id},
function(taskIds) {
--- End diff --
Looks like you are anchoring the tuple here but there is no ack in
WordCountTopologyNode.WordCount Bolt. This might be the one causing the fail
count go up and also completeLatency. I removed the anchorTupleId and in
storm.js anchors as part of the message. There is no failed tuples and lower
completeLatency of 41.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---