Navigation
API > API/Plugins > API/Plugins/QuicMessagingTransport
References
| Module | QuicMessagingTransport |
| Header | /Engine/Plugins/Experimental/QuicMessaging/Source/QuicMessagingTransport/Public/QuicEndpointManager.h |
| Include | #include "QuicEndpointManager.h" |
Syntax
class FQuicEndpointManager
Remarks
QUIC endpoint manager
Authentication:
- If AuthenticationMode is Enabled, QuicServerHandler will discard any message with MessageType other than "Authentication" until the node associated with the handler is marked as authenticated
- Messages with type "Authentication" or "AuthenticationResponse" can be sent via the extension methods found in IQuicNetworkMessagingExtension.h
- The MaxAuthenticationMessageSize limit can be set to avoid reading potentially large malicious authentication messages
Client/Server:
- The EndpointManager will start in client mode by default and is converted to a server endpoint when SetServerMode is called with additional parameters needed to run a server
- QuicServerHandlers will continuously ping the connected client to keep the connection alive
Constructors
| Type | Name | Description | |
|---|---|---|---|
FQuicEndpointManager
(
TSharedRef< FQuicEndpointConfig > InEndpointConfig |
Initialize endpoint manager with default mode as client. |
Destructors
| Type | Name | Description | |
|---|---|---|---|
| Default destructor. |
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | AddClient
(
const FIPv4Endpoint& ClientEndpoint |
Add remote endpoint client. | |
| void | Regularly called to check if any of the endpoints have reached the discovery timeout. | ||
| void | CheckLoseNode
(
const FIPv4Endpoint LostEndpoint |
Checks if the lost endpoint node is still registered and removes it. | |
| FMessageHeader | DeserializeHeader
(
const FQuicPayloadPtr HeaderData |
Forward for the deserialize header delegate. | |
| void | DisconnectEndpoint
(
const FIPv4Endpoint& Endpoint |
Disconnect an endpoint. | |
| void | DisconnectNode
(
const FGuid& NodeId |
Disconnect a node. | |
| void | EndpointConnected
(
const FIPv4Endpoint& ConnectedEndpoint |
Adds a DiscoveryTimeout entry if discovery timeouts are enabled. | |
| void | EndpointDisconnected
(
const FIPv4Endpoint DisconnectedEndpoint, |
Removes a disconnected endpoint. | |
| void | EndpointNodeDiscovered
(
const FGuid NodeId, |
Register discovered endpoint node. | |
| void | EndpointNodeLost
(
const FGuid NodeId, |
De-register lost endpoint node. | |
| void | EndpointStatisticsUpdated
(
const FMessageTransportStatistics TransportStats |
Updates a KnownNode with new endpoint transport statistics. | |
| void | EnqueueOutboundMessages
(
FQuicPayloadPtr Data, |
Enqueues outbound messages on all recipient endpoints. | |
| TArray< FIPv4Endpoint > | Get a list of the known endpoints. | ||
| TOptional< FGuid > | GetKnownNodeId
(
const FIPv4Endpoint& Endpoint |
Get the NodeId of a known endpoint. | |
| TArray< FGuid > | Get a list of known NodeIds. | ||
| FMessageTransportStatistics | Get the network/transport statistics for a node. | ||
| void | Set endpoint manager to operate in server mode and initialize server. | ||
| bool | IsEndpointAuthenticated
(
const FGuid& NodeId |
Check if a QuicServerHandler endpoint is authenticated.This is only used for QuicServers | |
| bool | IsEndpointKnown
(
const FIPv4Endpoint Endpoint |
Check if an endpoint is associated with a known node. | |
| bool | IsMessageValid
(
const FInboundMessage InboundMessage |
Checks if a message is valid. | |
| FOnClientConnectionChanged & | |||
| FOnDeserializeHeader & | |||
| FOnEndpointNodeDiscovered & | |||
| FOnEndpointNodeLost & | |||
| FOnMessageDelivered & | |||
| FOnMessageValidated & | |||
| FOnSerializeHeader & | |||
| void | ReconnectClient
(
const FIPv4Endpoint ClientEndpoint |
Reconnect remote endpoint client. | |
| void | RemoveClient
(
const FIPv4Endpoint& ClientEndpoint |
Remove remote endpoint client. | |
| void | SendEndpointHello
(
const FInboundMessage& InboundMessage |
Instructs the appropriate endpoint or handler to send a hello message. | |
| FQuicPayloadPtr | SerializeHeader
(
FMessageHeader& MessageHeader |
Forward for the serialize header delegate. | |
| void | SetEndpointAuthenticated
(
const FGuid& NodeId |
Set QuicServerHandler endpoint as authenticated.This is only used for QuicServers | |
| void | Shutdown () |
Shutdown endpoint manager and kill client/server threads. | |
| void | ValidateInboundMessage
(
const FInboundMessage InboundMessage |
Validates InboundMessage and passes it to MessageProcessor. |
Typedefs
| Name | Description |
|---|---|
| FOnClientConnectionChanged | Delegate for when a client connection changes. |
| FOnDeserializeHeader | Delegate for when a header needs to be deserialized. |
| FOnEndpointNodeDiscovered | Delegate for when a node was discovered. |
| FOnEndpointNodeLost | Delegate for when a node was lost. |
| FOnMessageDelivered | Delegate for when a message has been delivered. |
| FOnMessageValidated | Delegate for when a message has been received and validated. |
| FOnSerializeHeader | Delegate for when a header needs to be serialized. |