aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Communications/Cache/AssetServerBase.cs
diff options
context:
space:
mode:
authorJustin Clarke Casey2008-07-07 19:32:21 +0000
committerJustin Clarke Casey2008-07-07 19:32:21 +0000
commit7fa00f9ecdf2ec5d42ebaf411a619e54404e4800 (patch)
tree4df20e35365c1e73dde417ae01111e03a0fa5644 /OpenSim/Framework/Communications/Cache/AssetServerBase.cs
parent* remove unused CommitAssets() hook for now (diff)
downloadopensim-SC_OLD-7fa00f9ecdf2ec5d42ebaf411a619e54404e4800.zip
opensim-SC_OLD-7fa00f9ecdf2ec5d42ebaf411a619e54404e4800.tar.gz
opensim-SC_OLD-7fa00f9ecdf2ec5d42ebaf411a619e54404e4800.tar.bz2
opensim-SC_OLD-7fa00f9ecdf2ec5d42ebaf411a619e54404e4800.tar.xz
* remove redundant sync locking in AssetServerBase since this is already being done by the lower database layers
Diffstat (limited to 'OpenSim/Framework/Communications/Cache/AssetServerBase.cs')
-rw-r--r--OpenSim/Framework/Communications/Cache/AssetServerBase.cs16
1 files changed, 2 insertions, 14 deletions
diff --git a/OpenSim/Framework/Communications/Cache/AssetServerBase.cs b/OpenSim/Framework/Communications/Cache/AssetServerBase.cs
index f65b88f..f729d78 100644
--- a/OpenSim/Framework/Communications/Cache/AssetServerBase.cs
+++ b/OpenSim/Framework/Communications/Cache/AssetServerBase.cs
@@ -44,12 +44,11 @@ namespace OpenSim.Framework.Communications.Cache
44 protected BlockingQueue<AssetRequest> m_assetRequests; 44 protected BlockingQueue<AssetRequest> m_assetRequests;
45 protected Thread m_localAssetServerThread; 45 protected Thread m_localAssetServerThread;
46 protected IAssetProvider m_assetProvider; 46 protected IAssetProvider m_assetProvider;
47 protected object m_syncLock = new object();
48 47
49 // Temporarily hardcoded - should be a plugin 48 // Temporarily hardcoded - should be a plugin
50 protected IAssetLoader assetLoader = new AssetLoaderFileSystem(); 49 protected IAssetLoader assetLoader = new AssetLoaderFileSystem();
51 50
52 protected abstract void StoreAsset(AssetBase asset); 51 public abstract void StoreAsset(AssetBase asset);
53 52
54 /// <summary> 53 /// <summary>
55 /// This method must be implemented by a subclass to retrieve the asset named in the 54 /// This method must be implemented by a subclass to retrieve the asset named in the
@@ -161,18 +160,7 @@ namespace OpenSim.Framework.Communications.Cache
161 160
162 public virtual void UpdateAsset(AssetBase asset) 161 public virtual void UpdateAsset(AssetBase asset)
163 { 162 {
164 lock (m_syncLock) 163 m_assetProvider.UpdateAsset(asset);
165 {
166 m_assetProvider.UpdateAsset(asset);
167 }
168 }
169
170 public void StoreAndCommitAsset(AssetBase asset)
171 {
172 lock (m_syncLock)
173 {
174 StoreAsset(asset);
175 }
176 } 164 }
177 165
178 public virtual void Close() 166 public virtual void Close()