From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39373) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zj6q4-0006gl-TV for qemu-devel@nongnu.org; Mon, 05 Oct 2015 10:34:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zj6q1-0005TI-ON for qemu-devel@nongnu.org; Mon, 05 Oct 2015 10:34:04 -0400 Received: from relay.parallels.com ([195.214.232.42]:57710) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zj6q1-000378-Gr for qemu-devel@nongnu.org; Mon, 05 Oct 2015 10:34:01 -0400 References: <1443685083-6242-1-git-send-email-den@openvz.org> <1443685083-6242-4-git-send-email-den@openvz.org> <20151001225926.32707.11419@loki> From: Yuri Pudgorodskiy Message-ID: <561286BC.2010206@virtuozzo.com> Date: Mon, 5 Oct 2015 17:18:36 +0300 MIME-Version: 1.0 In-Reply-To: <20151001225926.32707.11419@loki> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 3/5] qga: guest exec functionality List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Michael Roth , "Denis V. Lunev" Cc: qemu-devel@nongnu.org On 10/2/2015 1:59 AM, Michael Roth wrote: >> +# >> +# Since: 2.5 >> +## >> +{ 'command': 'guest-exec', >> + 'data': { 'path': 'str', '*arg': ['str'], '*env': ['str'], >> + '*inp-data': 'str', '*capture-output': 'bool' }, >> + 'returns': 'GuestExec' } > Would it make sense to just add handle (pid) to GuestExecStatus, and > have this return GuestExecStatus just the same as guest-exec-status > does? I'm not sure either way personally, just thought I'd mention it. > I do not think it's a good idea. GuestExecStatus contains mostly the data about the finished exec. Having GuestExec returns same struct may make wrong assumption that it can be synchronous - wait for exec to complete and return all data in a single call. Implementing synchronous GuestExec is not and easy job - either we occupy host-guest channel for all time until task finished, which is bad or we need to implement multiplexed messages for concurrent qga commands.