The demo in the Getting Started with GigaSpaces in Kubernetes created a data grid that contained a single Space instance. Real-life environments generally have to store large volumes of data, and therefore need more than a single Space instance (a cluster).
Type the following Helm command to deploy a Space cluster with n Data Pods, with a partition count from 1 to n:
helm install insightedge --name test --set pu.partitions=n
There are several aspects to configuring a data grid for high availability. Each primary Data Pod needs a minimum of one backup Data Pod, and three Management Pods are deployed instead of one so that a quorum of Platform Managers is always available to manage the Spaces. Both the Data Pods and the Management Pods should have the Pod anti-affinity property set to true, so that the primary/backup sets and the managers are deployed on different nodes. This enables successful failover if a node gets disrupted.
The Kubernetes minikube runs on a single node and therefore doesn't provide anti-affinity, so you may want to evaluate InsightEdge high-availability behavior on a Kubernetes cluster that contains multiple nodes.
When the Manager high availability property (
ha) is set to true, Kubernetes deploys three Management Pods. You should enable the Manager high availability property so these Management Pods are deployed on different nodes.
The following Helm command deploys three Management Pods (instead of one) with high availability enabled:
helm install insightedge-manager --name test --set ha=true,antiAffinity.enabled=true
When you set the Space high availability property to true, Kubernetes deploys a backup Data Pod for each primary Data Pod. You must also enable the Space anti-affinity (
antiAffinity) property so that the backup Data Pods are deployed on different nodes than the primary Data Pods.
If you apply Pod anti-affinity on a minikube, not all of the Pods will be deployed, because the environment contains only a single node.
The following Helm command deploys a Space cluster called
test in a high availability topology, with anti-affinity enabled:
helm install insightedge --name test --set pu.ha=true,pu.antiAffinity.enabled=true
If you want to deploy multiple data grids in the same Kubernetes environment, to better utilize resources it is best to deploy one Platform Manager cluster and then configure the Spaces to use this cluster, instead of deploying each data grid with its own Platform Manager.
To enable users to customize the installation, we provide several additional Helm charts that can be used to define specific constellations in more advanced scenarios:
- Manager (
- Processing Unit (
- Apache Zeppelin (
Before using these charts for the first time, you must fetch the charts as described in Getting Started section.
The helm command by default creates a Management Pod and a Data Pod together. When deploying a Platform Manager that will connect to multiple Spaces, you have to disable the part of the command that creates the Data Pod. Type the following Helm command to create a Management Pod called
testmanager without the accompanying Space:
helm install insightedge-manager --name testmanager
After the Management Pod has been deployed and the Platform Manager is available, you can deploy the Space instances and connect them to the Platform Manager. Use the following Helm command to deploy a cluster of Data Pods called
testspace, and to specify that the cluster should connect to the
testmanager Management Pod:
helm install insightedge-pu --name testspace --set manager.name=testmanager