Management framework: make "result" argument plural in multi-result response events

No functional change, just a consistency tweak. Since agent and controller send
response events via Broker::publish(), the arguments aren't named and so this
only affects the API definition.
This commit is contained in:
Christian Kreibich 2022-06-22 16:23:42 -07:00
parent 54f2f28047
commit b2f9e29bae
2 changed files with 19 additions and 16 deletions

View file

@ -38,10 +38,13 @@ export {
## ##
## reqid: the request identifier used in the request event. ## reqid: the request identifier used in the request event.
## ##
## result: the result record. ## results: A vector of :zeek:see:`Management::Result` records, each
## capturing the outcome of a single launched node. For failing
## nodes, the result's data field is a
## :zeek:see:`Management::NodeOutputs` record.
## ##
global deploy_response: event(reqid: string, global deploy_response: event(reqid: string,
result: Management::ResultVec); results: Management::ResultVec);
## The controller sends this event to request a list of ## The controller sends this event to request a list of
@ -92,13 +95,13 @@ export {
## ##
## reqid: the request identifier used in the request event. ## reqid: the request identifier used in the request event.
## ##
## result: a :zeek:type:`vector` of :zeek:see:`Management::Result` ## results: a :zeek:type:`vector` of :zeek:see:`Management::Result`
## records. Each record covers one Zeek cluster node managed by this ## records. Each record covers one Zeek cluster node managed by this
## agent. Upon success, each :zeek:see:`Management::Result` record's ## agent. Upon success, each :zeek:see:`Management::Result` record's
## data member contains the dispatches' response in a data type ## data member contains the dispatches' response in a data type
## appropriate for the respective dispatch. ## appropriate for the respective dispatch.
## ##
global node_dispatch_response: event(reqid: string, result: Management::ResultVec); global node_dispatch_response: event(reqid: string, results: Management::ResultVec);
## The controller sends this event to confirm to the agent that it is ## The controller sends this event to confirm to the agent that it is

View file

@ -52,13 +52,13 @@ export {
## ##
## reqid: the request identifier used in the request event. ## reqid: the request identifier used in the request event.
## ##
## result: a :zeek:see:`Management::Result` vector, indicating whether ## results: a :zeek:see:`Management::Result` vector, indicating whether
## the controller accepts the configuration. In case of a success, ## the controller accepts the configuration. In case of a success,
## a single result record indicates so. Otherwise, the sequence is ## a single result record indicates so. Otherwise, the sequence is
## all errors, each indicating a configuration validation error. ## all errors, each indicating a configuration validation error.
## ##
global stage_configuration_response: event(reqid: string, global stage_configuration_response: event(reqid: string,
result: Management::ResultVec); results: Management::ResultVec);
## The client sends this event to retrieve the controller's current ## The client sends this event to retrieve the controller's current
@ -105,13 +105,13 @@ export {
## ##
## reqid: the request identifier used in the request event. ## reqid: the request identifier used in the request event.
## ##
## result: a vector of :zeek:see:`Management::Result` records. ## results: a vector of :zeek:see:`Management::Result` records.
## Each member captures the result of launching one cluster ## Each member captures the result of launching one cluster
## node captured in the configuration, or an agent-wide error ## node captured in the configuration, or an agent-wide error
## when the result does not indicate a particular node. ## when the result does not indicate a particular node.
## ##
global deploy_response: event(reqid: string, global deploy_response: event(reqid: string,
result: Management::ResultVec); results: Management::ResultVec);
## The client sends this event to request a list of ## The client sends this event to request a list of
@ -128,14 +128,14 @@ export {
## ##
## reqid: the request identifier used in the request event. ## reqid: the request identifier used in the request event.
## ##
## result: a :zeek:type:`vector` of :zeek:see:`Management::Result` ## results: a :zeek:type:`vector` of :zeek:see:`Management::Result`
## records. Each record covers one cluster instance. Each record's data ## records. Each record covers one cluster instance. Each record's
## member is a vector of :zeek:see:`Management::NodeStatus` ## data member is a vector of :zeek:see:`Management::NodeStatus`
## records, covering the nodes at that instance. Results may also indicate ## records, covering the nodes at that instance. Results may also
## failure, with error messages indicating what went wrong. ## indicate failure, with error messages indicating what went wrong.
## ##
global get_nodes_response: event(reqid: string, global get_nodes_response: event(reqid: string,
result: Management::ResultVec); results: Management::ResultVec);
## The client sends this event to retrieve the current value of a ## The client sends this event to retrieve the current value of a
@ -161,13 +161,13 @@ export {
## ##
## reqid: the request identifier used in the request event. ## reqid: the request identifier used in the request event.
## ##
## result: a :zeek:type:`vector` of :zeek:see:`Management::Result` ## results: a :zeek:type:`vector` of :zeek:see:`Management::Result`
## records. Each record covers one Zeek cluster node. Each record's ## records. Each record covers one Zeek cluster node. Each record's
## data field contains a string with the JSON rendering (as produced ## data field contains a string with the JSON rendering (as produced
## by :zeek:id:`to_json`, including the error strings it potentially ## by :zeek:id:`to_json`, including the error strings it potentially
## returns). ## returns).
## ##
global get_id_value_response: event(reqid: string, result: Management::ResultVec); global get_id_value_response: event(reqid: string, results: Management::ResultVec);
# Testing events. These don't provide operational value but expose # Testing events. These don't provide operational value but expose