Skip to main content

Module srv_calls

Module srv_calls 

Source
Expand description

One way for a tool to ask this agent’s srv: the address, the instance key, the request and the words of a failure, written once.

An agent reads a failure’s words and acts on them, so they are the ones each call has always used: request failed: .. when srv was not reached, <name> failed: HTTP <status> — <what srv said> when srv refused, with srv’s body whole, and response parse failed: .. when the answer is not JSON. srv_calls_tests.rs pins them call by call.

The calls that word a failure the longer way (srv_http::describe_http_error) still go through srv_get_json and srv_post_json; the tools that write their request by hand move here family by family.

Structs§

Named 🔒
The name a call’s failure carries, and the mark between the status and what srv said: a dash, except in the messages that have always had a hyphen.

Functions§

accepted 🔒
The response when srv was reached and said yes; otherwise the failure in the call’s words.
read_json 🔒