Details
-
New Feature
-
Status: Open
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
Description
This feature request is about improving the behavior of update when working in a write-thru proxy environment and the replica server is out of date. The specific scenario is you have a client that is configured to use a replica server. It does a commit which proxies back to the master which bumps the revision. So the client working copy now knows about this new revision. If the client run svn update it will fail until the replica has synced the new commit. This makes it difficult to write automated scripts that are being used with a replica, something fairly common with CI servers where they may be configured to use a replica to offload work from the master.
In SVN-4021 work was done to improve the error message in this scenario, and AFAIK that still works provided the server and client are on 1.8+ The request is to consider ways to make this not be an error and actually work. A couple possibilities:
- When the server detects this scenario, what if instead of issuing the error it figured out a way to proxy the request back to the master? The master could service the request successfully which would be better than providing an error.
- Seemingly more difficult, but what a lot of users ask for is to have the replica force a sync to happen when it receives this request. This is likely not practical for a number of reasons but it is worth recording it here in the request. What they envision is the server would recognize the scenario, force a sync to happen and then service the update. Assuming this were somehow possible, which I do not believe it is, I would have to assume in most cases the client would timeout before the server had a chance to finish all of this.
Option 1 seems at least somewhat possible. I have vague recollections this was discussed in the past and the feeling was that by the time SVN recognizes the error situation we are beyond the point in the request cycle where we can proxy it. Maybe this is not true though and could be reexamined?