diff options
author | Melanie | 2010-04-27 03:58:43 +0100 |
---|---|---|
committer | Melanie | 2010-04-27 03:58:43 +0100 |
commit | 8a32ee7dd2f2a49b510e7743ae908cace3dd7899 (patch) | |
tree | 80ae806cdff9eae5673e97d71816d244e9460800 /OpenSim | |
parent | Merge branch 'master' into careminster-presence-refactor (diff) | |
parent | Adding some more SNMP events and some refactoring (diff) | |
download | opensim-SC_OLD-8a32ee7dd2f2a49b510e7743ae908cace3dd7899.zip opensim-SC_OLD-8a32ee7dd2f2a49b510e7743ae908cace3dd7899.tar.gz opensim-SC_OLD-8a32ee7dd2f2a49b510e7743ae908cace3dd7899.tar.bz2 opensim-SC_OLD-8a32ee7dd2f2a49b510e7743ae908cace3dd7899.tar.xz |
Merge branch 'careminster' into careminster-presence-refactor
Diffstat (limited to 'OpenSim')
-rw-r--r-- | OpenSim/Region/Application/OpenSimBase.cs | 26 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Interfaces/ISnmpModule.cs | 6 |
2 files changed, 21 insertions, 11 deletions
diff --git a/OpenSim/Region/Application/OpenSimBase.cs b/OpenSim/Region/Application/OpenSimBase.cs index 831269c..ba2c2de 100644 --- a/OpenSim/Region/Application/OpenSimBase.cs +++ b/OpenSim/Region/Application/OpenSimBase.cs | |||
@@ -347,14 +347,12 @@ namespace OpenSim | |||
347 | if (scene.SnmpService != null) | 347 | if (scene.SnmpService != null) |
348 | { | 348 | { |
349 | scene.SnmpService.ColdStart(1,scene); | 349 | scene.SnmpService.ColdStart(1,scene); |
350 | scene.SnmpService.LinkDown(scene); | ||
350 | } | 351 | } |
351 | 352 | ||
352 | // it should be a LinkDown event | ||
353 | // Maped inside opennms | ||
354 | // bad... | ||
355 | if (scene.SnmpService != null) | 353 | if (scene.SnmpService != null) |
356 | { | 354 | { |
357 | scene.SnmpService.Warning("Loading prins", scene); | 355 | scene.SnmpService.BootInfo("Loading prins", scene); |
358 | } | 356 | } |
359 | 357 | ||
360 | // Prims have to be loaded after module configuration since some modules may be invoked during the load | 358 | // Prims have to be loaded after module configuration since some modules may be invoked during the load |
@@ -362,7 +360,7 @@ namespace OpenSim | |||
362 | 360 | ||
363 | if (scene.SnmpService != null) | 361 | if (scene.SnmpService != null) |
364 | { | 362 | { |
365 | scene.SnmpService.Warning("Creating region texture", scene); | 363 | scene.SnmpService.BootInfo("Creating region texture", scene); |
366 | } | 364 | } |
367 | 365 | ||
368 | // moved these here as the terrain texture has to be created after the modules are initialized | 366 | // moved these here as the terrain texture has to be created after the modules are initialized |
@@ -374,8 +372,8 @@ namespace OpenSim | |||
374 | 372 | ||
375 | if (scene.SnmpService != null) | 373 | if (scene.SnmpService != null) |
376 | { | 374 | { |
377 | scene.SnmpService.Warning("Grid Registration in progress", scene); | 375 | scene.SnmpService.BootInfo("Grid Registration in progress", scene); |
378 | } | 376 | } |
379 | try | 377 | try |
380 | { | 378 | { |
381 | scene.RegisterRegionWithGrid(); | 379 | scene.RegisterRegionWithGrid(); |
@@ -395,7 +393,7 @@ namespace OpenSim | |||
395 | 393 | ||
396 | if (scene.SnmpService != null) | 394 | if (scene.SnmpService != null) |
397 | { | 395 | { |
398 | scene.SnmpService.Warning("Grid Registration done", scene); | 396 | scene.SnmpService.BootInfo("Grid Registration done", scene); |
399 | } | 397 | } |
400 | 398 | ||
401 | // We need to do this after we've initialized the | 399 | // We need to do this after we've initialized the |
@@ -407,7 +405,7 @@ namespace OpenSim | |||
407 | 405 | ||
408 | if (scene.SnmpService != null) | 406 | if (scene.SnmpService != null) |
409 | { | 407 | { |
410 | scene.SnmpService.Warning("ScriptEngine started", scene); | 408 | scene.SnmpService.BootInfo("ScriptEngine started", scene); |
411 | } | 409 | } |
412 | 410 | ||
413 | m_sceneManager.Add(scene); | 411 | m_sceneManager.Add(scene); |
@@ -420,7 +418,7 @@ namespace OpenSim | |||
420 | 418 | ||
421 | if (scene.SnmpService != null) | 419 | if (scene.SnmpService != null) |
422 | { | 420 | { |
423 | scene.SnmpService.Warning("Initializing region modules", scene); | 421 | scene.SnmpService.BootInfo("Initializing region modules", scene); |
424 | } | 422 | } |
425 | if (do_post_init) | 423 | if (do_post_init) |
426 | { | 424 | { |
@@ -435,7 +433,8 @@ namespace OpenSim | |||
435 | 433 | ||
436 | if (scene.SnmpService != null) | 434 | if (scene.SnmpService != null) |
437 | { | 435 | { |
438 | scene.SnmpService.Warning("The region is operational", scene); | 436 | scene.SnmpService.BootInfo("The region is operational", scene); |
437 | scene.SnmpService.LinkUp(scene); | ||
439 | } | 438 | } |
440 | 439 | ||
441 | scene.StartTimer(); | 440 | scene.StartTimer(); |
@@ -446,6 +445,11 @@ namespace OpenSim | |||
446 | private void ShutdownRegion(Scene scene) | 445 | private void ShutdownRegion(Scene scene) |
447 | { | 446 | { |
448 | m_log.DebugFormat("[SHUTDOWN]: Shutting down region {0}", scene.RegionInfo.RegionName); | 447 | m_log.DebugFormat("[SHUTDOWN]: Shutting down region {0}", scene.RegionInfo.RegionName); |
448 | if (scene.SnmpService != null) | ||
449 | { | ||
450 | scene.SnmpService.BootInfo("The region is shutting down", scene); | ||
451 | scene.SnmpService.LinkDown(scene); | ||
452 | } | ||
449 | IRegionModulesController controller; | 453 | IRegionModulesController controller; |
450 | if (ApplicationRegistry.TryGet<IRegionModulesController>(out controller)) | 454 | if (ApplicationRegistry.TryGet<IRegionModulesController>(out controller)) |
451 | { | 455 | { |
diff --git a/OpenSim/Region/Framework/Interfaces/ISnmpModule.cs b/OpenSim/Region/Framework/Interfaces/ISnmpModule.cs index 8a83fe9..16a243c 100644 --- a/OpenSim/Region/Framework/Interfaces/ISnmpModule.cs +++ b/OpenSim/Region/Framework/Interfaces/ISnmpModule.cs | |||
@@ -15,4 +15,10 @@ public interface ISnmpModule | |||
15 | void Major(string Message, Scene scene); | 15 | void Major(string Message, Scene scene); |
16 | void ColdStart(int step , Scene scene); | 16 | void ColdStart(int step , Scene scene); |
17 | void Shutdown(int step , Scene scene); | 17 | void Shutdown(int step , Scene scene); |
18 | // | ||
19 | // Node Start/stop events | ||
20 | // | ||
21 | void LinkUp(Scene scene); | ||
22 | void LinkDown(Scene scene); | ||
23 | void BootInfo(string data, Scene scene); | ||
18 | } | 24 | } |