Skip to content

Commit

Permalink
Merge pull request gitblit-org#1243 from sebastianopilla/master
Browse files Browse the repository at this point in the history
Fixes the 30 seconds timeout when cloning over HTTP
  • Loading branch information
gitblit committed Jun 5, 2017
2 parents c1d816d + 203748f commit a13f078
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
7 changes: 7 additions & 0 deletions src/main/distrib/data/defaults.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2134,6 +2134,13 @@ server.requireClientCertificates = false
# RESTART REQUIRED
server.shutdownPort = 8081

# Http idle Timeout (in milliseconds) for http and https requests
# Increase this value if you get java.util.concurrent.TimeoutException errors
#
# SINCE 1.9.0
# RESTART REQUIRED
server.httpIdleTimeout = 30000

#
# Gitblit Filestore Settings
#
Expand Down
6 changes: 3 additions & 3 deletions src/main/java/com/gitblit/GitBlitServer.java
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ public void log(String message) {

ServerConnector connector = new ServerConnector(server, factory);
connector.setSoLingerTime(-1);
connector.setIdleTimeout(30000);
connector.setIdleTimeout(settings.getLong(Keys.server.httpIdleTimeout, 30000L));
connector.setPort(params.securePort);
String bindInterface = settings.getString(Keys.server.httpsBindInterface, null);
if (!StringUtils.isEmpty(bindInterface)) {
Expand Down Expand Up @@ -330,7 +330,7 @@ public void log(String message) {

ServerConnector connector = new ServerConnector(server, new HttpConnectionFactory(httpConfig));
connector.setSoLingerTime(-1);
connector.setIdleTimeout(30000);
connector.setIdleTimeout(settings.getLong(Keys.server.httpIdleTimeout, 30000L));
connector.setPort(params.port);
String bindInterface = settings.getString(Keys.server.httpBindInterface, null);
if (!StringUtils.isEmpty(bindInterface)) {
Expand Down Expand Up @@ -608,4 +608,4 @@ public static class Params {
public String ldapLdifFile;

}
}
}

0 comments on commit a13f078

Please sign in to comment.