diff options
author | UbitUmarov | 2015-09-03 18:39:08 +0100 |
---|---|---|
committer | UbitUmarov | 2015-09-03 18:39:08 +0100 |
commit | cdaed113872f0615a0d2864cc54064a4432054c6 (patch) | |
tree | 246e62dfeffac632cdcd9738a77faebd30b3bd6c /OpenSim/Framework | |
parent | seems to compile ( tests comented out) (diff) | |
download | opensim-SC_OLD-cdaed113872f0615a0d2864cc54064a4432054c6.zip opensim-SC_OLD-cdaed113872f0615a0d2864cc54064a4432054c6.tar.gz opensim-SC_OLD-cdaed113872f0615a0d2864cc54064a4432054c6.tar.bz2 opensim-SC_OLD-cdaed113872f0615a0d2864cc54064a4432054c6.tar.xz |
at last we can login and see objects ( friends is dead and disable in
scenepresence)
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Framework/Communications/RestClient.cs | 8 | ||||
-rw-r--r-- | OpenSim/Framework/Console/CommandConsole.cs | 2 | ||||
-rwxr-xr-x | OpenSim/Framework/Monitoring/SimExtraStatsCollector.cs | 8 | ||||
-rw-r--r-- | OpenSim/Framework/Servers/HttpServer/PollServiceRequestManager.cs | 56 | ||||
-rw-r--r-- | OpenSim/Framework/VersionInfo.cs | 2 | ||||
-rw-r--r-- | OpenSim/Framework/WebUtil.cs | 18 |
6 files changed, 21 insertions, 73 deletions
diff --git a/OpenSim/Framework/Communications/RestClient.cs b/OpenSim/Framework/Communications/RestClient.cs index 7c89e6b..807222b 100644 --- a/OpenSim/Framework/Communications/RestClient.cs +++ b/OpenSim/Framework/Communications/RestClient.cs | |||
@@ -388,10 +388,6 @@ namespace OpenSim.Framework.Communications | |||
388 | m_log.Error(string.Format("[REST CLIENT] Error fetching resource from server: {0} ", _request.Address.ToString()), e); | 388 | m_log.Error(string.Format("[REST CLIENT] Error fetching resource from server: {0} ", _request.Address.ToString()), e); |
389 | } | 389 | } |
390 | } | 390 | } |
391 | |||
392 | if (_response != null) | ||
393 | _response.Close(); | ||
394 | |||
395 | return null; | 391 | return null; |
396 | } | 392 | } |
397 | 393 | ||
@@ -417,7 +413,7 @@ namespace OpenSim.Framework.Communications | |||
417 | _request = (HttpWebRequest) WebRequest.Create(buildUri()); | 413 | _request = (HttpWebRequest) WebRequest.Create(buildUri()); |
418 | _request.KeepAlive = false; | 414 | _request.KeepAlive = false; |
419 | _request.ContentType = "application/xml"; | 415 | _request.ContentType = "application/xml"; |
420 | _request.Timeout = 30000; | 416 | _request.Timeout = 90000; |
421 | _request.Method = RequestMethod; | 417 | _request.Method = RequestMethod; |
422 | _asyncException = null; | 418 | _asyncException = null; |
423 | _request.ContentLength = src.Length; | 419 | _request.ContentLength = src.Length; |
@@ -476,8 +472,6 @@ namespace OpenSim.Framework.Communications | |||
476 | } | 472 | } |
477 | } | 473 | } |
478 | 474 | ||
479 | _response.Close(); | ||
480 | |||
481 | if (_response != null) | 475 | if (_response != null) |
482 | _response.Close(); | 476 | _response.Close(); |
483 | 477 | ||
diff --git a/OpenSim/Framework/Console/CommandConsole.cs b/OpenSim/Framework/Console/CommandConsole.cs index 851fbed..d908b68 100644 --- a/OpenSim/Framework/Console/CommandConsole.cs +++ b/OpenSim/Framework/Console/CommandConsole.cs | |||
@@ -83,7 +83,7 @@ namespace OpenSim.Framework.Console | |||
83 | = "To enter an argument that contains spaces, surround the argument with double quotes.\nFor example, show object name \"My long object name\"\n"; | 83 | = "To enter an argument that contains spaces, surround the argument with double quotes.\nFor example, show object name \"My long object name\"\n"; |
84 | 84 | ||
85 | public const string ItemHelpText | 85 | public const string ItemHelpText |
86 | = @"For more information, type 'help' to get a list of all commands, | 86 | = @"For more information, type 'help ' to get a list of all commands, |
87 | or type help <item>' where <item> is one of the following:"; | 87 | or type help <item>' where <item> is one of the following:"; |
88 | 88 | ||
89 | /// <value> | 89 | /// <value> |
diff --git a/OpenSim/Framework/Monitoring/SimExtraStatsCollector.cs b/OpenSim/Framework/Monitoring/SimExtraStatsCollector.cs index e4df7ee..b0fdc81 100755 --- a/OpenSim/Framework/Monitoring/SimExtraStatsCollector.cs +++ b/OpenSim/Framework/Monitoring/SimExtraStatsCollector.cs | |||
@@ -281,10 +281,10 @@ namespace OpenSim.Framework.Monitoring | |||
281 | activeScripts = stats.StatsBlock[19].StatValue; | 281 | activeScripts = stats.StatsBlock[19].StatValue; |
282 | scriptLinesPerSecond = stats.StatsBlock[20].StatValue; | 282 | scriptLinesPerSecond = stats.StatsBlock[20].StatValue; |
283 | m_frameDilation = stats.StatsBlock[22].StatValue; | 283 | m_frameDilation = stats.StatsBlock[22].StatValue; |
284 | m_usersLoggingIn = stats.StatsBlock[23].StatValue; | 284 | // m_usersLoggingIn = stats.StatsBlock[23].StatValue; |
285 | m_totalGeoPrims = stats.StatsBlock[24].StatValue; | 285 | // m_totalGeoPrims = stats.StatsBlock[24].StatValue; |
286 | m_totalMeshes = stats.StatsBlock[25].StatValue; | 286 | // m_totalMeshes = stats.StatsBlock[25].StatValue; |
287 | m_inUseThreads = stats.StatsBlock[26].StatValue; | 287 | // m_inUseThreads = stats.StatsBlock[26].StatValue; |
288 | } | 288 | } |
289 | 289 | ||
290 | /// <summary> | 290 | /// <summary> |
diff --git a/OpenSim/Framework/Servers/HttpServer/PollServiceRequestManager.cs b/OpenSim/Framework/Servers/HttpServer/PollServiceRequestManager.cs index 571e8d8..0e4323a 100644 --- a/OpenSim/Framework/Servers/HttpServer/PollServiceRequestManager.cs +++ b/OpenSim/Framework/Servers/HttpServer/PollServiceRequestManager.cs | |||
@@ -44,25 +44,6 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
44 | { | 44 | { |
45 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 45 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
46 | 46 | ||
47 | /// <summary> | ||
48 | /// Is the poll service request manager running? | ||
49 | /// </summary> | ||
50 | /// <remarks> | ||
51 | /// Can be running either synchronously or asynchronously | ||
52 | /// </remarks> | ||
53 | public bool IsRunning { get; private set; } | ||
54 | |||
55 | /// <summary> | ||
56 | /// Is the poll service performing responses asynchronously (with its own threads) or synchronously (via | ||
57 | /// external calls)? | ||
58 | /// </summary> | ||
59 | public bool PerformResponsesAsync { get; private set; } | ||
60 | |||
61 | /// <summary> | ||
62 | /// Number of responses actually processed and sent to viewer (or aborted due to error). | ||
63 | /// </summary> | ||
64 | public int ResponsesProcessed { get; private set; } | ||
65 | |||
66 | private readonly BaseHttpServer m_server; | 47 | private readonly BaseHttpServer m_server; |
67 | 48 | ||
68 | private Dictionary<PollServiceHttpRequest, Queue<PollServiceHttpRequest>> m_bycontext; | 49 | private Dictionary<PollServiceHttpRequest, Queue<PollServiceHttpRequest>> m_bycontext; |
@@ -74,7 +55,7 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
74 | private Thread[] m_workerThreads; | 55 | private Thread[] m_workerThreads; |
75 | private Thread m_retrysThread; | 56 | private Thread m_retrysThread; |
76 | 57 | ||
77 | private bool m_running = true; | 58 | private bool m_running = false; |
78 | private int slowCount = 0; | 59 | private int slowCount = 0; |
79 | 60 | ||
80 | private SmartThreadPool m_threadPool; | 61 | private SmartThreadPool m_threadPool; |
@@ -84,37 +65,9 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
84 | BaseHttpServer pSrv, bool performResponsesAsync, uint pWorkerThreadCount, int pTimeout) | 65 | BaseHttpServer pSrv, bool performResponsesAsync, uint pWorkerThreadCount, int pTimeout) |
85 | { | 66 | { |
86 | m_server = pSrv; | 67 | m_server = pSrv; |
87 | PerformResponsesAsync = performResponsesAsync; | ||
88 | m_WorkerThreadCount = pWorkerThreadCount; | 68 | m_WorkerThreadCount = pWorkerThreadCount; |
89 | m_workerThreads = new Thread[m_WorkerThreadCount]; | 69 | m_workerThreads = new Thread[m_WorkerThreadCount]; |
90 | 70 | ||
91 | /* | ||
92 | StatsManager.RegisterStat( | ||
93 | new Stat( | ||
94 | "QueuedPollResponses", | ||
95 | "Number of poll responses queued for processing.", | ||
96 | "", | ||
97 | "", | ||
98 | "httpserver", | ||
99 | m_server.Port.ToString(), | ||
100 | StatType.Pull, | ||
101 | MeasuresOfInterest.AverageChangeOverTime, | ||
102 | stat => stat.Value = m_requests.Count(), | ||
103 | StatVerbosity.Debug)); | ||
104 | |||
105 | StatsManager.RegisterStat( | ||
106 | new Stat( | ||
107 | "ProcessedPollResponses", | ||
108 | "Number of poll responses processed.", | ||
109 | "", | ||
110 | "", | ||
111 | "httpserver", | ||
112 | m_server.Port.ToString(), | ||
113 | StatType.Pull, | ||
114 | MeasuresOfInterest.AverageChangeOverTime, | ||
115 | stat => stat.Value = ResponsesProcessed, | ||
116 | StatVerbosity.Debug)); | ||
117 | */ | ||
118 | PollServiceHttpRequestComparer preqCp = new PollServiceHttpRequestComparer(); | 71 | PollServiceHttpRequestComparer preqCp = new PollServiceHttpRequestComparer(); |
119 | m_bycontext = new Dictionary<PollServiceHttpRequest, Queue<PollServiceHttpRequest>>(preqCp); | 72 | m_bycontext = new Dictionary<PollServiceHttpRequest, Queue<PollServiceHttpRequest>>(preqCp); |
120 | 73 | ||
@@ -127,10 +80,12 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
127 | startInfo.ThreadPoolName = "PoolService"; | 80 | startInfo.ThreadPoolName = "PoolService"; |
128 | 81 | ||
129 | m_threadPool = new SmartThreadPool(startInfo); | 82 | m_threadPool = new SmartThreadPool(startInfo); |
83 | |||
130 | } | 84 | } |
131 | 85 | ||
132 | public void Start() | 86 | public void Start() |
133 | { | 87 | { |
88 | m_running = true; | ||
134 | m_threadPool.Start(); | 89 | m_threadPool.Start(); |
135 | //startup worker threads | 90 | //startup worker threads |
136 | for (uint i = 0; i < m_WorkerThreadCount; i++) | 91 | for (uint i = 0; i < m_WorkerThreadCount; i++) |
@@ -154,12 +109,13 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
154 | true, | 109 | true, |
155 | null, | 110 | null, |
156 | 1000 * 60 * 10); | 111 | 1000 * 60 * 10); |
112 | |||
157 | 113 | ||
158 | } | 114 | } |
159 | 115 | ||
160 | private void ReQueueEvent(PollServiceHttpRequest req) | 116 | private void ReQueueEvent(PollServiceHttpRequest req) |
161 | { | 117 | { |
162 | if (IsRunning) | 118 | if (m_running) |
163 | { | 119 | { |
164 | lock (m_retryRequests) | 120 | lock (m_retryRequests) |
165 | m_retryRequests.Enqueue(req); | 121 | m_retryRequests.Enqueue(req); |
@@ -207,7 +163,7 @@ namespace OpenSim.Framework.Servers.HttpServer | |||
207 | 163 | ||
208 | public void EnqueueInt(PollServiceHttpRequest req) | 164 | public void EnqueueInt(PollServiceHttpRequest req) |
209 | { | 165 | { |
210 | if (IsRunning) | 166 | if (m_running) |
211 | { | 167 | { |
212 | if (req.PollServiceArgs.Type != PollServiceEventArgs.EventType.LongPoll) | 168 | if (req.PollServiceArgs.Type != PollServiceEventArgs.EventType.LongPoll) |
213 | { | 169 | { |
diff --git a/OpenSim/Framework/VersionInfo.cs b/OpenSim/Framework/VersionInfo.cs index f0ea96f..165b2b4 100644 --- a/OpenSim/Framework/VersionInfo.cs +++ b/OpenSim/Framework/VersionInfo.cs | |||
@@ -29,7 +29,7 @@ namespace OpenSim | |||
29 | { | 29 | { |
30 | public class VersionInfo | 30 | public class VersionInfo |
31 | { | 31 | { |
32 | public const string VersionNumber = "0.8.2.0CM"; | 32 | public const string VersionNumber = "0.8.2.0"; |
33 | private const Flavour VERSION_FLAVOUR = Flavour.Dev; | 33 | private const Flavour VERSION_FLAVOUR = Flavour.Dev; |
34 | 34 | ||
35 | public enum Flavour | 35 | public enum Flavour |
diff --git a/OpenSim/Framework/WebUtil.cs b/OpenSim/Framework/WebUtil.cs index 44d9318..f834baa 100644 --- a/OpenSim/Framework/WebUtil.cs +++ b/OpenSim/Framework/WebUtil.cs | |||
@@ -86,7 +86,7 @@ namespace OpenSim.Framework | |||
86 | /// Number of milliseconds a call can take before it is considered | 86 | /// Number of milliseconds a call can take before it is considered |
87 | /// a "long" call for warning & debugging purposes | 87 | /// a "long" call for warning & debugging purposes |
88 | /// </summary> | 88 | /// </summary> |
89 | public const int LongCallTime = 500; | 89 | public const int LongCallTime = 3000; |
90 | 90 | ||
91 | /// <summary> | 91 | /// <summary> |
92 | /// The maximum length of any data logged because of a long request time. | 92 | /// The maximum length of any data logged because of a long request time. |
@@ -418,7 +418,7 @@ namespace OpenSim.Framework | |||
418 | /// </summary> | 418 | /// </summary> |
419 | public static OSDMap PostToService(string url, NameValueCollection data) | 419 | public static OSDMap PostToService(string url, NameValueCollection data) |
420 | { | 420 | { |
421 | return ServiceFormRequest(url,data, 20000); | 421 | return ServiceFormRequest(url,data, 30000); |
422 | } | 422 | } |
423 | 423 | ||
424 | public static OSDMap ServiceFormRequest(string url, NameValueCollection data, int timeout) | 424 | public static OSDMap ServiceFormRequest(string url, NameValueCollection data, int timeout) |
@@ -808,7 +808,7 @@ namespace OpenSim.Framework | |||
808 | /// <param name="requestUrl"></param> | 808 | /// <param name="requestUrl"></param> |
809 | /// <param name="obj"></param> | 809 | /// <param name="obj"></param> |
810 | /// <param name="pTimeout"> | 810 | /// <param name="pTimeout"> |
811 | /// Request timeout in milliseconds. Timeout.Infinite indicates no timeout. If 0 is passed then the default HttpWebRequest timeout is used (100 seconds) | 811 | /// Request timeout in seconds. Timeout.Infinite indicates no timeout. If 0 is passed then the default HttpWebRequest timeout is used (100 seconds) |
812 | /// </param> | 812 | /// </param> |
813 | /// <param name="maxConnections"></param> | 813 | /// <param name="maxConnections"></param> |
814 | /// <returns> | 814 | /// <returns> |
@@ -877,7 +877,7 @@ namespace OpenSim.Framework | |||
877 | requestStream.Write(data, 0, length); | 877 | requestStream.Write(data, 0, length); |
878 | 878 | ||
879 | // capture how much time was spent writing | 879 | // capture how much time was spent writing |
880 | // tickdata = Util.EnvironmentTickCountSubtract(tickstart); | 880 | tickdata = Util.EnvironmentTickCountSubtract(tickstart); |
881 | 881 | ||
882 | request.BeginGetResponse(delegate(IAsyncResult ar) | 882 | request.BeginGetResponse(delegate(IAsyncResult ar) |
883 | { | 883 | { |
@@ -992,9 +992,9 @@ namespace OpenSim.Framework | |||
992 | } | 992 | } |
993 | else if (WebUtil.DebugLevel >= 4) | 993 | else if (WebUtil.DebugLevel >= 4) |
994 | { | 994 | { |
995 | m_log.DebugFormat( | 995 | m_log.DebugFormat("[LOGHTTP]: HTTP OUT {0} took {1}ms, {2}ms writing", |
996 | "[WEB UTIL]: HTTP OUT {0} took {1}ms", | 996 | |
997 | reqnum, tickdiff); | 997 | reqnum, tickdiff, tickdata); |
998 | } | 998 | } |
999 | } | 999 | } |
1000 | finally | 1000 | finally |
@@ -1054,8 +1054,6 @@ namespace OpenSim.Framework | |||
1054 | { | 1054 | { |
1055 | writer.Write(obj); | 1055 | writer.Write(obj); |
1056 | writer.Flush(); | 1056 | writer.Flush(); |
1057 | if (WebUtil.DebugLevel >= 5) | ||
1058 | WebUtil.LogOutgoingDetail(buffer); | ||
1059 | } | 1057 | } |
1060 | 1058 | ||
1061 | length = (int)obj.Length; | 1059 | length = (int)obj.Length; |
@@ -1248,7 +1246,7 @@ namespace OpenSim.Framework | |||
1248 | auth.AddAuthorization(ht.Headers); | 1246 | auth.AddAuthorization(ht.Headers); |
1249 | 1247 | ||
1250 | if (pTimeout != 0) | 1248 | if (pTimeout != 0) |
1251 | ht.Timeout = pTimeout; | 1249 | request.Timeout = pTimeout * 1000; |
1252 | 1250 | ||
1253 | if (maxConnections > 0 && ht.ServicePoint.ConnectionLimit < maxConnections) | 1251 | if (maxConnections > 0 && ht.ServicePoint.ConnectionLimit < maxConnections) |
1254 | ht.ServicePoint.ConnectionLimit = maxConnections; | 1252 | ht.ServicePoint.ConnectionLimit = maxConnections; |