aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Grid/AssetServer/Main.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Grid/AssetServer/Main.cs')
-rw-r--r--OpenSim/Grid/AssetServer/Main.cs15
1 files changed, 1 insertions, 14 deletions
diff --git a/OpenSim/Grid/AssetServer/Main.cs b/OpenSim/Grid/AssetServer/Main.cs
index 07fe0a4..060c473 100644
--- a/OpenSim/Grid/AssetServer/Main.cs
+++ b/OpenSim/Grid/AssetServer/Main.cs
@@ -112,24 +112,11 @@ namespace OpenSim.Grid.AssetServer
112 return null; 112 return null;
113 } 113 }
114 114
115 public IAssetDataPlugin LoadDatabasePlugin(string provider, string connect)
116 {
117 PluginLoader<IAssetDataPlugin> loader =
118 new PluginLoader<IAssetDataPlugin> (new AssetDataInitialiser (connect));
119
120 // loader will try to load all providers (MySQL, MSSQL, etc)
121 // unless it is constrainted to the correct "Provider" entry in the addin.xml
122 loader.Add ("/OpenSim/AssetData", new PluginProviderFilter (provider));
123 loader.Load();
124
125 return loader.Plugin;
126 }
127
128 public void setupDB(AssetConfig config) 115 public void setupDB(AssetConfig config)
129 { 116 {
130 try 117 try
131 { 118 {
132 m_assetProvider = LoadDatabasePlugin(config.DatabaseProvider, config.DatabaseConnect); 119 m_assetProvider = DataPluginFactory.LoadAssetDataPlugin(config.DatabaseProvider, config.DatabaseConnect);
133 if (m_assetProvider == null) 120 if (m_assetProvider == null)
134 { 121 {
135 m_log.Error("[ASSET]: Failed to load a database plugin, server halting"); 122 m_log.Error("[ASSET]: Failed to load a database plugin, server halting");