github.com/spotahome/redis-operator@v1.2.4/docs/logic.md (about) 1 # Controller logic 2 3 ## Creation pipeline 4 5 The Redis-Operator creates Redis Failovers, with all the needed pieces. So, when a event arrives from Kubernetes (add or sync), the following steps are executed: 6 7 - Ensure: checks that all the pieces needed are created. It is important to notice that if a change is performed manually on the objects created, the operator will override them. This is done to ensure a healthy status. It will create the following: 8 - Redis service (if exporter enabled) 9 - Redis configmap 10 - Redis shutdown configmap 11 - Redis statefulset 12 - Sentinel service 13 - Sentinel configmap 14 - Sentinel deployment 15 - Check & Heal: will connect to every Redis and Sentinel and will ensure that they are working as they are supposed to do. If this is not the case, it will reconfigure the nodes to move them to the desire state. It will check the following: 16 - Number of Redis is equal as the set on the RF spec 17 - Number of Sentinel is equal as the set on the RF spec 18 - Only one Redis working as a master 19 - All Redis slaves have the same master 20 - All Redis slaves are connected to the master 21 - All Sentinels points to the same Redis master 22 - Sentinel has not death nodes 23 - Sentinel knows the correct slave number 24 - Ensure Redis has the custom configuration set 25 - Ensure Sentinel has the custom configuration set 26 27 Most of the problems that may occur will be treated and tried to fix by the controller, except the case that there are a [split-brain](<https://en.wikipedia.org/wiki/Split-brain_(computing)>). **If happens to be a split-brain, an error will be logged waiting for manual fix**.