From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MKCwd-0007yo-Ab for qemu-devel@nongnu.org; Fri, 26 Jun 2009 11:02:27 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MKCwY-0007wo-NI for qemu-devel@nongnu.org; Fri, 26 Jun 2009 11:02:27 -0400 Received: from [199.232.76.173] (port=54755 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MKCwY-0007wj-1d for qemu-devel@nongnu.org; Fri, 26 Jun 2009 11:02:22 -0400 Received: from rv-out-0708.google.com ([209.85.198.247]:36152) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MKCwX-0007Ro-F2 for qemu-devel@nongnu.org; Fri, 26 Jun 2009 11:02:21 -0400 Received: by rv-out-0708.google.com with SMTP id b17so437295rvf.22 for ; Fri, 26 Jun 2009 08:02:18 -0700 (PDT) Message-ID: <4A44E2F3.8050804@codemonkey.ws> Date: Fri, 26 Jun 2009 10:02:11 -0500 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH 01/11] QMP: Introduce specification file References: <4A412339.5000109@redhat.com> <4A412659.1080803@us.ibm.com> <20090623220204.GA5612@snarc.org> <4A415C30.7030301@us.ibm.com> <20090624010108.GA6537@snarc.org> <4A42200C.6060600@codemonkey.ws> <5b31733c0906240857g546316e0pd92fee9afe6115fa@mail.gmail.com> <4A4252DD.70300@redhat.com> <20090624190539.GR14121@shareable.org> <5b31733c0906241224j50baa7e6lc80b8c79c5d6baa7@mail.gmail.com> <20090624211358.GA14121@shareable.org> <4A43768A.2090604@eu.citrix.com> <4A438FDD.5060206@redhat.com> <4A43935D.6000506@codemonkey.ws> <4A4395B8.4010401@redhat.com> <4A43BD5D.80307@codemonkey.ws> <4A43C264.6060803@redhat.com> <4A43D600.8060605@codemonkey.ws> <4A449113.8070907@redhat.com> <4A44CB74.1070808@codemonkey.ws> In-Reply-To: <4A44CB74.1070808@codemonkey.ws> Content-Type: multipart/mixed; boundary="------------050606030402020101060503" List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Avi Kivity Cc: "ehabkost@redhat.com" , Stefano Stabellini , "jan.kiszka@siemens.com" , "dlaor@redhat.com" , "qemu-devel@nongnu.org" , Luiz Capitulino , Filip Navara , Vincent Hanquez This is a multi-part message in MIME format. --------------050606030402020101060503 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Anthony Liguori wrote: > Avi Kivity wrote: >> Merging is a meaningless milestone since the protocol will not be >> enabled. Since we'll miss 0.11 in reality we have 7-8 months before >> the protocol can be used in production. IMO you're optimizing for >> the short term, disregarding long-term maintenance, and disregarding >> ease of implementation for users of the qemu monitor. > Here's an updated grammar. One benefit of using our own grammar over just JSON-RPC that is line based is that lines form discrete PDUs. If you wanted to implement a JSON-RPC parser, you would have to be able to either invent your own PDU transmission mechanism or rely on the JSON parser to determine message boundaries. Since the later is likely to be a recursive decent parser, this is difficult to work into an asynchronous client library. The same is true for XML-RPC. With XML-RPC, you rely on HTTP's Content-Length header to determine boundaries. By having a well defined PDU, you can hand lines to the parser and be sure that the recursion will complete without requiring more data. Regards, Anthony Liguori --------------050606030402020101060503 Content-Type: text/plain; name="qmp-v2.g" Content-Transfer-Encoding: base64 Content-Disposition: inline; filename="qmp-v2.g" IyBRTVAgMS4wCgojIHYxIC0+IHYyCiMgIG8gYWxsb3cgaW50ZWdlciBpbiBzeW1ib2wgbmFt ZXMgKEMtc3R5bGUpCiMgIG8gYWxsb3cgbmVnYXRpdmUgaW50ZWdlci9mbG9hdHMKIyAgbyBu byBuZXdsaW5lcyBpbiBzdHJpbmdzCiMgIG8gb25lIHZhbHVlIHBlciByZXNwb25zZV9kYXRh IGxpbmUKCl9fc2tpcF9fOiBbIFx0XSsKCnN5bWJvbDogW0EtWmEtel9cLV1bQS1aYS16X1wt MC05XSoKCmR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