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/Agent/AssetTransaction')
-rw-r--r-- | OpenSim/Region/CoreModules/Agent/AssetTransaction/AgentAssetsTransactions.cs | 9 | ||||
-rw-r--r-- | OpenSim/Region/CoreModules/Agent/AssetTransaction/AssetXferUploader.cs | 4 |
2 files changed, 6 insertions, 7 deletions
diff --git a/OpenSim/Region/CoreModules/Agent/AssetTransaction/AgentAssetsTransactions.cs b/OpenSim/Region/CoreModules/Agent/AssetTransaction/AgentAssetsTransactions.cs index eefcfe8..94140fc 100644 --- a/OpenSim/Region/CoreModules/Agent/AssetTransaction/AgentAssetsTransactions.cs +++ b/OpenSim/Region/CoreModules/Agent/AssetTransaction/AgentAssetsTransactions.cs | |||
@@ -32,6 +32,7 @@ using OpenMetaverse; | |||
32 | using OpenSim.Framework; | 32 | using OpenSim.Framework; |
33 | using OpenSim.Framework.Communications.Cache; | 33 | using OpenSim.Framework.Communications.Cache; |
34 | using OpenSim.Region.Framework.Scenes; | 34 | using OpenSim.Region.Framework.Scenes; |
35 | using OpenSim.Services.Interfaces; | ||
35 | 36 | ||
36 | namespace OpenSim.Region.CoreModules.Agent.AssetTransaction | 37 | namespace OpenSim.Region.CoreModules.Agent.AssetTransaction |
37 | { | 38 | { |
@@ -177,7 +178,7 @@ namespace OpenSim.Region.CoreModules.Agent.AssetTransaction | |||
177 | asset.Type = (sbyte)item.Type; | 178 | asset.Type = (sbyte)item.Type; |
178 | item.AssetID = asset.FullID; | 179 | item.AssetID = asset.FullID; |
179 | 180 | ||
180 | Manager.MyScene.CommsManager.AssetCache.AddAsset(asset); | 181 | Manager.MyScene.AssetService.Store(asset); |
181 | 182 | ||
182 | if (part.Inventory.UpdateInventoryItem(item)) | 183 | if (part.Inventory.UpdateInventoryItem(item)) |
183 | part.GetProperties(remoteClient); | 184 | part.GetProperties(remoteClient); |
@@ -198,9 +199,7 @@ namespace OpenSim.Region.CoreModules.Agent.AssetTransaction | |||
198 | { | 199 | { |
199 | UUID assetID = UUID.Combine(transactionID, remoteClient.SecureSessionId); | 200 | UUID assetID = UUID.Combine(transactionID, remoteClient.SecureSessionId); |
200 | 201 | ||
201 | AssetBase asset | 202 | AssetBase asset = Manager.MyScene.AssetService.Get(assetID.ToString()); |
202 | = Manager.MyScene.CommsManager.AssetCache.GetAsset( | ||
203 | assetID, (item.AssetType == (int)AssetType.Texture ? true : false)); | ||
204 | 203 | ||
205 | if (asset == null) | 204 | if (asset == null) |
206 | { | 205 | { |
@@ -216,7 +215,7 @@ namespace OpenSim.Region.CoreModules.Agent.AssetTransaction | |||
216 | asset.Type = (sbyte)item.AssetType; | 215 | asset.Type = (sbyte)item.AssetType; |
217 | item.AssetID = asset.FullID; | 216 | item.AssetID = asset.FullID; |
218 | 217 | ||
219 | Manager.MyScene.CommsManager.AssetCache.AddAsset(asset); | 218 | Manager.MyScene.AssetService.Store(asset); |
220 | } | 219 | } |
221 | 220 | ||
222 | userInfo.UpdateItem(item); | 221 | userInfo.UpdateItem(item); |
diff --git a/OpenSim/Region/CoreModules/Agent/AssetTransaction/AssetXferUploader.cs b/OpenSim/Region/CoreModules/Agent/AssetTransaction/AssetXferUploader.cs index a8e5ae3..6044949 100644 --- a/OpenSim/Region/CoreModules/Agent/AssetTransaction/AssetXferUploader.cs +++ b/OpenSim/Region/CoreModules/Agent/AssetTransaction/AssetXferUploader.cs | |||
@@ -153,7 +153,7 @@ namespace OpenSim.Region.CoreModules.Agent.AssetTransaction | |||
153 | } | 153 | } |
154 | else if (m_storeLocal) | 154 | else if (m_storeLocal) |
155 | { | 155 | { |
156 | m_userTransactions.Manager.MyScene.CommsManager.AssetCache.AddAsset(m_asset); | 156 | m_userTransactions.Manager.MyScene.AssetService.Store(m_asset); |
157 | } | 157 | } |
158 | 158 | ||
159 | m_log.DebugFormat("[ASSET TRANSACTIONS]: Uploaded asset data for transaction {0}", TransactionID); | 159 | m_log.DebugFormat("[ASSET TRANSACTIONS]: Uploaded asset data for transaction {0}", TransactionID); |
@@ -213,7 +213,7 @@ namespace OpenSim.Region.CoreModules.Agent.AssetTransaction | |||
213 | 213 | ||
214 | private void DoCreateItem(uint callbackID) | 214 | private void DoCreateItem(uint callbackID) |
215 | { | 215 | { |
216 | m_userTransactions.Manager.MyScene.CommsManager.AssetCache.AddAsset(m_asset); | 216 | m_userTransactions.Manager.MyScene.AssetService.Store(m_asset); |
217 | CachedUserInfo userInfo = | 217 | CachedUserInfo userInfo = |
218 | m_userTransactions.Manager.MyScene.CommsManager.UserProfileCacheService.GetUserDetails( | 218 | m_userTransactions.Manager.MyScene.CommsManager.UserProfileCacheService.GetUserDetails( |
219 | ourClient.AgentId); | 219 | ourClient.AgentId); |