Object Type: LoadBalancerRule

LoadBalancerRule object type provides a required abstraction to implement different algorithms.

Methods

getNextClient

Provides an HTTP client which is chosen according to the algorithm.

getNextClient

function getNextClient(Client?[ ] loadBalanceCallerActionsArray) returns Client | ClientError
Isolated Function

Provides an HTTP client which is chosen according to the algorithm.

Parameters

  • loadBalanceCallerActionsArray Client?[ ]
  • Array of HTTP clients which needs to be load balanced

Return Type

(Client | ClientError)

Chosen Client from the algorithm or an http:ClientError for the failure in the algorithm implementation