This topic introduces the leader and follower nodes and the Cluster Coordinator.
The leader node is a single Dgraph process in the cluster responsible for processing queries and for receiving updates to the data files and to the configuration. This node is responsible for obtaining information about the latest versions of the data files and propagating this information to the follower nodes through the Cluster Coordinator.
The leader node periodically receives full or incremental data files updates from Integrator. It also receives administration or configuration updates. It is the only node in the cluster that has access with write permissions to the on-disk representation of the index.
Once the leader node acquires access to the new version of the data files, it updates the data files, adding new information and deleting information that has become obsolete. The Cluster Coordinator notifies all follower nodes, alerting them to start using the updated version of the data files. The follower nodes acquire read-only access to an updated version of the data files.
A follower node is a node in the cluster responsible for processing queries. The follower node does not update the data files, although it has read-only access to their latest copy.
During the process of acquiring access to the recently updated data files, both the follower and the leader nodes continue to serve queries. Each query is processed against a specific version of the data files that is available to a cluster node at any given time. Query processing performance may slow down as the follower nodes acquire read-only access to the updated data files.
An entity that provides a mechanism for the nodes to communicate with each other.