You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Kamesh Jayachandran <ka...@collab.net> on 2009/03/18 15:46:01 UTC

[PATCH] Why bother about r->main in webdav write through proxy code?

Hi All,

I was going through the webdav write through proxy filter code.
I could see check for 'r->main' in it.

I tested the following,
1. slave writing to different master host.
2. slave writing to same master host instance but on a different uri.

In both tests I could 'r->main' is always null.

I am not sure why we should bother about sub request inside by checking
for r->main?

Attached patch removes such checks.

Any thoughts?

With regards
Kamesh Jayachandran

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1349115

Re: [PATCH] Why bother about r->main in webdav write through proxy code?

Posted by Justin Erenkrantz <je...@apache.org>.
On Wed, Mar 18, 2009 at 8:55 AM, C. Michael Pilato <cm...@collab.net> wrote:
> We only use subrequests ourselves when invoking the authz callback, and we
> always invoke that using a GET request (which isn't proxied through).  But
> by keeping the checks for r->main present, we avoid the unnecessary proxy
> logic altogether for those subrequests, don't we?

Correct.  You don't want to proxy any sub-req's.  -- justin

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1349886


Re: [PATCH] Why bother about r->main in webdav write through proxy code?

Posted by "C. Michael Pilato" <cm...@collab.net>.
Kamesh Jayachandran wrote:
> Hi All,
> 
> I was going through the webdav write through proxy filter code.
> I could see check for 'r->main' in it.
> 
> I tested the following,
> 1. slave writing to different master host.
> 2. slave writing to same master host instance but on a different uri.
> 
> In both tests I could 'r->main' is always null.
> 
> I am not sure why we should bother about sub request inside by checking
> for r->main?

We only use subrequests ourselves when invoking the authz callback, and we
always invoke that using a GET request (which isn't proxied through).  But
by keeping the checks for r->main present, we avoid the unnecessary proxy
logic altogether for those subrequests, don't we?

-- 
C. Michael Pilato <cm...@collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1349179