All of lore.kernel.org
 help / color / mirror / Atom feed
From: Igor Mammedov <imammedo@redhat.com>
To: "Daniel P. Berrangé" <berrange@redhat.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>,
	qemu-devel@nongnu.org, armbru@redhat.com
Subject: Re: [PATCH v2 1/3] qmp: Support for querying stats
Date: Tue, 18 Jan 2022 15:47:31 +0100	[thread overview]
Message-ID: <20220118154731.159e4b23@redhat.com> (raw)
In-Reply-To: <Yea3+t4qtk4iB9jr@redhat.com>

On Tue, 18 Jan 2022 12:52:10 +0000
Daniel P. Berrangé <berrange@redhat.com> wrote:

> On Tue, Jan 18, 2022 at 01:26:32PM +0100, Paolo Bonzini wrote:
> > On 1/17/22 16:17, Mark Kanda wrote:  
> > > > 
> > > > I agree except that I think this and StatsResults should be unions,
> > > > even if it means running multiple query-stats commands.  
> > > 
> > > IIUC, making StatsResults a union implies the filter is a required
> > > argument (currently it is optional - omitting it dumps all VM and VCPU
> > > stats). Just to confirm - we want the filter to be required?  
> > 
> > Yeah, I think at least the "kind" (vcpu, vm, perhaps in the future block or
> > net) should be mandatory.  If the caller doesn't know of a "kind", chances
> > are it won't be able to understand what object the stats refer to, for
> > example the vcpu "id" here:
> > 
> > { 'union': 'StatsResults',
> >    'base': { 'target': 'StatsTarget', stats: ['StatsResultsEntry'] },
> >    'discriminator': 'target',
> >    'data': { 'vcpu': ['id': 'int'] }
> > }
> > 
> > (which is another different between Daniel's proposal and mine; his just
> > placed all vcpus into an array with no explicit id, if I understand
> > correctly).  
> 
> An explicit ID isn't strictly required, since the caller can assume
> the results are ordered on CPU ID, so even if they gave a request
> for a sparse subset of CPUs, the results can be interpreted.  None
> the less having a vCPU id included is more friendly, so worth
> having.

and what exactly this CPU ID is,
may QOM path pointing to VCPU instance would be better?

> 
> Regards,
> Daniel



  parent reply	other threads:[~2022-01-18 15:49 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-19 19:51 [PATCH v2 0/3] Support fd-based KVM stats Mark Kanda
2021-11-19 19:51 ` [PATCH v2 1/3] qmp: Support for querying stats Mark Kanda
2021-12-07 18:42   ` Daniel P. Berrangé
2022-01-17 12:05     ` Paolo Bonzini
2022-01-17 15:17       ` Mark Kanda
2022-01-18 12:26         ` Paolo Bonzini
2022-01-18 12:52           ` Daniel P. Berrangé
2022-01-18 13:59             ` Mark Kanda
2022-01-19  8:48               ` Paolo Bonzini
2022-01-18 14:47             ` Igor Mammedov [this message]
2022-01-19  8:43               ` Paolo Bonzini
2022-01-19  9:11                 ` Daniel P. Berrangé
2021-11-19 19:51 ` [PATCH v2 2/3] hmp: " Mark Kanda
2021-11-19 19:51 ` [PATCH v2 3/3] kvm: Support for querying fd-based stats Mark Kanda
2022-01-15 16:22 ` [PATCH v2 0/3] Support fd-based KVM stats Paolo Bonzini
2022-01-16 23:17   ` Mark Kanda

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220118154731.159e4b23@redhat.com \
    --to=imammedo@redhat.com \
    --cc=armbru@redhat.com \
    --cc=berrange@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.