All docs This doc

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: https://wso2.org/jira/browse/DOCUMENTATION-8040

...

WSO2 API Manager provides configuring load balancing endpoints through the API Publisher. 

To configure load balanced endpoints go to the edit view of the API and navigate to the implementImplement tab and click select the Load Balanced under endpoint type check box.


Following are the other configurations that you need to do in order to specify a load balancing endpoint.

...

WSO2 API Manager provides configuring failover group endpoints through the API Publisher. 

To configure failover endpoints go to the edit view of the API and navigate to the implementImplement tab and click Failover under endpoint type.

...

At leaset one failover endpoint need to be added for production and sandbox (if you have specified)   Endpointsendpoints

You can specify more than one endpoint by clicking on "+" sign and can delete the endpoints by clicking on "-" sign.

...

WSO2 API Manager provides controlling the production and sandbox endpoints with the Advanced Endpoint Configuration.

...

Following are the configurations that we can do with the Advanced Endpoint Configurations. You can do advanced configurations for both Production production and Sandbox sandbox endpoints.

Endpoint ConfigurationDescription
Endpoint Suspend State

If you want to configure the suspension of an Endpoint endpoint specifying error codes, maximum suspension time, suspension factors etc., you can use Endpoint Suspension State in the endpoint suspension state in the Advanced Endpoint Configuration.

Error Codes: Error codes in the drop down list which need to make the endpoint suspension. If the selected error codes are received from the endpoint, the endpoint will be suspended. Specify the transport error codes where the Endpoint Suspension should be triggered. You can select single or error codes here.

Initial duration: The time duration for which the endpoint will be suspended, when one or more suspend error codes are received from it for the first time.

Note

When creating (or updating) Failover endpoints through the Publisher UI (in the Implement tab), you need to go into this configuration box of each endpoint and specify a set of Error Codes error codes for the endpoint to fail over on and take off the Initial Duration initial duration by setting its value to -1. 

Max duration: The maximum time duration for which the endpoint is suspended when suspend error codes are received from it.

Factor: The duration to suspend can vary from the first time suspension to the subsequent time. The factor value decides the suspense duration variance between subsequent suspensions.

Endpoint Timeout state

Configurations of retry, error codes and delays in terms of Endpoint endpoint timeout can be configured with Endpoint Timeout State in the endpoint timeout state in the Advanced Endpoint Configuration.

Error Codes: A list of error codes. If these error codes are received from the endpoint, the request will be subjected to a timeout.

Retries Before Suspension: The number of re-tries in case of a timeout, caused by the above listed error codes.

Retry Delay: The delay between retries in milliseconds.

Connection Timeout

Duration and the Response Actions after a Connection Timeout connection timeout can be configured here in the Advanced Endpoint Configuration.

Action: Response Action to be performed after connection timeout. You can select from Never Timeout, Discard Message, Execute Fault Sequence. The default value is Execute Fault Sequence.

Duration: The time duration of Connection Timeout connection timeout in milliseconds.

Note

if you want to change the Endpoint Connection Timeout endpoint connection timeout duration globally affecting all APIs, do the following.

  1. Open the <APIM_HOME>/repository/conf/synapse.properties file. Change the value of the timeout as given below.

    Code Block
    synapse.global_timeout_interval=30000
  2. Open the <ESB_HOME>/repository/conf/passthru-http.properties file and change the socket timeout value.

    Code Block
    http.socket.timeout=30000

Note that the global the socket timeout value should  should be greater than both the connection timeout value synapse global timeout and any endpoint timeouts given for your API.

For more information about endpoints and how to add, edit or delete them, see the WSO2 ESB documentation.