diff options
author | Melanie | 2012-02-24 09:56:06 +0000 |
---|---|---|
committer | Melanie | 2012-02-24 09:56:06 +0000 |
commit | 37068d17c5a6a4679f75af12cbbcfc3c78790e33 (patch) | |
tree | 42454c2fd6072b0baebb4f3d7632476de3ad18e9 /OpenSim/Region/Framework | |
parent | Partially apply the core banlines fix (diff) | |
parent | Take watchdog alarm calling back outside the m_threads lock. (diff) | |
download | opensim-SC-37068d17c5a6a4679f75af12cbbcfc3c78790e33.zip opensim-SC-37068d17c5a6a4679f75af12cbbcfc3c78790e33.tar.gz opensim-SC-37068d17c5a6a4679f75af12cbbcfc3c78790e33.tar.bz2 opensim-SC-37068d17c5a6a4679f75af12cbbcfc3c78790e33.tar.xz |
Merge branch 'master' into careminster
Diffstat (limited to 'OpenSim/Region/Framework')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.cs | 30 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs | 4 |
2 files changed, 12 insertions, 22 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index fcbed9f..108f3c8 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -1181,7 +1181,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1181 | 1181 | ||
1182 | HeartbeatThread | 1182 | HeartbeatThread |
1183 | = Watchdog.StartThread( | 1183 | = Watchdog.StartThread( |
1184 | Heartbeat, string.Format("Heartbeat ({0})", RegionInfo.RegionName), ThreadPriority.Normal, false); | 1184 | Heartbeat, string.Format("Heartbeat ({0})", RegionInfo.RegionName), ThreadPriority.Normal, false, false); |
1185 | } | 1185 | } |
1186 | 1186 | ||
1187 | /// <summary> | 1187 | /// <summary> |
@@ -1219,6 +1219,13 @@ namespace OpenSim.Region.Framework.Scenes | |||
1219 | try | 1219 | try |
1220 | { | 1220 | { |
1221 | m_eventManager.TriggerOnRegionStarted(this); | 1221 | m_eventManager.TriggerOnRegionStarted(this); |
1222 | |||
1223 | // The first frame can take a very long time due to physics actors being added on startup. Therefore, | ||
1224 | // don't turn on the watchdog alarm for this thread until the second frame, in order to prevent false | ||
1225 | // alarms for scenes with many objects. | ||
1226 | Update(); | ||
1227 | Watchdog.GetCurrentThreadInfo().AlarmIfTimeout = true; | ||
1228 | |||
1222 | while (!shuttingdown) | 1229 | while (!shuttingdown) |
1223 | Update(); | 1230 | Update(); |
1224 | } | 1231 | } |
@@ -1244,7 +1251,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1244 | 1251 | ||
1245 | ++Frame; | 1252 | ++Frame; |
1246 | 1253 | ||
1247 | // m_log.DebugFormat("[SCENE]: Processing frame {0}", Frame); | 1254 | // m_log.DebugFormat("[SCENE]: Processing frame {0} in {1}", Frame, RegionInfo.RegionName); |
1248 | 1255 | ||
1249 | try | 1256 | try |
1250 | { | 1257 | { |
@@ -1406,26 +1413,10 @@ namespace OpenSim.Region.Framework.Scenes | |||
1406 | { | 1413 | { |
1407 | throw; | 1414 | throw; |
1408 | } | 1415 | } |
1409 | catch (AccessViolationException e) | ||
1410 | { | ||
1411 | m_log.ErrorFormat( | ||
1412 | "[REGION]: Failed on region {0} with exception {1}{2}", | ||
1413 | RegionInfo.RegionName, e.Message, e.StackTrace); | ||
1414 | } | ||
1415 | //catch (NullReferenceException e) | ||
1416 | //{ | ||
1417 | // m_log.Error("[REGION]: Failed with exception " + e.ToString() + " On Region: " + RegionInfo.RegionName); | ||
1418 | //} | ||
1419 | catch (InvalidOperationException e) | ||
1420 | { | ||
1421 | m_log.ErrorFormat( | ||
1422 | "[REGION]: Failed on region {0} with exception {1}{2}", | ||
1423 | RegionInfo.RegionName, e.Message, e.StackTrace); | ||
1424 | } | ||
1425 | catch (Exception e) | 1416 | catch (Exception e) |
1426 | { | 1417 | { |
1427 | m_log.ErrorFormat( | 1418 | m_log.ErrorFormat( |
1428 | "[REGION]: Failed on region {0} with exception {1}{2}", | 1419 | "[SCENE]: Failed on region {0} with exception {1}{2}", |
1429 | RegionInfo.RegionName, e.Message, e.StackTrace); | 1420 | RegionInfo.RegionName, e.Message, e.StackTrace); |
1430 | } | 1421 | } |
1431 | 1422 | ||
@@ -1467,7 +1458,6 @@ namespace OpenSim.Region.Framework.Scenes | |||
1467 | entry.checkAtTargets(); | 1458 | entry.checkAtTargets(); |
1468 | } | 1459 | } |
1469 | 1460 | ||
1470 | |||
1471 | /// <summary> | 1461 | /// <summary> |
1472 | /// Send out simstats data to all clients | 1462 | /// Send out simstats data to all clients |
1473 | /// </summary> | 1463 | /// </summary> |
diff --git a/OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs b/OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs index 65ffe92..b806d91 100644 --- a/OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs +++ b/OpenSim/Region/Framework/Scenes/SceneCommunicationService.cs | |||
@@ -156,8 +156,8 @@ namespace OpenSim.Region.Framework.Scenes | |||
156 | // that the region position is cached or performance will degrade | 156 | // that the region position is cached or performance will degrade |
157 | Utils.LongToUInts(regionHandle, out x, out y); | 157 | Utils.LongToUInts(regionHandle, out x, out y); |
158 | GridRegion dest = m_scene.GridService.GetRegionByPosition(UUID.Zero, (int)x, (int)y); | 158 | GridRegion dest = m_scene.GridService.GetRegionByPosition(UUID.Zero, (int)x, (int)y); |
159 | bool v = true; | 159 | // bool v = true; |
160 | if (! simulatorList.Contains(dest.ServerURI)) | 160 | if (!simulatorList.Contains(dest.ServerURI)) |
161 | { | 161 | { |
162 | // we havent seen this simulator before, add it to the list | 162 | // we havent seen this simulator before, add it to the list |
163 | // and send it an update | 163 | // and send it an update |