diff options
Heart surgery on asset service code bits. Affects OpenSim.ini configuration -- please see the example. Affects region servers only.
This may break a lot of things, but it needs to go in. It was tested in standalone and the UCI grid, but it needs a lot more testing.
Known problems:
* HG asset transfers are borked for now
* missing texture is missing
* 3 unit tests commented out for now
Diffstat (limited to 'OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs')
-rw-r--r-- | OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs b/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs index b0c1d0b..ca731d5 100644 --- a/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs +++ b/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveReadRequest.cs | |||
@@ -41,6 +41,7 @@ using OpenSim.Framework.Communications.Osp; | |||
41 | using OpenSim.Framework.Serialization; | 41 | using OpenSim.Framework.Serialization; |
42 | using OpenSim.Framework.Serialization.External; | 42 | using OpenSim.Framework.Serialization.External; |
43 | using OpenSim.Region.CoreModules.World.Archiver; | 43 | using OpenSim.Region.CoreModules.World.Archiver; |
44 | using OpenSim.Services.Interfaces; | ||
44 | 45 | ||
45 | namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver | 46 | namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver |
46 | { | 47 | { |
@@ -59,24 +60,26 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver | |||
59 | private Stream m_loadStream; | 60 | private Stream m_loadStream; |
60 | 61 | ||
61 | protected CommunicationsManager m_commsManager; | 62 | protected CommunicationsManager m_commsManager; |
63 | protected IAssetService m_assetService; | ||
62 | 64 | ||
63 | public InventoryArchiveReadRequest( | 65 | public InventoryArchiveReadRequest( |
64 | CachedUserInfo userInfo, string invPath, string loadPath, CommunicationsManager commsManager) | 66 | CachedUserInfo userInfo, string invPath, string loadPath, CommunicationsManager commsManager, IAssetService assetService) |
65 | : this( | 67 | : this( |
66 | userInfo, | 68 | userInfo, |
67 | invPath, | 69 | invPath, |
68 | new GZipStream(new FileStream(loadPath, FileMode.Open), CompressionMode.Decompress), | 70 | new GZipStream(new FileStream(loadPath, FileMode.Open), CompressionMode.Decompress), |
69 | commsManager) | 71 | commsManager, assetService) |
70 | { | 72 | { |
71 | } | 73 | } |
72 | 74 | ||
73 | public InventoryArchiveReadRequest( | 75 | public InventoryArchiveReadRequest( |
74 | CachedUserInfo userInfo, string invPath, Stream loadStream, CommunicationsManager commsManager) | 76 | CachedUserInfo userInfo, string invPath, Stream loadStream, CommunicationsManager commsManager, IAssetService assetService) |
75 | { | 77 | { |
76 | m_userInfo = userInfo; | 78 | m_userInfo = userInfo; |
77 | m_invPath = invPath; | 79 | m_invPath = invPath; |
78 | m_loadStream = loadStream; | 80 | m_loadStream = loadStream; |
79 | m_commsManager = commsManager; | 81 | m_commsManager = commsManager; |
82 | m_assetService = assetService; | ||
80 | } | 83 | } |
81 | 84 | ||
82 | /// <summary> | 85 | /// <summary> |
@@ -356,7 +359,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver | |||
356 | asset.Type = assetType; | 359 | asset.Type = assetType; |
357 | asset.Data = data; | 360 | asset.Data = data; |
358 | 361 | ||
359 | m_commsManager.AssetCache.AddAsset(asset); | 362 | m_assetService.Store(asset); |
360 | 363 | ||
361 | return true; | 364 | return true; |
362 | } | 365 | } |