API Gateway 11.1 | Administering API Gateway | Deployment | Deployment Configurations | Cluster Deployment | Enabling Clustering for API Gateway through the User Interface
 
Enabling Clustering for API Gateway through the User Interface
Keep the following points in mind when enabling clustering for API Gateway.
*You must have API Gateway administrator privileges to enable clustering.
*For a cluster configuration, the external Elasticsearch instances should also be clustered using external Elasticsearch clustering properties, by modifying the <Elastic_Dir>/config/elasticsearch.yml file on each instance.
*To enable clustering
1. Expand the menu options icon menu_options, in the title bar, and select Administration.
2. Select General > Clustering.
3. Click the Enabled toggle button to toggle_button state to enable the cluster.
4. Provide the following information:
Field
Description
Cluster name
Specifies the name of the cluster to which API Gateway belongs.
Keep the following in mind when specifying the cluster name:
*The cluster name cannot include any periods ".". API Gateway converts any periods in the name to underscores when you save the cluster configuration.
*The cluster name cannot exceed 32 characters. If it does, API Gateway uses the first 20 characters of the supplied name and then a hash for the remaining characters.
Session time out (in minutes)
Specifies the number of minutes an inactive session is retained in the clustered session store.
The default is 60 minutes.
Set the clustered session timeout value to be longer than the session timeout value, which governs how long a server keeps session information in its memory. (API Gateway displays the session timeout on the Administration > System settings > Configuration page.)
Action on clustering failure
Specifies how API Gateway responds when an error at start up prevents API Gateway from joining the cluster. Select one of the following:
*Start as stand-alone API Gateway. API Gateway starts as a stand-alone, unclustered API Gateway if it encounters any errors that prevent it from joining the cluster at start up.API Gateway continues to receive requests on inbound ports and serve requests. This is the default setting.
*Shut down API Gateway. API Gateway shuts down if it encounters any errors that prevent it from joining the cluster at start up.
*Enter quiesce mode on stand-alone. API Gateway starts as a stand-alone, unclustered API Gateway in quiesce mode if it encounters any errors that prevent it from joining the cluster at start up. When API Gateway is in quiesce mode, only the diagnostic port and quiesce port are enabled.
Discovery port
This field is available and required when you select Ignite as the cluster type.
Specifies the port that is used to discover the members that participate in the cluster. Each cluster member opens this port in order to be discoverable. Each API Gateway server tries to contact other servers through this port.
When you specify the port number, make sure the port number ranges between 1024 to 65535.
Communication port
This field is available and required when you select Ignite as the cluster type.
Specifies the port that is used to communicate between distributed caches. Each server opens this port to be able to receive information. Each server distributes cache entries through this port to other cluster members.
When you specify the port number, make sure the port number ranges between 1024 to 65535.
Port range
This field is available and required when you select Ignite as the cluster type.
Specifies the number of ports to include in the range available to multiple cluster members on the same host. The default value is 0.
The Port range parameter applies to both the Discovery port and the Communication port.
Generally, each cluster member is deployed on its own host. However, for trial or demo purposes you might have multiple cluster members on the same host. In such a situation, each server requires its own discovery and communication port, and must know the other servers' ports. You can use the Port range parameter to configure this scenario. This parameter defines the size of a port range. For example, if you configure the port with port number 10100 and set Port range as 5, the resulting port range that is available is 10100 to 10105. When a server starts, it picks an unused port from the range 10100 to 10105, and uses the port to communicate with the other servers. Another server on start up can use an unused port from the same port range to communicate with the other servers. This allows all servers to use the same cluster configuration.
Provisioning target
This field is available and required when you select Ignite as the cluster type.
Specifies whether you want to use host name or Kubernetes service as the provisioning target.
Select one of the following as provisioning targets and provide the required details:
*Hostnames. Provide the name of the participating host in the cluster and click add.
You can add multiple host names by clicking add.
*Kubernetes. Provide the following details:
*Servicename. Provide the name of the service that exposes the API Gateway deployment.
*Namespace. Provide the name of the Kubernetes namespace within which the API Gateway is deployed.
5. Click Save.
6. Restart API Gateway.
7. Log on as administrator and navigate to Administration > General > Clustering and verify that all nodes in the cluster are displayed under Cluster hosts.
Note:
You must enable clustering on all nodes in a cluster for the nodes to be included in the cluster.