diff options
author | Justin Clarke Casey | 2009-04-14 18:49:45 +0000 |
---|---|---|
committer | Justin Clarke Casey | 2009-04-14 18:49:45 +0000 |
commit | d0744f8eca6adc2b6ae257f581792bd8eae16ea2 (patch) | |
tree | c6fe087005bb4d1a0ccf7ded71b611cec721a817 /OpenSim/Region | |
parent | Fix for minor bug introduced yesterday, HG only. Can't lookup the profile whe... (diff) | |
download | opensim-SC_OLD-d0744f8eca6adc2b6ae257f581792bd8eae16ea2.zip opensim-SC_OLD-d0744f8eca6adc2b6ae257f581792bd8eae16ea2.tar.gz opensim-SC_OLD-d0744f8eca6adc2b6ae257f581792bd8eae16ea2.tar.bz2 opensim-SC_OLD-d0744f8eca6adc2b6ae257f581792bd8eae16ea2.tar.xz |
* Make archiver tests pump the asset server manually instead of starting the normal runtime thread
* This may eliminate the occasional archive test freezes, since they appeared to occur when somehow the asset server didn't pick up on the presence of a request in the asset
quque
Diffstat (limited to 'OpenSim/Region')
4 files changed, 13 insertions, 4 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/Tests/InventoryArchiverTests.cs b/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/Tests/InventoryArchiverTests.cs index c140ec0..01e5ae0 100644 --- a/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/Tests/InventoryArchiverTests.cs +++ b/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/Tests/InventoryArchiverTests.cs | |||
@@ -67,7 +67,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver.Tests | |||
67 | 67 | ||
68 | InventoryArchiverModule archiverModule = new InventoryArchiverModule(); | 68 | InventoryArchiverModule archiverModule = new InventoryArchiverModule(); |
69 | 69 | ||
70 | Scene scene = SceneSetupHelpers.SetupScene(); | 70 | Scene scene = SceneSetupHelpers.SetupScene(false); |
71 | SceneSetupHelpers.SetupSceneModules(scene, archiverModule); | 71 | SceneSetupHelpers.SetupSceneModules(scene, archiverModule); |
72 | CommunicationsManager cm = scene.CommsManager; | 72 | CommunicationsManager cm = scene.CommsManager; |
73 | 73 | ||
@@ -119,6 +119,10 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver.Tests | |||
119 | lock (this) | 119 | lock (this) |
120 | { | 120 | { |
121 | archiverModule.ArchiveInventory(userFirstName, userLastName, "Objects", archiveWriteStream); | 121 | archiverModule.ArchiveInventory(userFirstName, userLastName, "Objects", archiveWriteStream); |
122 | AssetServerBase assetServer = (AssetServerBase)scene.CommsManager.AssetCache.AssetServer; | ||
123 | while (assetServer.HasWaitingRequests()) | ||
124 | assetServer.ProcessNextRequest(); | ||
125 | |||
122 | Monitor.Wait(this, 60000); | 126 | Monitor.Wait(this, 60000); |
123 | } | 127 | } |
124 | 128 | ||
diff --git a/OpenSim/Region/CoreModules/World/Archiver/Tests/ArchiverTests.cs b/OpenSim/Region/CoreModules/World/Archiver/Tests/ArchiverTests.cs index 04c3289..165a607 100644 --- a/OpenSim/Region/CoreModules/World/Archiver/Tests/ArchiverTests.cs +++ b/OpenSim/Region/CoreModules/World/Archiver/Tests/ArchiverTests.cs | |||
@@ -34,6 +34,7 @@ using NUnit.Framework; | |||
34 | using NUnit.Framework.SyntaxHelpers; | 34 | using NUnit.Framework.SyntaxHelpers; |
35 | using OpenMetaverse; | 35 | using OpenMetaverse; |
36 | using OpenSim.Framework; | 36 | using OpenSim.Framework; |
37 | using OpenSim.Framework.Communications.Cache; | ||
37 | using OpenSim.Framework.Serialization; | 38 | using OpenSim.Framework.Serialization; |
38 | using OpenSim.Region.CoreModules.World.Serialiser; | 39 | using OpenSim.Region.CoreModules.World.Serialiser; |
39 | using OpenSim.Region.CoreModules.World.Terrain; | 40 | using OpenSim.Region.CoreModules.World.Terrain; |
@@ -67,7 +68,7 @@ namespace OpenSim.Region.CoreModules.World.Archiver.Tests | |||
67 | SerialiserModule serialiserModule = new SerialiserModule(); | 68 | SerialiserModule serialiserModule = new SerialiserModule(); |
68 | TerrainModule terrainModule = new TerrainModule(); | 69 | TerrainModule terrainModule = new TerrainModule(); |
69 | 70 | ||
70 | Scene scene = SceneSetupHelpers.SetupScene(); | 71 | Scene scene = SceneSetupHelpers.SetupScene(false); |
71 | SceneSetupHelpers.SetupSceneModules(scene, archiverModule, serialiserModule, terrainModule); | 72 | SceneSetupHelpers.SetupSceneModules(scene, archiverModule, serialiserModule, terrainModule); |
72 | 73 | ||
73 | SceneObjectPart part1; | 74 | SceneObjectPart part1; |
@@ -114,6 +115,10 @@ namespace OpenSim.Region.CoreModules.World.Archiver.Tests | |||
114 | lock (this) | 115 | lock (this) |
115 | { | 116 | { |
116 | archiverModule.ArchiveRegion(archiveWriteStream); | 117 | archiverModule.ArchiveRegion(archiveWriteStream); |
118 | AssetServerBase assetServer = (AssetServerBase)scene.CommsManager.AssetCache.AssetServer; | ||
119 | while (assetServer.HasWaitingRequests()) | ||
120 | assetServer.ProcessNextRequest(); | ||
121 | |||
117 | Monitor.Wait(this, 60000); | 122 | Monitor.Wait(this, 60000); |
118 | } | 123 | } |
119 | 124 | ||
diff --git a/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceTests.cs b/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceTests.cs index c781305..c00ef3c 100644 --- a/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceTests.cs +++ b/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceTests.cs | |||
@@ -57,7 +57,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
57 | public UUID agent1, agent2, agent3; | 57 | public UUID agent1, agent2, agent3; |
58 | public static Random random; | 58 | public static Random random; |
59 | public ulong region1,region2,region3; | 59 | public ulong region1,region2,region3; |
60 | public CommunicationsManager cm; | 60 | public TestCommunicationsManager cm; |
61 | public AgentCircuitData acd1; | 61 | public AgentCircuitData acd1; |
62 | public SceneObjectGroup sog1, sog2, sog3; | 62 | public SceneObjectGroup sog1, sog2, sog3; |
63 | public TestClient testclient; | 63 | public TestClient testclient; |
diff --git a/OpenSim/Region/Framework/Scenes/Tests/StandaloneTeleportTests.cs b/OpenSim/Region/Framework/Scenes/Tests/StandaloneTeleportTests.cs index 80d2ba9..a0c956e 100644 --- a/OpenSim/Region/Framework/Scenes/Tests/StandaloneTeleportTests.cs +++ b/OpenSim/Region/Framework/Scenes/Tests/StandaloneTeleportTests.cs | |||
@@ -60,7 +60,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
60 | 60 | ||
61 | UUID sceneAId = UUID.Parse("00000000-0000-0000-0000-000000000100"); | 61 | UUID sceneAId = UUID.Parse("00000000-0000-0000-0000-000000000100"); |
62 | UUID sceneBId = UUID.Parse("00000000-0000-0000-0000-000000000200"); | 62 | UUID sceneBId = UUID.Parse("00000000-0000-0000-0000-000000000200"); |
63 | CommunicationsManager cm = new TestCommunicationsManager(); | 63 | TestCommunicationsManager cm = new TestCommunicationsManager(); |
64 | 64 | ||
65 | // shared module | 65 | // shared module |
66 | IRegionModule interregionComms = new RESTInterregionComms(); | 66 | IRegionModule interregionComms = new RESTInterregionComms(); |