swarm: say "no queue coordinates", never "a hive with no queue"
The swarm always has exactly one queue; a hive can only lack its address. Reworded every prose site this PR added that stated or implied the opposite, to name what is actually absent (coordinates, credential, or address) instead of the queue itself. Refs #3805
This commit is contained in:
parent
86652f051a
commit
2989c5ccdb
8 changed files with 31 additions and 26 deletions
|
|
@ -61,7 +61,7 @@ impl QueueEnv {
|
|||
enum Resolution {
|
||||
/// Everything is here; the agent can reach the queue.
|
||||
Configured(Box<QueueConfig>),
|
||||
/// No queue for this agent, and that is a legal state — carries why.
|
||||
/// No queue coordinates for this agent, and that is a legal state — carries why.
|
||||
Absent(&'static str),
|
||||
/// Some of the environment, not all of it. A deployment bug rather than
|
||||
/// an absent integration, so it is reported and then survived.
|
||||
|
|
@ -141,7 +141,7 @@ pub fn init() {
|
|||
Some(*cfg)
|
||||
}
|
||||
Resolution::Absent(why) => {
|
||||
tracing::info!(why, "no swarm queue for this agent");
|
||||
tracing::info!(why, "no swarm queue coordinates for this agent");
|
||||
None
|
||||
}
|
||||
Resolution::Partial => {
|
||||
|
|
@ -219,9 +219,10 @@ mod tests {
|
|||
);
|
||||
}
|
||||
|
||||
/// A hive with no swarm queue at all. Silence here is correct, and it has
|
||||
/// to be distinguishable from the half-set case below — that distinction
|
||||
/// is the only thing that makes the error branch worth logging.
|
||||
/// A hive that has not been given its queue's coordinates at all. Silence
|
||||
/// here is correct, and it has to be distinguishable from the half-set
|
||||
/// case below — that distinction is the only thing that makes the error
|
||||
/// branch worth logging.
|
||||
#[test]
|
||||
fn an_empty_environment_is_no_queue_rather_than_an_error() {
|
||||
let e = env([None, None, None, None]);
|
||||
|
|
|
|||
Loading…
Reference in a new issue