Customizing a Space

This topic describes how to customize a Space in a Kubernetes environment, by specifying multiple partitions, and by providing a backup partition (high availability option).

The topics in this section assume basic knowledge of the GigaSpaces platform. If you aren't familiar with GigaSpaces, review the contents of the general Getting Started section before performing the tasks described here.

Prerequisites

 

Deploy Multiple Partitions

Performance of the Kubernetes environment can be improved by allocating multiple partitions for a Space.

The steps to allocate multiple partitions for a Space are shown below. This example allocates two partitions for the demo Space.

  1. Install xap charts.

    helm install xap ./xap/ --version=16.1.1 --set manager.resources.limits.memory=1000Mi
  2. Wait for all pods to be ready.

  3. Install the demo Space with two partitions.

    helm install demo ./xap-pu/ --set manager.name=xap,partitions=2
  4. Enter the command kubectl get pods to see the result:

  5. NAME                            READY   STATUS    RESTARTS   AGE
    demo-xap-pu-0                   1/1     Running   0          44s
    demo-xap-pu-1                   1/1     Running   0          23s
    xap-grafana-67d9b898b5-d5jn4    1/1     Running   0          2m27s
    xap-influxdb-0                  1/1     Running   0          2m27s
    xap-operator-55c7997cd5-rt6bt   1/1     Running   0          2m27s
    xap-xap-manager-0               1/1     Running   0          2m26s
  6. You can also see the result in Ops Manager:

Deploy with High Availability

High availabilty deploys a backup partition that is in sync with the data in the primary partition. This reduces downtime and prevents data loss if the primary node holding data becomes unavailable. This example adds high availability to a Space called demo.

  1. Undeploy the Space

    helm delete demo
  2. Install helm charts

    helm install xap ./xap/ --version=16.1.1 --set manager.resources.limits.memory=1000Mi
  3. Wait for all pods to be ready.

  4. Install the Space with high availability turned on.

    helm install demo ./xap-pu/ --set manager.name=xap,partitions=1,ha=true
  5. Enter the command kubectl get pods to see the result:

  6. NAME                            READY   STATUS    RESTARTS   AGE
    demo-xap-pu-0                   1/1     Running   0          44s
    demo-xap-pu-1                   1/1     Running   0          23s
    xap-grafana-67d9b898b5-d5jn4    1/1     Running   0          2m27s
    xap-influxdb-0                  1/1     Running   0          2m27s
    xap-operator-55c7997cd5-rt6bt   1/1     Running   0          2m27s
    xap-xap-manager-0               1/1     Running   0          2m26s
  7. In Ops Manager, click on the demo service to see the primary and backup instances.