aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorDiva Canto2013-06-29 18:35:23 -0700
committerDiva Canto2013-06-29 18:35:23 -0700
commit00093a305d225c98ffe00b656df7943cb50c42b0 (patch)
treefdb0e618735f9bb5af141e6a9271f079adbd6b5c
parentRemove hack to migrate previous experimental-level os materials data. (diff)
downloadopensim-SC_OLD-00093a305d225c98ffe00b656df7943cb50c42b0.zip
opensim-SC_OLD-00093a305d225c98ffe00b656df7943cb50c42b0.tar.gz
opensim-SC_OLD-00093a305d225c98ffe00b656df7943cb50c42b0.tar.bz2
opensim-SC_OLD-00093a305d225c98ffe00b656df7943cb50c42b0.tar.xz
Changed HG status notifications timeout down to 15secs from the default 100.
-rw-r--r--OpenSim/Framework/WebUtil.cs10
-rw-r--r--OpenSim/Services/Connectors/Hypergrid/HGFriendsServicesConnector.cs2
2 files changed, 10 insertions, 2 deletions
diff --git a/OpenSim/Framework/WebUtil.cs b/OpenSim/Framework/WebUtil.cs
index 4599f62..6fb1e0c 100644
--- a/OpenSim/Framework/WebUtil.cs
+++ b/OpenSim/Framework/WebUtil.cs
@@ -962,11 +962,12 @@ namespace OpenSim.Framework
962 /// <param name="verb"></param> 962 /// <param name="verb"></param>
963 /// <param name="requestUrl"></param> 963 /// <param name="requestUrl"></param>
964 /// <param name="obj"> </param> 964 /// <param name="obj"> </param>
965 /// <param name="timeoutsecs"> </param>
965 /// <returns></returns> 966 /// <returns></returns>
966 /// 967 ///
967 /// <exception cref="System.Net.WebException">Thrown if we encounter a network issue while posting 968 /// <exception cref="System.Net.WebException">Thrown if we encounter a network issue while posting
968 /// the request. You'll want to make sure you deal with this as they're not uncommon</exception> 969 /// the request. You'll want to make sure you deal with this as they're not uncommon</exception>
969 public static string MakeRequest(string verb, string requestUrl, string obj) 970 public static string MakeRequest(string verb, string requestUrl, string obj, int timeoutsecs)
970 { 971 {
971 int reqnum = WebUtil.RequestNumber++; 972 int reqnum = WebUtil.RequestNumber++;
972 973
@@ -980,6 +981,8 @@ namespace OpenSim.Framework
980 981
981 WebRequest request = WebRequest.Create(requestUrl); 982 WebRequest request = WebRequest.Create(requestUrl);
982 request.Method = verb; 983 request.Method = verb;
984 if (timeoutsecs > 0)
985 request.Timeout = timeoutsecs * 1000;
983 string respstring = String.Empty; 986 string respstring = String.Empty;
984 987
985 using (MemoryStream buffer = new MemoryStream()) 988 using (MemoryStream buffer = new MemoryStream())
@@ -1073,6 +1076,11 @@ namespace OpenSim.Framework
1073 1076
1074 return respstring; 1077 return respstring;
1075 } 1078 }
1079
1080 public static string MakeRequest(string verb, string requestUrl, string obj)
1081 {
1082 return MakeRequest(verb, requestUrl, obj, -1);
1083 }
1076 } 1084 }
1077 1085
1078 public class SynchronousRestObjectRequester 1086 public class SynchronousRestObjectRequester
diff --git a/OpenSim/Services/Connectors/Hypergrid/HGFriendsServicesConnector.cs b/OpenSim/Services/Connectors/Hypergrid/HGFriendsServicesConnector.cs
index e984a54..622d4e1 100644
--- a/OpenSim/Services/Connectors/Hypergrid/HGFriendsServicesConnector.cs
+++ b/OpenSim/Services/Connectors/Hypergrid/HGFriendsServicesConnector.cs
@@ -277,7 +277,7 @@ namespace OpenSim.Services.Connectors.Hypergrid
277 { 277 {
278 reply = SynchronousRestFormsRequester.MakeRequest("POST", 278 reply = SynchronousRestFormsRequester.MakeRequest("POST",
279 uri, 279 uri,
280 ServerUtils.BuildQueryString(sendData)); 280 ServerUtils.BuildQueryString(sendData), 15);
281 } 281 }
282 catch (Exception e) 282 catch (Exception e)
283 { 283 {