We describe the interactions between the modules of the
system and the use of various data structures using a simple
scenario--a user on server S creates file
in directory
.
For the moment, assume that S already stores a replica of
(if not, S creates one, using the protocol described in
Section 4.2.) First, S determines the location of
initial replicas of
, which will become the gold replicas
of the file (a typical value for
is 3). One replica will reside
on
. The other
replicas are chosen at random from different
regions in the system to improve the expected availability of the
file. Second, S creates the local
replica for
and adds an entry
for
in the local replica of
. S then replies to the
client, and the client can start accessing the file.
In the background, S disseminates two types of updates. It first
``floods'' the new directory contents to other directory
replicas. It also floods the contents of
(which is empty, save for attributes such as
permissions and owner) to its gold-replica nodes. In practice, as
we describe in Section 5, we deploy several techniques to
reduce the overhead of flooding dramatically. As a side effect of the
propagation, the replicas of
will point to
's gold replicas so that
the latter can be discovered during future path-name lookups.