aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework
diff options
context:
space:
mode:
authorDiva Canto2012-09-30 07:48:03 -0700
committerDiva Canto2012-09-30 07:48:03 -0700
commit91a5c602e313b96ffaf1d50b7f0d2923a2e141ba (patch)
tree3c76fe34e863fa990c6da0f72d8350c7476cf1e4 /OpenSim/Framework
parentAdded request.Proxy=null everywhere, as discussed in http://stackoverflow.com... (diff)
downloadopensim-SC_OLD-91a5c602e313b96ffaf1d50b7f0d2923a2e141ba.zip
opensim-SC_OLD-91a5c602e313b96ffaf1d50b7f0d2923a2e141ba.tar.gz
opensim-SC_OLD-91a5c602e313b96ffaf1d50b7f0d2923a2e141ba.tar.bz2
opensim-SC_OLD-91a5c602e313b96ffaf1d50b7f0d2923a2e141ba.tar.xz
Revert "Added request.Proxy=null everywhere, as discussed in http://stackoverflow.com/questions/2519655/httpwebrequest-is-extremely-slow."
But the patch is here, in case anyone wants to try it. This reverts commit 531edd51d82ecd6a842a2611c99e9919634491ef.
Diffstat (limited to 'OpenSim/Framework')
-rw-r--r--OpenSim/Framework/Communications/RestClient.cs2
-rw-r--r--OpenSim/Framework/Configuration/HTTP/HTTPConfiguration.cs1
-rw-r--r--OpenSim/Framework/RegionLoader/Web/RegionLoaderWebServer.cs1
-rw-r--r--OpenSim/Framework/Servers/HttpServer/RestObjectPoster.cs1
-rw-r--r--OpenSim/Framework/Servers/HttpServer/RestObjectPosterResponse.cs1
-rw-r--r--OpenSim/Framework/Servers/HttpServer/RestSessionService.cs2
-rw-r--r--OpenSim/Framework/UntrustedWebRequest.cs1
-rw-r--r--OpenSim/Framework/WebUtil.cs5
8 files changed, 0 insertions, 14 deletions
diff --git a/OpenSim/Framework/Communications/RestClient.cs b/OpenSim/Framework/Communications/RestClient.cs
index 226e52f..97b3b60 100644
--- a/OpenSim/Framework/Communications/RestClient.cs
+++ b/OpenSim/Framework/Communications/RestClient.cs
@@ -306,7 +306,6 @@ namespace OpenSim.Framework.Communications
306 _request.ContentType = "application/xml"; 306 _request.ContentType = "application/xml";
307 _request.Timeout = 200000; 307 _request.Timeout = 200000;
308 _request.Method = RequestMethod; 308 _request.Method = RequestMethod;
309 _request.Proxy = null;
310 _asyncException = null; 309 _asyncException = null;
311 310
312// IAsyncResult responseAsyncResult = _request.BeginGetResponse(new AsyncCallback(ResponseIsReadyDelegate), _request); 311// IAsyncResult responseAsyncResult = _request.BeginGetResponse(new AsyncCallback(ResponseIsReadyDelegate), _request);
@@ -366,7 +365,6 @@ namespace OpenSim.Framework.Communications
366 _request.ContentType = "application/xml"; 365 _request.ContentType = "application/xml";
367 _request.Timeout = 900000; 366 _request.Timeout = 900000;
368 _request.Method = RequestMethod; 367 _request.Method = RequestMethod;
369 _request.Proxy = null;
370 _asyncException = null; 368 _asyncException = null;
371 _request.ContentLength = src.Length; 369 _request.ContentLength = src.Length;
372 370
diff --git a/OpenSim/Framework/Configuration/HTTP/HTTPConfiguration.cs b/OpenSim/Framework/Configuration/HTTP/HTTPConfiguration.cs
index 7aaf776..3dce578 100644
--- a/OpenSim/Framework/Configuration/HTTP/HTTPConfiguration.cs
+++ b/OpenSim/Framework/Configuration/HTTP/HTTPConfiguration.cs
@@ -65,7 +65,6 @@ namespace OpenSim.Framework.Configuration.HTTP
65 byte[] buf = new byte[8192]; 65 byte[] buf = new byte[8192];
66 HttpWebRequest request = 66 HttpWebRequest request =
67 (HttpWebRequest) WebRequest.Create(remoteConfigSettings.baseConfigURL + configFileName); 67 (HttpWebRequest) WebRequest.Create(remoteConfigSettings.baseConfigURL + configFileName);
68 request.Proxy = null;
69 HttpWebResponse response = (HttpWebResponse) request.GetResponse(); 68 HttpWebResponse response = (HttpWebResponse) request.GetResponse();
70 69
71 Stream resStream = response.GetResponseStream(); 70 Stream resStream = response.GetResponseStream();
diff --git a/OpenSim/Framework/RegionLoader/Web/RegionLoaderWebServer.cs b/OpenSim/Framework/RegionLoader/Web/RegionLoaderWebServer.cs
index 96d4d59..a2f5d9c 100644
--- a/OpenSim/Framework/RegionLoader/Web/RegionLoaderWebServer.cs
+++ b/OpenSim/Framework/RegionLoader/Web/RegionLoaderWebServer.cs
@@ -70,7 +70,6 @@ namespace OpenSim.Framework.RegionLoader.Web
70 int regionCount = 0; 70 int regionCount = 0;
71 HttpWebRequest webRequest = (HttpWebRequest) WebRequest.Create(url); 71 HttpWebRequest webRequest = (HttpWebRequest) WebRequest.Create(url);
72 webRequest.Timeout = 30000; //30 Second Timeout 72 webRequest.Timeout = 30000; //30 Second Timeout
73 webRequest.Proxy = null;
74 m_log.DebugFormat("[WEBLOADER]: Sending download request to {0}", url); 73 m_log.DebugFormat("[WEBLOADER]: Sending download request to {0}", url);
75 74
76 try 75 try
diff --git a/OpenSim/Framework/Servers/HttpServer/RestObjectPoster.cs b/OpenSim/Framework/Servers/HttpServer/RestObjectPoster.cs
index 61161e3..48ced19 100644
--- a/OpenSim/Framework/Servers/HttpServer/RestObjectPoster.cs
+++ b/OpenSim/Framework/Servers/HttpServer/RestObjectPoster.cs
@@ -50,7 +50,6 @@ namespace OpenSim.Framework.Servers.HttpServer
50 50
51 WebRequest request = WebRequest.Create(requestUrl); 51 WebRequest request = WebRequest.Create(requestUrl);
52 request.Method = verb; 52 request.Method = verb;
53 request.Proxy = null;
54 request.ContentType = "text/xml"; 53 request.ContentType = "text/xml";
55 54
56 MemoryStream buffer = new MemoryStream(); 55 MemoryStream buffer = new MemoryStream();
diff --git a/OpenSim/Framework/Servers/HttpServer/RestObjectPosterResponse.cs b/OpenSim/Framework/Servers/HttpServer/RestObjectPosterResponse.cs
index 727f027..451745c 100644
--- a/OpenSim/Framework/Servers/HttpServer/RestObjectPosterResponse.cs
+++ b/OpenSim/Framework/Servers/HttpServer/RestObjectPosterResponse.cs
@@ -57,7 +57,6 @@ namespace OpenSim.Framework.Servers.HttpServer
57 57
58 WebRequest request = WebRequest.Create(requestUrl); 58 WebRequest request = WebRequest.Create(requestUrl);
59 request.Method = verb; 59 request.Method = verb;
60 request.Proxy = null;
61 request.ContentType = "text/xml"; 60 request.ContentType = "text/xml";
62 request.Timeout = 10000; 61 request.Timeout = 10000;
63 62
diff --git a/OpenSim/Framework/Servers/HttpServer/RestSessionService.cs b/OpenSim/Framework/Servers/HttpServer/RestSessionService.cs
index 1612d4a..19c03a8 100644
--- a/OpenSim/Framework/Servers/HttpServer/RestSessionService.cs
+++ b/OpenSim/Framework/Servers/HttpServer/RestSessionService.cs
@@ -74,7 +74,6 @@ namespace OpenSim.Framework.Servers.HttpServer
74 74
75 WebRequest request = WebRequest.Create(requestUrl); 75 WebRequest request = WebRequest.Create(requestUrl);
76 request.Method = verb; 76 request.Method = verb;
77 request.Proxy = null;
78 request.ContentType = "text/xml"; 77 request.ContentType = "text/xml";
79 request.Timeout = 20000; 78 request.Timeout = 20000;
80 79
@@ -140,7 +139,6 @@ namespace OpenSim.Framework.Servers.HttpServer
140 139
141 WebRequest request = WebRequest.Create(requestUrl); 140 WebRequest request = WebRequest.Create(requestUrl);
142 request.Method = verb; 141 request.Method = verb;
143 request.Proxy = null;
144 request.ContentType = "text/xml"; 142 request.ContentType = "text/xml";
145 request.Timeout = 10000; 143 request.Timeout = 10000;
146 144
diff --git a/OpenSim/Framework/UntrustedWebRequest.cs b/OpenSim/Framework/UntrustedWebRequest.cs
index f2355b1..e6411cc 100644
--- a/OpenSim/Framework/UntrustedWebRequest.cs
+++ b/OpenSim/Framework/UntrustedWebRequest.cs
@@ -88,7 +88,6 @@ namespace OpenSim.Framework
88 httpWebRequest.ReadWriteTimeout = readWriteTimeoutMS; 88 httpWebRequest.ReadWriteTimeout = readWriteTimeoutMS;
89 httpWebRequest.Timeout = timeoutMS; 89 httpWebRequest.Timeout = timeoutMS;
90 httpWebRequest.KeepAlive = false; 90 httpWebRequest.KeepAlive = false;
91 httpWebRequest.Proxy = null;
92 91
93 return httpWebRequest; 92 return httpWebRequest;
94 } 93 }
diff --git a/OpenSim/Framework/WebUtil.cs b/OpenSim/Framework/WebUtil.cs
index 9eff0d2..1d9e2ce 100644
--- a/OpenSim/Framework/WebUtil.cs
+++ b/OpenSim/Framework/WebUtil.cs
@@ -171,7 +171,6 @@ namespace OpenSim.Framework
171 request.Method = method; 171 request.Method = method;
172 request.Timeout = timeout; 172 request.Timeout = timeout;
173 request.KeepAlive = false; 173 request.KeepAlive = false;
174 request.Proxy = null;
175 request.MaximumAutomaticRedirections = 10; 174 request.MaximumAutomaticRedirections = 10;
176 request.ReadWriteTimeout = timeout / 4; 175 request.ReadWriteTimeout = timeout / 4;
177 request.Headers[OSHeaderRequestID] = reqnum.ToString(); 176 request.Headers[OSHeaderRequestID] = reqnum.ToString();
@@ -351,7 +350,6 @@ namespace OpenSim.Framework
351 request.Method = "POST"; 350 request.Method = "POST";
352 request.Timeout = timeout; 351 request.Timeout = timeout;
353 request.KeepAlive = false; 352 request.KeepAlive = false;
354 request.Proxy = null;
355 request.MaximumAutomaticRedirections = 10; 353 request.MaximumAutomaticRedirections = 10;
356 request.ReadWriteTimeout = timeout / 4; 354 request.ReadWriteTimeout = timeout / 4;
357 request.Headers[OSHeaderRequestID] = reqnum.ToString(); 355 request.Headers[OSHeaderRequestID] = reqnum.ToString();
@@ -732,7 +730,6 @@ namespace OpenSim.Framework
732 Type type = typeof(TRequest); 730 Type type = typeof(TRequest);
733 731
734 WebRequest request = WebRequest.Create(requestUrl); 732 WebRequest request = WebRequest.Create(requestUrl);
735 request.Proxy = null;
736 WebResponse response = null; 733 WebResponse response = null;
737 TResponse deserial = default(TResponse); 734 TResponse deserial = default(TResponse);
738 XmlSerializer deserializer = new XmlSerializer(typeof(TResponse)); 735 XmlSerializer deserializer = new XmlSerializer(typeof(TResponse));
@@ -927,7 +924,6 @@ namespace OpenSim.Framework
927 924
928 WebRequest request = WebRequest.Create(requestUrl); 925 WebRequest request = WebRequest.Create(requestUrl);
929 request.Method = verb; 926 request.Method = verb;
930 request.Proxy = null;
931 string respstring = String.Empty; 927 string respstring = String.Empty;
932 928
933 using (MemoryStream buffer = new MemoryStream()) 929 using (MemoryStream buffer = new MemoryStream())
@@ -1055,7 +1051,6 @@ namespace OpenSim.Framework
1055 1051
1056 WebRequest request = WebRequest.Create(requestUrl); 1052 WebRequest request = WebRequest.Create(requestUrl);
1057 request.Method = verb; 1053 request.Method = verb;
1058 request.Proxy = null;
1059 MemoryStream buffer = null; 1054 MemoryStream buffer = null;
1060 1055
1061 if ((verb == "POST") || (verb == "PUT")) 1056 if ((verb == "POST") || (verb == "PUT"))