You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Author: Xiao Li (@xli)
Status: Idea (for discussion)
To improve the ability of off-chain service handling network problems and protocol errors, we’d like to introduce a ping command for client to:
detect dead connections to a remote off-chain service.
measure the latency to a remote off-chain service.
detect off-chain protocol errors to a remote off-chain service, for example: when a remote off-chain service rotates their compliance key, and client used old compliance public key to verify the response message, the ping command can be used to debug the error and verify the fix.
Specification
The PingCommand object definition:
Field
Type
Required?
Description
_ObjectType
str
Y
The fixed string PingCommand
An example CommandRequestObject JSON message with PingCommand:
Note we don’t need a random message body in PingCommand for the server to response, because the off-chain API protocol already have a cid field defined in the CommandRequestObject and CommandResponseObject to serve the purpose of distinguish different command instance.
There is no command_error for this command. Server may respond with protocol_error (with CommandResponseObject.status==“failure”) defined in DIP-1 when processing an invalid HTTP headers, JWS message or CommandRequestObject payload.
The text was updated successfully, but these errors were encountered:
Author: Xiao Li (@xli)
Status: Idea (for discussion)
To improve the ability of off-chain service handling network problems and protocol errors, we’d like to introduce a ping command for client to:
Specification
The PingCommand object definition:
An example
CommandRequestObject
JSON message withPingCommand
:And the response of the
PingCommand
:Note we don’t need a random message body in PingCommand for the server to response, because the off-chain API protocol already have a
cid
field defined in theCommandRequestObject
andCommandResponseObject
to serve the purpose of distinguish different command instance.There is no
command_error
for this command. Server may respond withprotocol_error
(with CommandResponseObject.status==“failure”) defined in DIP-1 when processing an invalid HTTP headers, JWS message orCommandRequestObject
payload.The text was updated successfully, but these errors were encountered: