29 using System.Reflection;
31 using OpenSim.Framework;
33 using OpenSim.Services.Interfaces;
34 using OpenSim.Services.Base;
36 namespace OpenSim.Services.AuthorizationService
44 string dllName = String.Empty;
45 string connString = String.Empty;
50 IConfig assetConfig = config.Configs[
"AuthorizationService"];
51 if (assetConfig != null)
53 dllName = assetConfig.GetString(
"StorageProvider", dllName);
54 connString = assetConfig.GetString(
"ConnectionString", connString);
60 IConfig dbConfig = config.Configs[
"DatabaseService"];
63 if (dllName == String.Empty)
64 dllName = dbConfig.GetString(
"StorageProvider", String.Empty);
65 if (connString == String.Empty)
66 connString = dbConfig.GetString(
"ConnectionString", String.Empty);
72 if (dllName.Equals(String.Empty))
73 throw new Exception(
"No StorageProvider configured");
75 m_Database = LoadPlugin<IAssetDataPlugin>(dllName);
76 if (m_Database == null)
77 throw new Exception(
"Could not find a storage interface in the given module");
79 m_Database.Initialise(connString);
AuthorizationServiceBase(IConfigSource config)