From patchwork Wed Mar 4 10:29:36 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Dr. David Alan Gilbert" X-Patchwork-Id: 446178 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 2C0E914012F for ; Wed, 4 Mar 2015 21:30:23 +1100 (AEDT) Received: from localhost ([::1]:43028 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YT6ZJ-000698-BB for incoming@patchwork.ozlabs.org; Wed, 04 Mar 2015 05:30:21 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51977) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YT6Yo-000653-Qf for qemu-devel@nongnu.org; Wed, 04 Mar 2015 05:29:51 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YT6Yi-0006l5-Lx for qemu-devel@nongnu.org; Wed, 04 Mar 2015 05:29:50 -0500 Received: from mx1.redhat.com ([209.132.183.28]:34728) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YT6Yi-0006kz-EC; Wed, 04 Mar 2015 05:29:44 -0500 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t24AThcn026914 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Wed, 4 Mar 2015 05:29:43 -0500 Received: from dgilbert-t530.redhat.com (ovpn-116-91.ams2.redhat.com [10.36.116.91]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t24ATdab025198; Wed, 4 Mar 2015 05:29:42 -0500 From: "Dr. David Alan Gilbert (git)" To: qemu-devel@nongnu.org Date: Wed, 4 Mar 2015 10:29:36 +0000 Message-Id: <1425464979-20578-2-git-send-email-dgilbert@redhat.com> In-Reply-To: <1425464979-20578-1-git-send-email-dgilbert@redhat.com> References: <1425464979-20578-1-git-send-email-dgilbert@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 Cc: amit.shah@redhat.com, armbru@redhat.com, qemu-block@nongnu.org, quintela@redhat.com Subject: [Qemu-devel] [RFC v2 1/4] RollingStats qapi type X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: "Dr. David Alan Gilbert" This adds a QAPI type that holds the results of statistics collected by RStats. Signed-off-by: Dr. David Alan Gilbert --- qapi-schema.json | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/qapi-schema.json b/qapi-schema.json index e16f8eb..9f5cdce 100644 --- a/qapi-schema.json +++ b/qapi-schema.json @@ -353,6 +353,36 @@ { 'command': 'query-events', 'returns': ['EventInfo'] } ## +# @RollingStatsValue: +# +# A value/tag tuple used in 'RollingStats' +# +# @value: An arbitrary measurement value +# +# @tag: An arbitrary integer tag value +# +## +{ 'type': 'RollingStatsValue', 'data': {'value': 'number', 'tag': 'uint64'} } + +## +# @RollingStats: +# +# A set of statistics that are measured repeatedly. +# +# @count: The number of measurements that have contributed to the statistics +# @min: The minimum value over the measurement period +# @max: The maximum value over the measurement period +# @mean: A rolling mean +# @weighted-mean: A weighted mean (the weight set at startup) +# @values: A list of the most recent values stored. Note that the +# stastics above are calculated over the whole set. +## +{ 'type': 'RollingStats', 'data': {'count': 'int', + 'min': 'number', 'max': 'number', + 'mean': 'number', 'weighted-mean': 'number', + 'values': ['RollingStatsValue'] } } + +## # @MigrationStats # # Detailed migration status.