Author: bodewig Date: Mon Feb 11 16:22:23 2013 New Revision: 1444847 URL: http://svn.apache.org/r1444847 Log: add 10min connection timeout for clients Modified: gump/mvnrepo/trunk/src/java/org/apache/gump/mvnrepoproxy/Main.java Modified: gump/mvnrepo/trunk/src/java/org/apache/gump/mvnrepoproxy/Main.java URL: http://svn.apache.org/viewvc/gump/mvnrepo/trunk/src/java/org/apache/gump/mvnrepoproxy/Main.java?rev=1444847&r1=1444846&r2=1444847&view=diff ============================================================================== --- gump/mvnrepo/trunk/src/java/org/apache/gump/mvnrepoproxy/Main.java (original) +++ gump/mvnrepo/trunk/src/java/org/apache/gump/mvnrepoproxy/Main.java Mon Feb 11 16:22:23 2013 @@ -36,6 +36,7 @@ import org.apache.gump.mvnrepoproxy.rest import org.apache.gump.mvnrepoproxy.restlets.Stop; import org.restlet.Application; +import org.restlet.Client; import org.restlet.Component; import org.restlet.Restlet; import org.restlet.Route; @@ -67,6 +68,9 @@ public class Main { } } + // ten minutes + private static final int DEFAULT_CONNECT_TIMEOUT =1000 * 60 * 10; + /** * Starts Jetty with the application */ @@ -111,6 +115,9 @@ public class Main { Component c = getRepositoryComponent(); c.getServers().add(Protocol.HTTP, port); c.getClients().add(Protocol.HTTP); + for (Client client : c.getClients()) { + client.setConnectTimeout(DEFAULT_CONNECT_TIMEOUT); + } c.start(); waitForShutdown(); System.err.println("Component finished");