From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33139) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YGrxA-00060U-Mm for qemu-devel@nongnu.org; Thu, 29 Jan 2015 11:28:25 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YGrx7-000667-G2 for qemu-devel@nongnu.org; Thu, 29 Jan 2015 11:28:24 -0500 Received: from mx1.redhat.com ([209.132.183.28]:52771) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YGrx7-00065M-7C for qemu-devel@nongnu.org; Thu, 29 Jan 2015 11:28:21 -0500 Date: Thu, 29 Jan 2015 16:28:15 +0000 From: "Dr. David Alan Gilbert" Message-ID: <20150129162815.GG2391@work-vm> References: <1422543997-22808-1-git-send-email-dgilbert@redhat.com> <1422543997-22808-2-git-send-email-dgilbert@redhat.com> <20150129151527.GE1102@redhat.com> <54CA500E.8030608@redhat.com> <20150129155425.GE2391@work-vm> <54CA594E.5030605@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <54CA594E.5030605@redhat.com> Subject: Re: [Qemu-devel] [RFC 1/1] Execute arbitrary QMP commands from command line List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake Cc: amit.shah@redhat.com, liang.z.li@intel.com, qemu-devel@nongnu.org, quintela@redhat.com * Eric Blake (eblake@redhat.com) wrote: > On 01/29/2015 08:54 AM, Dr. David Alan Gilbert wrote: > >> The idea of a QMP command to trigger incoming migration looks > >> reasonable. We can probably use a qapi union for a nicer syntax, > >> something like: > >> > >> {"execute": "migrate-incoming", "arguments": { > >> "type": "tcp", "port": 44 } } > >> vs. > >> {"execute": "migrate-incoming", "arguments": { > >> "type": "fd", "fd": 0 } } > >> vs. > >> {"execute": "migrate-incoming", "arguments": { > >> "type": "exec", "command": [ "cat", "/path/to/file" ] } } > >> > >> and so forth. > > > > Compared to just taking a URI argument that Dan suggested, that's quite a > > bit of rework to do the reworking of each transport which is pretty > > trivial. > > Yes, but getting the interface right means that adding future extensions > will be easier, with less string parsing hacks. I guess so, but I still have to maintain the -incoming string interface and an HMP equivalent of whatever we come up with here. So what would the .args_type look like in qmp-commands.hx; something like this? .args-type = "type:s,port:-i,host:-s,command:-s" Dave > > -- > Eric Blake eblake redhat com +1-919-301-3266 > Libvirt virtualization library http://libvirt.org > -- Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK