Learning about the resource hierarchy for each container

The following diagram shows the resource hierarchy for each container. For example, as previously learned, in a document database, the container is a collection:

The containers are the logical resources that are exposed to the APIs as collections, graphs, or tables. Each container has partition sets, which are composed of database replicas. The database service hosts four replicas per region. This way, whenever there are either hardware or software updates, they are completely transparent to us and we can continue working with the remaining replicas.

Resource partitions provide resource-governed coordination primitives. The following diagram shows a replica set in detail. Notice that each replica set hosts an instance of the database engine:

The database service is always online and available. The software and hardware updates on the Azure side happen under the hood for one out of four replicas per region while the remaining replicas continue working. Hence, we don't have to worry about availability due to operating system or database engine updates.