From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60486) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZgTxP-0004z6-9u for qemu-devel@nongnu.org; Mon, 28 Sep 2015 04:38:48 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZgTxO-0004Vw-84 for qemu-devel@nongnu.org; Mon, 28 Sep 2015 04:38:47 -0400 Received: from mx1.redhat.com ([209.132.183.28]:37299) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZgTxO-0004Vs-2d for qemu-devel@nongnu.org; Mon, 28 Sep 2015 04:38:46 -0400 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (Postfix) with ESMTPS id C709DAC856 for ; Mon, 28 Sep 2015 08:38:45 +0000 (UTC) From: Markus Armbruster References: <1443189647-11417-1-git-send-email-armbru@redhat.com> <1443189647-11417-7-git-send-email-armbru@redhat.com> <5605A17F.1090001@redhat.com> Date: Mon, 28 Sep 2015 10:38:43 +0200 In-Reply-To: <5605A17F.1090001@redhat.com> (Eric Blake's message of "Fri, 25 Sep 2015 13:33:19 -0600") Message-ID: <87vbavkkfg.fsf@blackfin.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] [RFC 6/6] docs: Document QMP event rate limiting List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake Cc: amit.shah@redhat.com, marcandre.lureau@redhat.com, lersek@redhat.com, qemu-devel@nongnu.org Eric Blake writes: > On 09/25/2015 08:00 AM, Markus Armbruster wrote: >> Signed-off-by: Markus Armbruster >> --- >> docs/qmp/qmp-events.txt | 12 ++++++++++++ >> docs/qmp/qmp-spec.txt | 5 +++++ >> 2 files changed, 17 insertions(+) > > Obvious rebase implied if your other patch to s,docs/qmp/,docs/, goes > through. > >> >> diff --git a/docs/qmp/qmp-events.txt b/docs/qmp/qmp-events.txt >> index d92cc48..d2f1ce4 100644 >> --- a/docs/qmp/qmp-events.txt >> +++ b/docs/qmp/qmp-events.txt >> @@ -28,6 +28,8 @@ Example: >> "data": { "actual": 944766976 }, >> "timestamp": { "seconds": 1267020223, "microseconds": 435656 } } >> >> +Note: this event is rate-limited. > > Marc-Andre's series moves all the documentation into the .json files; > maybe we could make it easier by just listing rate-limiting in the .json > files for now, rather than having to churn through which file(s) > document things. As long as qmp-events.txt exists, shouldn't we document rate-limiting there? > Do we want to document that VSERPORT_CHANGE rate limiting is per-"id"? I did: @@ -632,6 +640,8 @@ Example: "data": { "id": "channel0", "open": true }, "timestamp": { "seconds": 1401385907, "microseconds": 422329 } } +Note: this event is rate-limited separately for each "id". + WAKEUP ------ >> +++ b/docs/qmp/qmp-spec.txt >> @@ -175,6 +175,11 @@ The format of asynchronous events is: >> For a listing of supported asynchronous events, please, refer to the >> qmp-events.txt file. >> >> +Some events are rate-limited to at most one per second. If more >> +events arrive within one second, all but the last one are dropped, and >> +the last one is delayed. Rate-limiting applies to each kind of event >> +separately. > > Do we also want to document that limits might be further tuned according > to other elements of the event, with VSERPORT_CHANGE "id" as the example? You need to interpret "each kind of event" in a sufficiently fuzzy manner :) Seriously, I'm open to suggestions for better language here.