blob: 6c8fd75ac2e75b62307c85087026db6d3ae2554f [file] [log] [blame]
czichy99006e02022-05-05 11:29:24 +03001.. ============LICENSE_START=======================================================
2..
3.. ================================================================================
4.. Copyright (C) 2020 Hcl Technologies Limited.
5.. ================================================================================
6.. Licensed under the Apache License, Version 2.0 (the "License");
7.. you may not use this file except in compliance with the License.
8.. You may obtain a copy of the License at
9..
10.. http://www.apache.org/licenses/LICENSE-2.0
11..
12.. Unless required by applicable law or agreed to in writing, software
13.. distributed under the License is distributed on an "AS IS" BASIS,
14.. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15.. See the License for the specific language governing permissions and
16.. limitations under the License.
17.. ============LICENSE_END=========================================================
Alok Bhatt1b131152020-10-21 14:37:35 +000018
19Important
czichy99006e02022-05-05 11:29:24 +030020^^^^^^^^^
Alok Bhatt1b131152020-10-21 14:37:35 +000021The redis-cluster currently is NOT part of RIC platform & hence is completely optional.
22This piece of document has been created as part of delivery item for below jira ticket
23https://jira.o-ran-sc.org/browse/RIC-109
24This ticket is about assessing the feasibility of redis-cluster (with data sharding)
25supporting desired pod anti-affinity for high availability as per the ticket.
26
27Overview
czichy99006e02022-05-05 11:29:24 +030028^^^^^^^^
Alok Bhatt1b131152020-10-21 14:37:35 +000029This document describes the environment/conditions used to test the feasibility of Redis
30cluster set-up as detailed in the above ticket. Redis Cluster is a distributed implementation
31of Redis with high performance goals. More details at https://redis.io/topics/cluster-spec
32
33Environment Set-Up
czichy99006e02022-05-05 11:29:24 +030034^^^^^^^^^^^^^^^^^^
Alok Bhatt1b131152020-10-21 14:37:35 +000035The set up was tested with kubernetes v1.19 cluster with
36 #. Pod topology spread constraint enabled
37 Reference: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints
38 #. CEPH as the Cluster Storage Solution.
Alok Bhatt1b131152020-10-21 14:37:35 +000039 #. Three worker nodes in the kubernet cluster
40
41Execution
czichy99006e02022-05-05 11:29:24 +030042^^^^^^^^^
Alok Bhatt1b131152020-10-21 14:37:35 +000043Once environment is set-up, a redis-cluster can be set up using the helm-chart (also provided with
44this commit). Once cluster is running, any master/slave of the redis instance pods can be deleted which
45will be compensated automatically by new instances
46
47At this stage the perl utility program (included with helm-chart) can be run. The helm chart installation
48output generates the requirement commands to invoke.
49
50This utility program identifies the missing anti-affinity(as per above ticket) of redis instances required
51in a redis-cluster. When executed it communicates to redis nodes to switch roles (e.g. master/slave)
52such that the end-state meets the desired anti-affinity.
53
54