[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

RE: [PATCH] Make svn clients indicate their operation name to backend(right now only to DAV)

From: Kamesh Jayachandran <kamesh_at_collab.net>
Date: Thu, 7 Jan 2010 00:04:15 +0530

Julian,

>As I understand it, the proxy was designed originally with some rules
>that effectively said something like

> * The following operations are passed through to the master:
> MKACTIVITY ...

Add MERGE, LOCK, UNLOCK and any request having '!svn' in its URI.

> * The following operations are handled by the proxy:
> REPORT OPTIONS ...

> * The following operations are handled by the proxy if referring to a
>cached revision, else passed through to the master:
> PROPFIND GET ...

>Now we discovered that this is too low-level, and in fact if a client
>has done a commit (MKACTIVITY) it then needs to receive up-to-date info
>when it subsequently does a PROPFIND, because it expects to be able to
>see the results of its commit.

MKACTIVITY is *not* commit though it is a starting point of any commit.

>Can we define the new rules of proxying? I'm unfamiliar with it so my
>guess below is probably way out. Please could you correct this attempt:

>RULES OF PROXYING

> * The following operations are passed through to the master:
> MKACTIVITY ...

Add MERGE, LOCK, UNLOCK and any request having '!svn' in its URI.

> * The following operations are handled by the proxy:
> REPORT OPTIONS ...

> * The following operations are handled by the proxy if referring to a
>cached revision *AND IF THE CLIENT HAS NOT PERFORMED A COMMIT IN THIS
>CONNECTION*, else passed through to the master:
> PROPFIND GET ...

>And what is the theory behind these rules?

> * A client that has completed a commit needs to see the new state of
>the master repository, in order to avoid errors like the one we are
>fixing.

I think you misunderstood the problem, the error we have observed occurs even before the commit completes rather it occurs during the start phase of the commit.

> * A client that has completed a commit must have started a commit and
>therefore must have issued a MKACTIVITY.

commit is not complete here.

> * A commit and any associated housekeeping tasks always occur within a
>single connection. (? - doesn't sound right)

It can occur over multiple connections though most of the time it may happen on the same connection. If it happens on the same connection we do not need 'SVN-ACTION' header at all as we can belive the connection pool, unfortunately it is not.

> * Only the PROPFIND needs this special handling, because it is the
>only operation that can find out about a new head revision number. (?)

Not sure of other operations :).

> * Only the MKACTIVITY needs to trigger this behaviour, because that is
>the only operation by which this client can create a new head revision
>number. (?)

I think 'MERGE' creates the head revision, we use MKACTIVITY as identification of commit in progress.

With regards
Kamesh Jayachandran
Received on 2010-01-06 19:34:54 CET

This is an archived mail posted to the Subversion Dev mailing list.