Uploaded image for project: 'Apache Storm'
  1. Apache Storm
  2. STORM-351

multilang python process fall into endless loop

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 0.9.3
    • Fix Version/s: 0.9.3
    • Component/s: storm-multilang
    • Labels:
      None
    • Environment:
      storm 0.9.3-incubating

      Description

      1. steps to reproduce
      1) write a topology with a python bolt, run the topology on storm; then there will be two process for the bolt: the worker(java process for ShellBolt), python process.
      2)kill -9 the worker(java process for ShellBolt);

      2. expected behavior
      the worker exit and the python process exist

      3. actual, incorrect behavior
      the worker exit, but the python process never exist and fall into endless loop

      4. analyse
      in storm.py,read tuple from stdin with follow function:

      def readMsg():
      msg = ""
      while True:
      line = sys.stdin.readline()[0:-1]
      if line == "end":
      break
      msg = msg + line + "\n"
      return json_decode(msg[0:-1])

      when sys.stdin is closed, EOF is encountered, readline() return None, so readMsg fall into endless loop.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                dashengju DashengJu
                Reporter:
                dashengju DashengJu
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 10m
                  10m