From: Luiz Capitulino <lcapitulino@redhat.com>
To: Eric Blake <eblake@redhat.com>
Cc: Kevin Wolf <kwolf@redhat.com>,
Paolo Bonzini <pbonzini@redhat.com>,
qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH for-1.5] qmp: add query-drive-mirror-capabilities
Date: Thu, 25 Apr 2013 08:26:35 -0400 [thread overview]
Message-ID: <20130425082635.5333288a@redhat.com> (raw)
In-Reply-To: <517855B3.6060604@redhat.com>
On Wed, 24 Apr 2013 15:59:15 -0600
Eric Blake <eblake@redhat.com> wrote:
> On 04/24/2013 03:29 PM, Luiz Capitulino wrote:
> >> -> { "execute": "query-command-capabilities" }
> >> <- { [ { "type": "drive-mirror",
> >> "data": [ "granularity", "buf-size" ] },
> >> { "type", ... }
> >> ] }
> >>
> >> And whether a '*command' argument should be optional for filtered
> >> output, vs. always unconditionally dumping all information on all
> >> commands with capabilities, vs. mandatory (can only get capabilities for
> >> one command at a time), all goes back to the larger question of whether
> >> query-* commands should allow filtering.
> >
> > Not discussing filtering for now, but your proposal would superseded by
> > full introspection, wouldn't it?
>
> Yeah, the two do seem rather similar, in that they are both providing a
> form of introspection. As I see it, it boils down to WHAT is being
> introspected:
>
> With query-command-capabilities, we are asking about capabilities, which
> can always be represented as pure enum values (either the capability is
> present or it is not). For DriveMirrorCapabilities we happened to map
> two enum values to the name of two optional drive-mirror parameters; but
> where we could introduce other capabilities that are unrelated to an
> optional parameter;
That's a good point, although I wonder if a command could have a new
capability that's not mapped to a new argument. IOW, I'd expect most/all
new capabilities to always be mapped to new arguments.
In any case, I think the way to go is to add full introspection and then
add query-command-capabilities afterwards if it turns out to be necessary.
next prev parent reply other threads:[~2013-04-25 12:26 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-24 20:36 [Qemu-devel] [PATCH for-1.5] qmp: add query-drive-mirror-capabilities Luiz Capitulino
2013-04-24 21:05 ` Eric Blake
2013-04-24 21:29 ` Luiz Capitulino
2013-04-24 21:59 ` Eric Blake
2013-04-24 22:06 ` Eric Blake
2013-04-25 12:26 ` Luiz Capitulino [this message]
2013-04-26 8:13 ` Paolo Bonzini
2013-04-26 13:40 ` Markus Armbruster
2013-04-26 13:54 ` Luiz Capitulino
2013-04-26 15:25 ` Markus Armbruster
2013-04-24 21:24 ` Paolo Bonzini
2013-04-24 21:30 ` Luiz Capitulino
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=20130425082635.5333288a@redhat.com \
--to=lcapitulino@redhat.com \
--cc=eblake@redhat.com \
--cc=kwolf@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).