Struct common_messages_sv2::SetupConnectionError[][src]

pub struct SetupConnectionError<'decoder> {
    pub flags: u32,
    pub error_code: Str0255<'decoder>,
}
Expand description

SetupConnection.Error (Server -> Client)

When protocol version negotiation fails (or there is another reason why the upstream node cannot setup the connection) the server sends this message with a particular error code prior to closing the connection. In order to allow a client to determine the set of available features for a given server (e.g. for proxies which dynamically switch between different pools and need to be aware of supported options), clients SHOULD send a SetupConnection message with all flags set and examine the (potentially) resulting SetupConnectionError message’s flags field. The Server MUST provide the full set of flags which it does not support in each SetupConnectionError message and MUST consistently support the same set of flags across all servers on the same hostname and port number. If flags is 0, the error is a result of some condition aside from unsupported flags.

Fields

flags: u32

Flags indicating features causing an error.

error_code: Str0255<'decoder>

Human-readable error code(s). See Error Codes section, link.

Possible error codes:

  • ‘unsupported-feature-flags’
  • ‘unsupported-protocol’
  • ‘protocol-version-mismatch’

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Performs the conversion.

Performs the conversion.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.