Github user HeartSaVioR commented on a diff in the pull request: https://github.com/apache/storm/pull/897#discussion_r45701129 --- Diff: storm-core/src/jvm/backtype/storm/task/ShellBolt.java --- @@ -376,15 +373,18 @@ public void run() { sendHeartbeatFlag.compareAndSet(true, false); } - Object write = _pendingWrites.poll(1, SECONDS); - if (write instanceof BoltMsg) { - _process.writeBoltMsg((BoltMsg) write); - } else if (write instanceof List<?>) { - _process.writeTaskIds((List<Integer>)write); - } else if (write != null) { - throw new RuntimeException("Unknown class type to write: " + write.getClass().getName()); + List<Integer> taskIds = _pendingTaskIds.peek(); --- End diff -- Implemented ShellBoltMessageQueue which accomplishes two things at once, * polling with priority that task ids > bolt message * when poll() is called, waiting up to the specified wait time if necessary for an any kind (task ids / bolt message) of element to become available ** same as current ShellBolt implementation
--- 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 infrastruct...@apache.org or file a JIRA ticket with INFRA. ---