Configuring high availability
Before you begin
- Ensure that there are a minimum three nodes available with Developer Portal installation and Ignite in them.
- Ensure that the required Load balancer is downloaded.
- Open appropriate ports on each machine so that they can access all components on the other machines. Else, the cluster is not formed.
- Ensure that the OpenSearch and Developer Portal services in all nodes are stopped.
About this task
Configuring OpenSearch
About this task
Developer Portal installation includes the deploying and configuring of OpenSearch that is used to store data. For clustering the OpenSearch instances, you must perform OpenSearch clustering. For more information, see https://opensearch.org/docs/latest/tuning-your-cluster/.
You must perform the following steps in all nodes of a cluster.
To configure OpenSearch
Procedure
Configuring Ignite
About this task
Developer Portal uses the embedded Ignite-core library to setup a cluster, without having to start any external runtime.
In Ignite terminology:
- a single Developer Portal with embedded ignite is an Ignite server node,
- together they form an Ignite cluster,
- and it is a stateless cluster as Developer Portal does not require persistence for its distributed caches.
Ignite cluster discovery
Each Ignite server node has to open a discovery port. Through this port, the nodes discover each other and form the cluster, and they detect the nodes that are added or removed from the cluster.
Each node in the cluster must be configured with a list of initial host names. These nodes will contact each other via the discovery port and form a cluster. Later more nodes can be added to the cluster, and even if their host names are not part of the initial host name list they can join the cluster by contacting one of the initial hosts, and then their host names will be communicated around the cluster.
Pre-requisites
- 47500 - 47509. These ports enable the discovery of Ignite nodes.
- 47100 - 47200. These ports
enable communication between Ignite nodes. Ensure that these ports are accessible across other
nodes.
If you have blocked the access of the port 47100 by any another application in the system, you need to open up the complete series. You can just open up the 47100 port. For more info refer https://ignite.apache.org/docs/latest/clustering/network-configuration.
- It is recommended that you do not open the following
local ports when you system is behind firewall:
- 10800. Enables communication between the thin client and the Ignite cluster.
- 11211. Enables communication between the JDBC client and the Ignite database.
- 47400. Enables node discovery via the UDP port.
Perform the following steps in all nodes of a cluster.
To configure Ignite
Procedure
Configuring Developer Portal
About this task
You must specify the load balancer URL in the Developer Portal instances of all nodes of the cluster.
Procedure
- Sign in to Developer Portal.
- Expand the menu options and select Administration.
- Click General from the left pane.
-
In the Load balancer URL field, provide the URL of the external Load
balancer.
For example, http://<ext_lb_hostname>/portal.
-
Click Save.
The configuration is saved.
Configuring Load Balancer
About this task
Load balancer distributes the incoming requests to the nodes of a cluster with the aim of making their overall processing more efficient. Load balancer optimizes the response time and avoid unevenly overloading some nodes while other nodes are idle.
You can download and use a load balancer of your choice. You must also configure sticky session in the Load balancer for UI upstreaming.
#******* @subdomain@Nginx Config ********
events {
worker_connections 1024;
}
http {
upstream @subdomain@_ui_upstream {
ip_hash;
server @node1@:18101;
server @node2@:18101;
server @node3@:18101;
}
server {
listen 80;
listen [::]:80;
server_name @subdomain@;
access_log /var/log/nginx/access.log;
# DESIGN time should work only in https.
location /portal {
proxy_pass http://@subdomain@_ui_upstream/portal/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
real_ip_header X-Real-IP;
proxy_http_version 1.1;
proxy_set_header Connection "";
}
location /portal/ {
proxy_pass http://@subdomain@_ui_upstream/portal/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
real_ip_header X-Real-IP;
proxy_http_version 1.1;
proxy_set_header Connection "";
}
}
}
The nodes in the cluster are synchronized.
Post-configuration
About this task
Perform the following steps after you have completed the high availability configuration: