Allow Mono Plugin Registry setting for Regions
Signed-off-by: Melanie <melanie@t-data.com>0.8.0.3
parent
a5800f479e
commit
3d0778bcd6
|
@ -215,7 +215,7 @@ namespace OpenSim.Framework
|
|||
AddinManager.AddinLoadError += on_addinloaderror_;
|
||||
AddinManager.AddinLoaded += on_addinloaded_;
|
||||
|
||||
clear_registry_();
|
||||
clear_registry_(dir);
|
||||
|
||||
suppress_console_output_(true);
|
||||
AddinManager.Initialize(dir);
|
||||
|
@ -239,18 +239,19 @@ namespace OpenSim.Framework
|
|||
+ args.Exception.StackTrace);
|
||||
}
|
||||
|
||||
private void clear_registry_()
|
||||
private void clear_registry_(string dir)
|
||||
{
|
||||
// The Mono addin manager (in Mono.Addins.dll version 0.2.0.0)
|
||||
// occasionally seems to corrupt its addin cache
|
||||
// Hence, as a temporary solution we'll remove it before each startup
|
||||
|
||||
try
|
||||
{
|
||||
if (Directory.Exists("addin-db-000"))
|
||||
Directory.Delete("addin-db-000", true);
|
||||
if (Directory.Exists(dir + "/addin-db-000"))
|
||||
Directory.Delete(dir + "/addin-db-000", true);
|
||||
|
||||
if (Directory.Exists("addin-db-001"))
|
||||
Directory.Delete("addin-db-001", true);
|
||||
if (Directory.Exists(dir + "/addin-db-001"))
|
||||
Directory.Delete(dir + "/addin-db-001", true);
|
||||
}
|
||||
catch (IOException)
|
||||
{
|
||||
|
|
|
@ -158,7 +158,10 @@ namespace OpenSim
|
|||
|
||||
protected virtual void LoadPlugins()
|
||||
{
|
||||
using (PluginLoader<IApplicationPlugin> loader = new PluginLoader<IApplicationPlugin>(new ApplicationPluginInitialiser(this)))
|
||||
IConfig startupConfig = Config.Configs["Startup"];
|
||||
string registryLocation = (startupConfig != null) ? startupConfig.GetString("RegistryLocation",".") : ".";
|
||||
|
||||
using (PluginLoader<IApplicationPlugin> loader = new PluginLoader<IApplicationPlugin>(new ApplicationPluginInitialiser(this), registryLocation))
|
||||
{
|
||||
loader.Load("/OpenSim/Startup");
|
||||
m_plugins = loader.Plugins;
|
||||
|
|
|
@ -57,6 +57,12 @@
|
|||
; when running with the SmartThreadPool option above
|
||||
MaxPoolThreads = 15
|
||||
|
||||
; Plugin Registry Location
|
||||
; Set path to directory for plugin registry. Information about the
|
||||
; registered repositories and installed plugins will be stored here.
|
||||
; The OpenSim.exe process must have R/W access to the location.
|
||||
; RegistryLocation = "."
|
||||
|
||||
; ##
|
||||
; ## CLIENTS
|
||||
; ##
|
||||
|
|
Loading…
Reference in New Issue