chiark / gitweb /
git-cache-proxy: New --serve-timeout option.
authorIan Jackson <ian.jackson@eu.citrix.com>
Mon, 8 May 2017 16:20:39 +0000 (17:20 +0100)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Mon, 8 May 2017 16:20:42 +0000 (17:20 +0100)
Signed-off-by: Ian Jackson <Ian.Jackson@eu.citrix.com>
debian/changelog
scripts/git-cache-proxy

index 7be9019e8e403615c658e6618a2dc45dd68e62e8..c2dbeb9af8d97e6b663df6846203926b79b94d53 100644 (file)
@@ -1,9 +1,12 @@
-chiark-utils (5.0.3~iwj) unstable; urgency=medium
+chiark-utils (5.0.3~citrix2) unstable; urgency=medium
 
   with-lock-ex:
   * Switch to using getopt.
   * New -t (timeout) option.  Closes:#858555.
 
 
   with-lock-ex:
   * Switch to using getopt.
   * New -t (timeout) option.  Closes:#858555.
 
+  git-cache-proxy:
+  * New --serve-timeout option.
+
   Copyright faff:
   * Add DEVELOPER-CERTIFICATE file and start using S-o-b practice.
   * Convert with-lock-ex to MIT, since the PD dedication is not
   Copyright faff:
   * Add DEVELOPER-CERTIFICATE file and start using S-o-b practice.
   * Convert with-lock-ex to MIT, since the PD dedication is not
index 647f6b60d3c152dae98a16240f0bf9181dcee86b..ffdf6eab52fe57bad3b276ad71a21002abc5011e 100755 (executable)
@@ -67,6 +67,7 @@ our $housekeepingeverydays = 1;
 our $treeexpiredays = 21;
 our $fetchtimeout = 1800;
 our $maxfetchtimeout = 3600;
 our $treeexpiredays = 21;
 our $fetchtimeout = 1800;
 our $maxfetchtimeout = 3600;
+our $servetimeout = 1000;
 our $cachedir = '/var/cache/git-cache-proxy';
 our $housekeepingonly = 0;
 
 our $cachedir = '/var/cache/git-cache-proxy';
 our $housekeepingonly = 0;
 
@@ -172,6 +173,7 @@ for (;;) {
            $cachedir = $1;
        } elsif (s/^--( max-fetch-timeout
                       | fetch-timeout
            $cachedir = $1;
        } elsif (s/^--( max-fetch-timeout
                       | fetch-timeout
+                      | serve-timeout
                       | tree-expire-days
                       | housekeeping-interval-days
                       )=(\d+)$//x) {
                       | tree-expire-days
                       | housekeeping-interval-days
                       )=(\d+)$//x) {
@@ -477,7 +479,7 @@ sub runcommand () {
 
     chdir $gitd or fail "chdir $gitd: $!";
 
 
     chdir $gitd or fail "chdir $gitd: $!";
 
-    exec qw(git-upload-pack --strict --timeout=1000 .)
+    exec qw(git-upload-pack --strict), "--timeout=$servetimeout", qw(.)
        or fail "exec git-upload-pack: $!";
 }
 
        or fail "exec git-upload-pack: $!";
 }