X-Git-Url: http://git.openafs.org/?p=openafs-wiki.git;a=blobdiff_plain;f=diagrams%2Fafs-cb-story.mdwn;h=3854740c5cb77fd052e1e36630d03a28b4d9475c;hp=d6b67cc92ac1821a760911ee66d317ecfafb42e6;hb=e226def8404a8de23e595cbb5cac3074e7f2d173;hpb=feaffb9a55243f14af75dd3ab732f8ff71aecf8b diff --git a/diagrams/afs-cb-story.mdwn b/diagrams/afs-cb-story.mdwn index d6b67cc..3854740 100644 --- a/diagrams/afs-cb-story.mdwn +++ b/diagrams/afs-cb-story.mdwn @@ -1,57 +1,67 @@ # Create file + ![afs-cb-0][1] -1. create file on *host d* - * data version (dv) = 1 +1. create file on **host d** + * data version **(dv) = 1** * callback registration -2. read on *hosts a,b,c* +2. read on **hosts a,b,c** 3. fetch-states 4. add callback at fileserver # Replicate file + ![afs-cb-1][2] -hello.c propagates to *hosts a,b,c* from fileserver. Callbacks are registered for a period of time. Callbacks notify a host if a change occurs. + +hello.c propagates to **hosts a,b,c** from fileserver. Callbacks are registered for a period of time. Callbacks notify a host if a change occurs. # Modify file + ![afs-cb-2][3] + host a modifies the file. -1. open, write, close on *host a* +1. open, write, close on **host a** 2. store-data -3. callbacks *b,c,d* are called +3. callbacks **b,c,d** are called * "break" callbacks once called (i.e. remove them from the table once called) -4. reply *dv=2* for *host a* - * incremented at the *fileserver* +4. reply **dv=2** for **host a** + * incremented at the **fileserver** # Read stale file + ![afs-cb-3][4] -read a stale file on *host c*. -1. open, read on *host c* +read a stale file on **host c**. + +1. open, read on **host c** 2. fetch-status - * returns *dv=2* > local cached *dv=1* -3. fetch-data *dv=2* for *host c* - * registers callback for the file on *host c* + * returns **dv=2** > local cached **dv=1** +3. fetch-data **dv=2** for **host c** + * registers callback for the file on **host c** # Callback expires + ![afs-cb-4][5] -1. callbacks *a,c* expire. -2. read file on *host c* +1. callbacks **a,c** expire. +2. read file on **host c** 3. fetch-status - * returns *dv=2* == local cached *dv* - * registers a new callback for the file on *host c* with *fileserver* + * returns **dv=2** == local cached **dv** + * registers a new callback for the file on **host c** with **fileserver** 4. new callback. cached data so local data is used. # Callback failure + ![afs-cb-5][6] + a common failure mode: callback to host fails -1. write, close on *host a* +1. write, close on **host a** 2. store-data 3. callback (fails) 4. store-data reply - * *fileserver* increments *dv=3* + * **fileserver** increments **dv=3** 5. delayed callback (fails until it does not) 6. callback expires (read fails)