diff options
author | Markus Armbruster <armbru@redhat.com> | 2018-07-03 10:53:33 +0200 |
---|---|---|
committer | Markus Armbruster <armbru@redhat.com> | 2018-07-03 23:18:56 +0200 |
commit | 80cd93bd966bbb0907caa7f1d5676342f27f8f9e (patch) | |
tree | 34621689d680819983c4c8e7ebfd5a3c222db452 /docs/interop/qmp-spec.txt | |
parent | 2970b4461f5f0dd0798774618713aadd457e8d48 (diff) |
qmp: Make "id" optional again even in "oob" monitors
Commit cf869d53172 "qmp: support out-of-band (oob) execution" made
"id" mandatory for all commands when the client accepted capability
"oob". This is rather onerous when you play with QMP by hand, and
unnecessarily so: only out-of-band commands need an ID for reliable
matching of response to command.
Revert that part of commit cf869d53172 for now, but have documentation
advise on the need to use "id" with out-of-band commands.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20180703085358.13941-8-armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'docs/interop/qmp-spec.txt')
-rw-r--r-- | docs/interop/qmp-spec.txt | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/docs/interop/qmp-spec.txt b/docs/interop/qmp-spec.txt index 6b72b69cb1..a1d6f9ee06 100644 --- a/docs/interop/qmp-spec.txt +++ b/docs/interop/qmp-spec.txt @@ -103,16 +103,13 @@ The format for command execution is: required. Each command documents what contents will be considered valid when handling the json-argument - The "id" member is a transaction identification associated with the - command execution. It is required for all commands if the OOB - - capability was enabled at startup, and optional otherwise. The same - "id" field will be part of the response if provided. The "id" - member can be any json-value. A json-number incremented for each - successive command works fine. + command execution, it is optional and will be part of the response + if provided. The "id" member can be any json-value. A json-number + incremented for each successive command works fine. - The optional "control" member further specifies how the command is to be executed. Currently, its only member is optional "run-oob". See section "2.3.1 Out-of-band execution" for details. - 2.3.1 Out-of-band execution --------------------------- @@ -128,6 +125,10 @@ possibly overtaking prior in-band commands. The client may therefore receive such a command's response before responses from prior in-band commands. +To be able to match responses back to their commands, the client needs +to pass "id" with out-of-band commands. Passing it with all commands +is recommended for clients that accept capability "oob". + To execute a command out-of-band, the client puts "run-oob": true into execute's member "control". |