Flowdock
start_import() public

No documentation

This method has no description. You can help the Ruby community by adding new notes.

Hide source
# File lib/shell/system-command.rb, line 83
    def start_import
      notify "Job(%id) start imp-pipe.", @shell.debug?
      rs = @shell.record_separator unless rs
      _eop = true
      Thread.start {
        begin
          while l = @pipe_in.gets
            @input_queue.push l
          end
          _eop = false
        rescue Errno::EPIPE
          _eop = false
        ensure
          if !ProcessController::USING_AT_EXIT_WHEN_PROCESS_EXIT and _eop
            notify("warn: Process finishing...",
                   "wait for Job[%id] to finish pipe importing.",
                   "You can use Shell#transact or Shell#check_point for more safe execution.")
            redo
          end
          notify "job(%id}) close imp-pipe.", @shell.debug?
          @input_queue.push :EOF
          @pipe_in.close
        end
      }
    end
Register or log in to add new notes.