Automatic fault tolerance

The cluster manager of Service Fabric ensures failover and resource balancing in case of a hardware failure. This ensures high availability of the services while minimizing manual management and operational overhead.

For a stateless service, Service Fabric lets you define an instance count, which is the number of instances of the stateless service that should be running in the cluster at a given time. The service can be scaled up by increasing the number of instances.

When Service Fabric detects a fault on an instance, it creates a new instance of the service on a healthy node within the cluster to ensure availability. This process is completely automated.

The story becomes a bit more complex for a stateful service. Service Fabric replicates a stateful service on different nodes to achieve high availability. Each replica will contain code used by the service and the state. All write operations are performed on one replica called the primary replica. All other replicas are called secondary replicas. Changes to state on the primary replica are automatically replicated to the secondary replicas by the framework. Service Fabric supports the configuration of a number of active secondary replicas. The higher the number of replicas, the better the fault tolerance of a service.

If the primary replica fails, Service Fabric makes one of the secondary replicas the primary replica and spins up a new instance of a service as a secondary replica.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.142.12.170