cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mlsoren...@apache.org
Subject git commit: updated refs/heads/4.3 to 9df5c18
Date Sat, 11 Jan 2014 00:59:55 GMT
Updated Branches:
  refs/heads/4.3 69aed6fe0 -> 9df5c1885


CLOUDSTACK-5843
For some reason the mgmt server is required to have access to the template
being registered in order to check its size against resource limits
during registration. This is bad, but worse, it's a sync call, so this
call can hang for up to the default HTTP connection timeout.

Reducing http timeout as a quick workaround, but this check needs to
1) be removed or 2) done later or 3)registerTemplate needs to be async
and 4) moved off the mgmt server (ssvm is the only thing that needs access to
template url).


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/9df5c188
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/9df5c188
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/9df5c188

Branch: refs/heads/4.3
Commit: 9df5c18850b24db973c809fab3310224a823591f
Parents: 69aed6f
Author: Marcus Sorensen <marcus@betterservers.com>
Authored: Fri Jan 10 17:57:10 2014 -0700
Committer: Marcus Sorensen <marcus@betterservers.com>
Committed: Fri Jan 10 17:57:10 2014 -0700

----------------------------------------------------------------------
 utils/src/com/cloud/utils/UriUtils.java | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/9df5c188/utils/src/com/cloud/utils/UriUtils.java
----------------------------------------------------------------------
diff --git a/utils/src/com/cloud/utils/UriUtils.java b/utils/src/com/cloud/utils/UriUtils.java
index 4759710..bf96707 100644
--- a/utils/src/com/cloud/utils/UriUtils.java
+++ b/utils/src/com/cloud/utils/UriUtils.java
@@ -152,6 +152,8 @@ public class UriUtils {
             URI uri = new URI(url);
             if (uri.getScheme().equalsIgnoreCase("http")) {
                 httpConn = (HttpURLConnection) uri.toURL().openConnection();
+                httpConn.setConnectTimeout(2000);
+                httpConn.setReadTimeout(5000);
                 if (httpConn != null) {
                     String contentLength = httpConn.getHeaderField("content-length");
                     if (contentLength != null) {


Mime
View raw message