Increase HTTP header length limit advertised by Mercurial

RESOLVED FIXED

Status

Developer Services
Mercurial: hg.mozilla.org
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: gps, Assigned: gps)

Tracking

Details

MozReview Requests

Submitter Diff Changes Open Issues Last Updated
Loading...
Error loading review requests:

Attachments

(1 attachment)

(Assignee)

Description

2 years ago
Mercurial advertises a 1024 byte HTTP header length max. I'm pretty sure our server environment supports longer (~8k in httpd currently). Although there's a chance Zeus is enforcing a lower limit.

Let's increase the advertised HTTP header length limit so Mercurial operations that exchange a lot of data over headers don't require as many round trips and number of headers.
(Assignee)

Comment 1

2 years ago
Created attachment 8698286 [details]
MozReview Request: ansible/hg-web: increase HTTP header max length (bug 1232492); r?fubar

ansible/hg-web: increase HTTP header max length (bug 1232492); r?fubar

This config knob was added in Mercurial 3.5 and we forgot to tweak it.
The default has been 1024 forever. httpd defaults to a max of just under
8k. Setting this to 6 * 1024 should be a nice win for operations that
involve lots of header exchange.
Attachment #8698286 - Flags: review?(klibby)
https://reviewboard.mozilla.org/r/27919/#review25107

There is a http!max_header_length setting in the hg service protection class in zeus, but it's disabled (0). There's also two memory buffer limits in the VS connection management section. I know we ran into the max_client_buffer limit at one point and doubled it (at 131072 bytes currently); are we likely to trip those by increasing this?

Otherwise, lgtm.
(Assignee)

Comment 3

2 years ago
https://reviewboard.mozilla.org/r/27919/#review25107

I don't think we'll run into issues with max_client_buffer_limit - I assume that has more to do with HTTP bodies than headers. Since it is 128k and we're increasing something from 1k to 6k, I'm not very concerned at all actually.
(Assignee)

Comment 4

2 years ago
Landed via autoland \o/
Status: ASSIGNED → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → FIXED
Comment on attachment 8698286 [details]
MozReview Request: ansible/hg-web: increase HTTP header max length (bug 1232492); r?fubar

(for some reason, the mozreview r+ didn't carry through so this was still flagged by BMO as awaiting approval. adding r+ manually to clear that)
Attachment #8698286 - Flags: review?(klibby) → review+
You need to log in before you can comment on or make changes to this bug.