git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* disabling PROPFIND when using smart http
@ 2010-11-23 15:40 Sitaram Chamarty
  2010-11-23 16:10 ` Ilari Liusvaara
  0 siblings, 1 reply; 5+ messages in thread
From: Sitaram Chamarty @ 2010-11-23 15:40 UTC (permalink / raw)
  To: Git Mailing List; +Cc: Shawn O. Pearce

Hello,

Although smart http worked fine for me out of the box, following "man
git-http-backend", I've found folks on #git for whom it seems to fail
on doing a PROPFIND (found by setting GIT_CURL_VERBOSE=1).  Enabling
WebDAV also doesn't seem to help, although that is quite likely to be
some nuance in the Apache config I suppose.

The thing is, I *think* that PROPFIND is not, strictly speaking,
needed when you use the smart HTTP mode.  If that is indeed true, can
we stop git from even attempting it, and so avoid the need to setup
WebDAV on Apache?

Would be a great help for many installations.

Thanks,


--
Sitaram

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: disabling PROPFIND when using smart http
  2010-11-23 15:40 disabling PROPFIND when using smart http Sitaram Chamarty
@ 2010-11-23 16:10 ` Ilari Liusvaara
  2010-11-23 17:31   ` Scott Chacon
  0 siblings, 1 reply; 5+ messages in thread
From: Ilari Liusvaara @ 2010-11-23 16:10 UTC (permalink / raw)
  To: Sitaram Chamarty; +Cc: Git Mailing List, Shawn O. Pearce

On Tue, Nov 23, 2010 at 09:10:43PM +0530, Sitaram Chamarty wrote:
> Hello,
> 
> Although smart http worked fine for me out of the box, following "man
> git-http-backend", I've found folks on #git for whom it seems to fail
> on doing a PROPFIND (found by setting GIT_CURL_VERBOSE=1).  Enabling
> WebDAV also doesn't seem to help, although that is quite likely to be
> some nuance in the Apache config I suppose.
> 
> The thing is, I *think* that PROPFIND is not, strictly speaking,
> needed when you use the smart HTTP mode.  If that is indeed true, can
> we stop git from even attempting it, and so avoid the need to setup
> WebDAV on Apache?

I thought that this is quite strange, and as consequence, decided to
dig a bit. 

This is pretty telling:

$ git grep -i --files-with-matches "propfind"
http-push.c

http-push.c is AFAIK not used by smart HTTP, only by dumb HTTP
push.

Apparently pusher is falling back to dumb WebDAV push for some
reason. And then failing because server does not support it
or isn't configured apporiately for it.

-Ilari

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: disabling PROPFIND when using smart http
  2010-11-23 16:10 ` Ilari Liusvaara
@ 2010-11-23 17:31   ` Scott Chacon
  2010-11-23 19:40     ` Sitaram Chamarty
  0 siblings, 1 reply; 5+ messages in thread
From: Scott Chacon @ 2010-11-23 17:31 UTC (permalink / raw)
  To: Ilari Liusvaara; +Cc: Sitaram Chamarty, Git Mailing List, Shawn O. Pearce

Hey,

On Tue, Nov 23, 2010 at 8:10 AM, Ilari Liusvaara
<ilari.liusvaara@elisanet.fi> wrote:
> Apparently pusher is falling back to dumb WebDAV push for some
> reason. And then failing because server does not support it
> or isn't configured apporiately for it.

Yes, the client will fall back to 'dumb' HTTP stuff if the server does
not respond properly to the initial /info/refs GET call.  I believe
it's something like if the client asks for

/info/refs?service=git-upload-pack

and the server does not respond with the first line being:

# service=git-upload-pack

or the Content-Type header being:

application/x-git-upload-pack-advertisement

I believe either of those being absent will cause the client to think
that it's not a smart server, so it falls back to the DAV based push.
If you let us know what the curl output before that point was, or what
your apache config looks like, we might be able to help figure out
what's wrong with the server.

I got these DAV fallbacks all the time when my proxy wasn't letting
the /info/refs calls through to Apache properly.

Scott

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: disabling PROPFIND when using smart http
  2010-11-23 17:31   ` Scott Chacon
@ 2010-11-23 19:40     ` Sitaram Chamarty
  2010-11-23 19:50       ` Scott Chacon
  0 siblings, 1 reply; 5+ messages in thread
From: Sitaram Chamarty @ 2010-11-23 19:40 UTC (permalink / raw)
  To: Scott Chacon; +Cc: Ilari Liusvaara, Git Mailing List, Shawn O. Pearce

On Tue, Nov 23, 2010 at 11:01 PM, Scott Chacon <schacon@gmail.com> wrote:
> Hey,
>
> On Tue, Nov 23, 2010 at 8:10 AM, Ilari Liusvaara
> <ilari.liusvaara@elisanet.fi> wrote:
>> Apparently pusher is falling back to dumb WebDAV push for some
>> reason. And then failing because server does not support it
>> or isn't configured apporiately for it.
>
> Yes, the client will fall back to 'dumb' HTTP stuff if the server does
> not respond properly to the initial /info/refs GET call.  I believe
> it's something like if the client asks for
>
> /info/refs?service=git-upload-pack
>
> and the server does not respond with the first line being:
>
> # service=git-upload-pack
>
> or the Content-Type header being:
>
> application/x-git-upload-pack-advertisement
>
> I believe either of those being absent will cause the client to think
> that it's not a smart server, so it falls back to the DAV based push.
> If you let us know what the curl output before that point was, or what
> your apache config looks like, we might be able to help figure out
> what's wrong with the server.

Well it was someone else, but the pastie he has sent was
http://pastebin.com/eaB0G1gx -- which may or may not help, because it
doesn't seem to show the response *body*, only the headers.

If that doesn't help I'll try and reproduce the problem myself first.

Thanks,

Sitaram

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: disabling PROPFIND when using smart http
  2010-11-23 19:40     ` Sitaram Chamarty
@ 2010-11-23 19:50       ` Scott Chacon
  0 siblings, 0 replies; 5+ messages in thread
From: Scott Chacon @ 2010-11-23 19:50 UTC (permalink / raw)
  To: Sitaram Chamarty; +Cc: Ilari Liusvaara, Git Mailing List, Shawn O. Pearce

Hey,

On Tue, Nov 23, 2010 at 11:40 AM, Sitaram Chamarty <sitaramc@gmail.com> wrote:
>
> Well it was someone else, but the pastie he has sent was
> http://pastebin.com/eaB0G1gx -- which may or may not help, because it
> doesn't seem to show the response *body*, only the headers.
>
> If that doesn't help I'll try and reproduce the problem myself first.

Still, it's enough.  The request is obviously not getting back to the
Git CGI for some reason.  There are a number of headers that should
have been returned after the first authed GET to /info/refs (lines
35-42 have the servers response).  It should have:

< Content-Type: application/x-git-receive-pack-advertisement
< Pragma: no-cache
< Cache-Control: no-cache, max-age=0, must-revalidate

The Git CGI will set all of those.  Since it's not, and it's setting
things like ETags, it's not the Git CGI you're communicating with.
Check the apache logs and see why it's not routing the request to the
cgi.

Scott

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-11-23 19:51 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-23 15:40 disabling PROPFIND when using smart http Sitaram Chamarty
2010-11-23 16:10 ` Ilari Liusvaara
2010-11-23 17:31   ` Scott Chacon
2010-11-23 19:40     ` Sitaram Chamarty
2010-11-23 19:50       ` Scott Chacon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).