shell.py 文件源码

python
阅读 71 收藏 0 点赞 0 评论 0

项目:docker-zenoss4 作者: krull 项目源码 文件源码
def start(self, command_line):
        log.debug("LongRunningCommand run_command: {0}".format(command_line))
        elem = yield self._sender.send_request('create')
        self._shell_id = _find_shell_id(elem)
        command_line_elem = _build_command_line_elem(command_line)
        log.debug('LongRunningCommand run_command: sending command request '
                  '(shell_id={0}, command_line_elem={1})'.format(
                    self._shell_id, command_line_elem))
        try:
            command_elem = yield self._sender.send_request(
                'command', shell_id=self._shell_id,
                command_line_elem=command_line_elem,
                timeout=self._sender._sender._conn_info.timeout)
        except TimeoutError:
            yield self._sender.close_connections()
            raise
        self._command_id = _find_command_id(command_elem)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号