aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorsacha2010-04-23 12:40:27 -0400
committersacha2010-04-23 12:40:27 -0400
commit85646b157ce0e07ef37e41de72b553bb377243e1 (patch)
tree720679b200cc529069b6c12f77bd392b5dac28de /OpenSim/Region
parentAdding LinkUp/LinkDown when a region is started or stoped. (diff)
downloadopensim-SC-85646b157ce0e07ef37e41de72b553bb377243e1.zip
opensim-SC-85646b157ce0e07ef37e41de72b553bb377243e1.tar.gz
opensim-SC-85646b157ce0e07ef37e41de72b553bb377243e1.tar.bz2
opensim-SC-85646b157ce0e07ef37e41de72b553bb377243e1.tar.xz
Adding some more SNMP events and some refactoring
Signed : The Masqued Foxi
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/Application/OpenSimBase.cs21
-rw-r--r--OpenSim/Region/Framework/Interfaces/ISnmpModule.cs1
2 files changed, 14 insertions, 8 deletions
diff --git a/OpenSim/Region/Application/OpenSimBase.cs b/OpenSim/Region/Application/OpenSimBase.cs
index 06bb886..1ec96a0 100644
--- a/OpenSim/Region/Application/OpenSimBase.cs
+++ b/OpenSim/Region/Application/OpenSimBase.cs
@@ -355,7 +355,7 @@ namespace OpenSim
355 355
356 if (scene.SnmpService != null) 356 if (scene.SnmpService != null)
357 { 357 {
358 scene.SnmpService.Warning("Loading prins", scene); 358 scene.SnmpService.BootInfo("Loading prins", scene);
359 } 359 }
360 360
361 // Prims have to be loaded after module configuration since some modules may be invoked during the load 361 // Prims have to be loaded after module configuration since some modules may be invoked during the load
@@ -363,7 +363,7 @@ namespace OpenSim
363 363
364 if (scene.SnmpService != null) 364 if (scene.SnmpService != null)
365 { 365 {
366 scene.SnmpService.Warning("Creating region texture", scene); 366 scene.SnmpService.BootInfo("Creating region texture", scene);
367 } 367 }
368 368
369 // moved these here as the terrain texture has to be created after the modules are initialized 369 // moved these here as the terrain texture has to be created after the modules are initialized
@@ -375,8 +375,8 @@ namespace OpenSim
375 375
376 if (scene.SnmpService != null) 376 if (scene.SnmpService != null)
377 { 377 {
378 scene.SnmpService.Warning("Grid Registration in progress", scene); 378 scene.SnmpService.BootInfo("Grid Registration in progress", scene);
379 } 379 }
380 try 380 try
381 { 381 {
382 scene.RegisterRegionWithGrid(); 382 scene.RegisterRegionWithGrid();
@@ -396,7 +396,7 @@ namespace OpenSim
396 396
397 if (scene.SnmpService != null) 397 if (scene.SnmpService != null)
398 { 398 {
399 scene.SnmpService.Warning("Grid Registration done", scene); 399 scene.SnmpService.BootInfo("Grid Registration done", scene);
400 } 400 }
401 401
402 // We need to do this after we've initialized the 402 // We need to do this after we've initialized the
@@ -408,7 +408,7 @@ namespace OpenSim
408 408
409 if (scene.SnmpService != null) 409 if (scene.SnmpService != null)
410 { 410 {
411 scene.SnmpService.Warning("ScriptEngine started", scene); 411 scene.SnmpService.BootInfo("ScriptEngine started", scene);
412 } 412 }
413 413
414 m_sceneManager.Add(scene); 414 m_sceneManager.Add(scene);
@@ -421,7 +421,7 @@ namespace OpenSim
421 421
422 if (scene.SnmpService != null) 422 if (scene.SnmpService != null)
423 { 423 {
424 scene.SnmpService.Warning("Initializing region modules", scene); 424 scene.SnmpService.BootInfo("Initializing region modules", scene);
425 } 425 }
426 if (do_post_init) 426 if (do_post_init)
427 { 427 {
@@ -436,7 +436,7 @@ namespace OpenSim
436 436
437 if (scene.SnmpService != null) 437 if (scene.SnmpService != null)
438 { 438 {
439 scene.SnmpService.Warning("The region is operational", scene); 439 scene.SnmpService.BootInfo("The region is operational", scene);
440 scene.SnmpService.LinkUp(scene); 440 scene.SnmpService.LinkUp(scene);
441 } 441 }
442 442
@@ -448,6 +448,11 @@ namespace OpenSim
448 private void ShutdownRegion(Scene scene) 448 private void ShutdownRegion(Scene scene)
449 { 449 {
450 m_log.DebugFormat("[SHUTDOWN]: Shutting down region {0}", scene.RegionInfo.RegionName); 450 m_log.DebugFormat("[SHUTDOWN]: Shutting down region {0}", scene.RegionInfo.RegionName);
451 if (scene.SnmpService != null)
452 {
453 scene.SnmpService.BootInfo("The region is shutting down", scene);
454 scene.SnmpService.LinkDown(scene);
455 }
451 IRegionModulesController controller; 456 IRegionModulesController controller;
452 if (ApplicationRegistry.TryGet<IRegionModulesController>(out controller)) 457 if (ApplicationRegistry.TryGet<IRegionModulesController>(out controller))
453 { 458 {
diff --git a/OpenSim/Region/Framework/Interfaces/ISnmpModule.cs b/OpenSim/Region/Framework/Interfaces/ISnmpModule.cs
index cc31322..16a243c 100644
--- a/OpenSim/Region/Framework/Interfaces/ISnmpModule.cs
+++ b/OpenSim/Region/Framework/Interfaces/ISnmpModule.cs
@@ -20,4 +20,5 @@ public interface ISnmpModule
20 // 20 //
21 void LinkUp(Scene scene); 21 void LinkUp(Scene scene);
22 void LinkDown(Scene scene); 22 void LinkDown(Scene scene);
23 void BootInfo(string data, Scene scene);
23} 24}