We will talk more about failover in the next section, but it is important here to mention that load balancing can be used to implement a failover strategy. Here, the goal will be to try the request against another machine if the current one fails. This can be sort of seen as round-robin, but instead of using each request as a trigger for the iteration over the hosts (to change targeted instance), a failure would be the trigger. Here is an example sequence using the failover strategy, considering that we have the same three hosts as in the round-robin part:
Request number
|
Selected server
|
Status
|
1
|
server1.company.com
|
OK
|
2
|
server1.company.com
|
OK
|
3
|
server1.company.com
|
OK
|
4
|
server1.company.com ... |