RoundRobin with Failover

For a target operation group of RoundRobin with Failover type, the Core Engine selects the target operation as per the RoundRobin algorithm. See RoundRobin for details. After the target operation is selected, the Core Engine checks the health of the target operation using the HealthCheck reference functionality of TIBCO API Exchange Gateway. See HealthCheck for Reference.

The Core Engine processes the client request as follows:

  • The Core Engine selects the target operation in a RoundRobin fashion.
  • If the selected target operation within the target operation group is running and available, the facade request is forwarded to this target operation for processing.
  • If the target operation is not running or times out, an alternate target operation is selected from the group of target operations using the RoundRobin algorithm. This process continues until a target operation is found within the target operations group that is available to process the request. The facade request is routed to the available target operation for processing.

The following variables are used to group the status codes to separate them from the MinimumFailoverHTTPStatusCode. The MinimumFailoverHTTPStatusCode is the minimum HTTP status code above which a failover is triggered. The default value is 502.

  • ASG/Routing/HTTPStatusCodeInclusionSet: The codes to be allowed for failover are included in this variable. known It is a comma-separated list of status codes. For example, tibco.clientVar.ASG/Routing/HTTPStatusCodeInclusionSet
  • ASG/Routing/HTTPStatusCodeExclusionSet: The codes to be restricted from failover are included in this variable. It is a comma-separated list of status codes. For example, tibco.clientVar.ASG/Routing/HTTPStatusCodeExclusionSet.

The following scenarios are covered:

MinimumFailoverHTTPStatusCode

Default value: 502

Property is either defined or empty

ASG/Routing/HTTPStatusCodeInclusionSet

Default value: Empty

Property is either defined or empty

ASG/Routing/HTTPStatusCodeExclusionSet

Default value: Empty

Property is either defined or empty

Effect
Value not provided Value provided

For example, HTTPStatusCodeInclusionSet = 408, 421

Value not provided Failover for all status codes greater or equal to MinimumFailoverHTTPStatusCode(502), OR status code present in the inclusion list but NOT present in the exclusion list.

502 - Failover (equal to default MinimumFailoverHTTPStatusCode) 408 - Failover (available in HTTPStatusCodeInclusionSet) 429 - No failover (less then MinimumFailoverHTTPStatusCode)

Value provided

For example, MinimumFailoverHTTPStatusCode = 510

Value not provided Value not provided Failover for all status codes greater or equal to the provided MinimumFailoverHTTPStatusCode(510), OR status code present in inclusion list but NOT present in the exclusion list

510 - Failover (equal to provided MinimumFailoverHTTPStatusCode) 502 - No Failover (less than MinimumFailoverHTTPStatusCode)

Value provided

For example, MinimumFailoverHTTPStatusCode = 510

Value provided

For example, HTTPStatusCodeInclusionSet = 503, 504

Value provided

For example, MinimumFailoverHTTPStatusCode = 596

Failover for all status codes greater or equal to MinimumFailoverHTTPStatusCode(510), OR status code present in inclusion list but NOT present in the exclusion list

510 - Failover (equal to provided MinimumFailoverHTTPStatusCode) 503 - Failover(available in HTTPStatusCodeInclusionSet) 596 - No failover (available in HTTPStatusCodeExclusionSet)

Value not provided Value not provided Value not provided

Failover for all status codes greater or equal to MinimumFailoverHTTPStatusCode(502)

502 - Failover (equal to MinimumFailoverHTTPStatusCode) 408 -No Failover

Value not provided Value provided

For example, HTTPStatusCodeInclusionSet = 408, 421

Value provided

For example, HTTPStatusCodeExclusionSet = 596

Failover for all status codes greater or equal to MinimumFailoverHTTPStatusCode(502), or status code present in inclusion list but not present in the exclusion list

502 - Failover(equal to MinimumFailoverHTTPStatusCode) 408 - Failover(available in HTTPStatusCodeInclusionSet)

596 - No failover(available in

HTTPStatusCodeExclusionSet

)

Value provided

For example, HTTPStatusCodeInclusionSet = 408, 421

Value not provided Value provided

For example, HTTPStatusCodeExclusionSet = 596

Failover for all status codes greater or equal to MinimumFailoverHTTPStatusCode(510), OR status code present in inclusion list but NOT present in the exclusion list

510 - Failover(equal to MinimumFailoverHTTPStatusCode) 502 - Don't failover(less than MinimumFailoverHTTPStatusCode)

596 - Don't failover (available in

HTTPStatusCodeExclusionSet

)

Value not provided Value not provided Value provided

For example, HTTPStatusCodeExclusionSet = 510

Failover for all status codes greater or equal to MinimumFailoverHTTPStatusCode(502), but NOT present in the inclusion list

502 - Failover(equal to provided MinimumFailoverHTTPStatusCode) 510 - No failover (available in HTTPStatusCodeExclusionSet)

Value provided or not provided Value provided

For example, HTTPStatusCodeInclusionSet = 510

Value provided

For example, HTTPStatusCodeExclusionSet = 510

IF Inclusion and exclusion both contain duplicate entries then IllegalArgumentExceptionto is thrown with an additional message Given Http Code can not be part of BOTH Inclusion and Exclusion set and Engine ignores all the values given in HTTPStatusCodeInclusionSet and HTTPStatusCodeExclusionSet. (both values to be considered as EMPTY set)