TsgcWebSocketClient › Events › OnLoadBalancerError
Fires when LoadBalancer is enabled and an error occurs while communicating with the Load Balancer Server.
public event TsgcWSLoadBalancerErrorEventHandler OnLoadBalancerError;
// delegate void TsgcWSLoadBalancerErrorEventHandler(TObject Sender, string Error)
—
When LoadBalancer.Enabled is True the client opens a side connection to the Load Balancer Server to query available WebSocket servers and to broadcast messages. OnLoadBalancerError is raised if that side connection fails (Load Balancer host unreachable, authentication rejected, protocol error...). The Error parameter contains a textual description. The event only reports failures with the Load Balancer; errors on the main WebSocket connection are still reported through OnError and OnException.
void OnLoadBalancerError(TObject Sender, string Error)
{
Console.WriteLine("#load balancer error: " + Error);
}