1
How we will extend ra_dav/mod_dav_svn protocol for locking feature
2
==================================================================
7
* send http LOCK request with 2 custom headers:
10
- working-revnum (for OOD check)
12
* mod_dav_svn should call authz_read func on path, if it exists.
14
* generate http LOCK response, which includes standard body that
15
describes almost all the svn_lock_t fields.
17
- add one custom response header: creation-date
19
* what if older server? just returns '405 Method not Allowed'.
24
* send http UNLOCK request with 1 custom header:
28
* mod_dav_svn should call authz_read func on path, if it exists.
30
* generate http UNLOCK response: success == "204 no content"
32
* what if older server? just returns '405 Method not Allowed'.
38
* do a depth-0 PROPFIND for DAV:lockdiscovery property
40
* mod_dav_svn should call authz_read func on path, if it exists.
42
* response is the same as what comes back in a LOCK response --
43
a standard property value that describes almost all the
46
- add one custom response header: X-SVN-creation-date
48
* what if older server? just returns '404 Not Found'.
53
* custom REPORT request.
55
* mod_dav_svn should call svn_repos_fs_get_locks(), because it
56
automatically uses the authz_read func to screen out paths.
60
* what if older server? return some sort of 4XX response and
61
error indicating the report-type is unknown.
63
*** NOTE: a dumb client can achieve the exact same effect by
64
doing a depth-infinity PROPFIND for the 'DAV:lockdiscovery'
65
property. But this causes mod_dav_svn to do an O(N)
66
traversal of the repository, running svn_fs_get_lock() on
67
each path! Much, *much* slower than allowing fs_get_locks()
68
to do a partial-key database lookup!
72
RA->get_commit_editor2()
74
* stash the incoming hash of tokens.
76
* every time we do a CHECKOUT, PUT, COPY, DELETE, PROPPATCH of a
77
file path, look to see if there's a token available in the
78
hash. If so, put it in the If: header of the request.
80
* send *all* tokens in the If: header of the final MERGE request.
82
-- also send either a new XML body element, or custom
83
header, indicating whether to 'keep_locks' or not.
85
* what if older server? meaningless. why would you have the
86
tokens in the first place. And anyway, the If: tokens will be
87
ignored anyway if the server isn't paying attention to locking.