aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs')
-rw-r--r--OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs12
1 files changed, 7 insertions, 5 deletions
diff --git a/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs b/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs
index 76608c7..d08ef8b 100644
--- a/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs
+++ b/OpenSim/Framework/Data.SQLite/SQLiteAssetData.cs
@@ -39,6 +39,8 @@ namespace OpenSim.Framework.Data.SQLite
39 /// </summary> 39 /// </summary>
40 public class SQLiteAssetData : SQLiteBase, IAssetProvider 40 public class SQLiteAssetData : SQLiteBase, IAssetProvider
41 { 41 {
42 private static readonly log4net.ILog m_log = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
43
42 /// <summary> 44 /// <summary>
43 /// The database manager 45 /// The database manager
44 /// </summary> 46 /// </summary>
@@ -86,10 +88,10 @@ namespace OpenSim.Framework.Data.SQLite
86 88
87 public void CreateAsset(AssetBase asset) 89 public void CreateAsset(AssetBase asset)
88 { 90 {
89 MainLog.Instance.Verbose("SQLITE", "Creating Asset " + Util.ToRawUuidString(asset.FullID)); 91 m_log.Info("[SQLITE]: Creating Asset " + Util.ToRawUuidString(asset.FullID));
90 if (ExistsAsset(asset.FullID)) 92 if (ExistsAsset(asset.FullID))
91 { 93 {
92 MainLog.Instance.Verbose("SQLITE", "Asset exists, updating instead. You should fix the caller for this!"); 94 m_log.Info("[SQLITE]: Asset exists, updating instead. You should fix the caller for this!");
93 UpdateAsset(asset); 95 UpdateAsset(asset);
94 } 96 }
95 else 97 else
@@ -135,7 +137,7 @@ namespace OpenSim.Framework.Data.SQLite
135 string temporary = asset.Temporary ? "Temporary" : "Stored"; 137 string temporary = asset.Temporary ? "Temporary" : "Stored";
136 string local = asset.Local ? "Local" : "Remote"; 138 string local = asset.Local ? "Local" : "Remote";
137 139
138 MainLog.Instance.Verbose("SQLITE", 140 m_log.Info("[SQLITE]: " +
139 string.Format("Loaded {6} {5} Asset: [{0}][{3}/{4}] \"{1}\":{2} ({7} bytes)", 141 string.Format("Loaded {6} {5} Asset: [{0}][{3}/{4}] \"{1}\":{2} ({7} bytes)",
140 asset.FullID, asset.Name, asset.Description, asset.Type, 142 asset.FullID, asset.Name, asset.Description, asset.Type,
141 asset.InvType, temporary, local, asset.Data.Length)); 143 asset.InvType, temporary, local, asset.Data.Length));
@@ -174,7 +176,7 @@ namespace OpenSim.Framework.Data.SQLite
174 176
175 public void CommitAssets() // force a sync to the database 177 public void CommitAssets() // force a sync to the database
176 { 178 {
177 MainLog.Instance.Verbose("SQLITE", "Attempting commit"); 179 m_log.Info("[SQLITE]: Attempting commit");
178 // lock (ds) 180 // lock (ds)
179 // { 181 // {
180 // da.Update(ds, "assets"); 182 // da.Update(ds, "assets");
@@ -261,7 +263,7 @@ namespace OpenSim.Framework.Data.SQLite
261 } 263 }
262 catch (SqliteSyntaxException) 264 catch (SqliteSyntaxException)
263 { 265 {
264 MainLog.Instance.Verbose("SQLITE", "SQLite Database doesn't exist... creating"); 266 m_log.Info("[SQLITE]: SQLite Database doesn't exist... creating");
265 InitDB(conn); 267 InitDB(conn);
266 } 268 }
267 return true; 269 return true;