Thanks, sempuki, for a patch that moves control of Mono.Addins from source attributes to external XML files. Fix issues 1682 and 1786.
parent
ba17b0df27
commit
a0930aa80d
|
@ -28,18 +28,13 @@
|
|||
using System.Reflection;
|
||||
using System.Threading;
|
||||
using log4net;
|
||||
using Mono.Addins;
|
||||
using Nini.Config;
|
||||
using OpenSim.Framework;
|
||||
using OpenSim.Framework.RegionLoader.Filesystem;
|
||||
using OpenSim.Framework.RegionLoader.Web;
|
||||
|
||||
[assembly : Addin]
|
||||
[assembly : AddinDependency("OpenSim", "0.5")]
|
||||
|
||||
namespace OpenSim.ApplicationPlugins.LoadRegions
|
||||
{
|
||||
[Extension("/OpenSim/Startup")]
|
||||
public class LoadRegionsPlugin : IApplicationPlugin
|
||||
{
|
||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||
|
|
|
@ -33,19 +33,14 @@ using System.Reflection;
|
|||
using System.Timers;
|
||||
using libsecondlife;
|
||||
using log4net;
|
||||
using Mono.Addins;
|
||||
using Nwc.XmlRpc;
|
||||
using OpenSim.Framework;
|
||||
using OpenSim.Framework.Servers;
|
||||
using OpenSim.Region.Environment.Modules.World.Terrain;
|
||||
using OpenSim.Region.Environment.Scenes;
|
||||
|
||||
[assembly : Addin]
|
||||
[assembly : AddinDependency("OpenSim", "0.5")]
|
||||
|
||||
namespace OpenSim.ApplicationPlugins.RemoteController
|
||||
{
|
||||
[Extension("/OpenSim/Startup")]
|
||||
public class RemoteAdminPlugin : IApplicationPlugin
|
||||
{
|
||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||
|
|
|
@ -32,16 +32,9 @@ using System.Reflection;
|
|||
using OpenSim.Framework;
|
||||
using OpenSim.Framework.Servers;
|
||||
using OpenSim.ApplicationPlugins.Rest;
|
||||
using Mono.Addins;
|
||||
|
||||
[assembly : Addin]
|
||||
[assembly : AddinDependency("OpenSim", "0.5")]
|
||||
|
||||
namespace OpenSim.ApplicationPlugins.Rest.Inventory
|
||||
{
|
||||
|
||||
[Extension("/OpenSim/Startup")]
|
||||
|
||||
public class RestHandler : RestPlugin, IHttpAgentHandler
|
||||
{
|
||||
|
||||
|
|
|
@ -37,7 +37,6 @@ using System.Timers;
|
|||
using System.Xml;
|
||||
using System.Xml.Serialization;
|
||||
using libsecondlife;
|
||||
using Mono.Addins;
|
||||
using Nwc.XmlRpc;
|
||||
using Nini.Config;
|
||||
using OpenSim.Framework;
|
||||
|
@ -47,13 +46,8 @@ using OpenSim.Framework.Communications;
|
|||
using OpenSim.Region.Environment.Scenes;
|
||||
using OpenSim.ApplicationPlugins.Rest;
|
||||
|
||||
[assembly : Addin]
|
||||
[assembly : AddinDependency("OpenSim", "0.5")]
|
||||
|
||||
namespace OpenSim.ApplicationPlugins.Rest.Regions
|
||||
{
|
||||
|
||||
[Extension("/OpenSim/Startup")]
|
||||
public partial class RestRegionPlugin : RestPlugin
|
||||
{
|
||||
private static XmlSerializerNamespaces _xmlNs;
|
||||
|
|
|
@ -35,7 +35,6 @@ using System.Reflection;
|
|||
using System.Timers;
|
||||
using System.Xml;
|
||||
using libsecondlife;
|
||||
using Mono.Addins;
|
||||
using Nwc.XmlRpc;
|
||||
using Nini.Config;
|
||||
using OpenSim.Framework;
|
||||
|
@ -44,13 +43,8 @@ using OpenSim.Framework.Servers;
|
|||
using OpenSim.Framework.Communications;
|
||||
using OpenSim.Region.Environment.Scenes;
|
||||
|
||||
// [assembly : Addin]
|
||||
// [assembly : AddinDependency("OpenSim", "0.5")]
|
||||
|
||||
namespace OpenSim.ApplicationPlugins.Rest
|
||||
{
|
||||
|
||||
// [Extension("/OpenSim/Startup")]
|
||||
public abstract class RestPlugin : IApplicationPlugin
|
||||
{
|
||||
#region properties
|
||||
|
|
|
@ -26,11 +26,8 @@
|
|||
*/
|
||||
|
||||
using libsecondlife;
|
||||
using Mono.Addins;
|
||||
using OpenSim.Framework;
|
||||
|
||||
[assembly : AddinRoot("OpenSim.Data", "0.5")]
|
||||
|
||||
namespace OpenSim.Data
|
||||
{
|
||||
public enum DataResponse
|
||||
|
@ -44,7 +41,6 @@ namespace OpenSim.Data
|
|||
/// <summary>
|
||||
/// A standard grid interface
|
||||
/// </summary>
|
||||
[TypeExtensionPoint("/OpenSim/GridDataStore")]
|
||||
public interface IGridDataPlugin : IPlugin
|
||||
{
|
||||
/// <summary>
|
||||
|
@ -105,10 +101,10 @@ namespace OpenSim.Data
|
|||
ReservationData GetReservationAtPoint(uint x, uint y);
|
||||
}
|
||||
|
||||
public class GridDataStoreInitialiser : PluginInitialiserBase
|
||||
public class GridDataInitialiser : PluginInitialiserBase
|
||||
{
|
||||
private string connect;
|
||||
public GridDataStoreInitialiser (string s) { connect = s; }
|
||||
public GridDataInitialiser (string s) { connect = s; }
|
||||
public override void Initialise (IPlugin plugin)
|
||||
{
|
||||
IGridDataPlugin p = plugin as IGridDataPlugin;
|
||||
|
|
|
@ -25,7 +25,6 @@
|
|||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
using Mono.Addins;
|
||||
using OpenSim.Framework;
|
||||
|
||||
namespace OpenSim.Data
|
||||
|
@ -64,7 +63,6 @@ namespace OpenSim.Data
|
|||
/// <summary>
|
||||
/// An interface to a LogData storage system
|
||||
/// </summary>
|
||||
[TypeExtensionPoint("/OpenSim/GridLogData")]
|
||||
public interface ILogDataPlugin : IPlugin
|
||||
{
|
||||
void saveLog(string serverDaemon, string target, string methodCall, string arguments, int priority,
|
||||
|
|
|
@ -33,18 +33,13 @@ using System.Security.Cryptography;
|
|||
using System.Text;
|
||||
using libsecondlife;
|
||||
using log4net;
|
||||
using Mono.Addins;
|
||||
using OpenSim.Framework;
|
||||
|
||||
[assembly : Addin]
|
||||
[assembly : AddinDependency("OpenSim.Data", "0.5")]
|
||||
|
||||
namespace OpenSim.Data.MSSQL
|
||||
{
|
||||
/// <summary>
|
||||
/// A grid data interface for MSSQL Server
|
||||
/// </summary>
|
||||
[Extension("/OpenSim/GridDataStore")]
|
||||
public class MSSQLGridData : GridDataBase
|
||||
{
|
||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||
|
|
|
@ -30,19 +30,13 @@ using System.Reflection;
|
|||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using log4net;
|
||||
using Mono.Addins;
|
||||
using OpenSim.Framework;
|
||||
|
||||
// Only one attribute per assembly. See: *GridData.cs
|
||||
// [assembly : Addin]
|
||||
// [assembly : AddinDependency("OpenSim.Data", "0.5")]
|
||||
|
||||
namespace OpenSim.Data.MSSQL
|
||||
{
|
||||
/// <summary>
|
||||
/// An interface to the log database for MSSQL
|
||||
/// </summary>
|
||||
[Extension("/OpenSim/GridLogData")]
|
||||
internal class MSSQLLogData : ILogDataPlugin
|
||||
{
|
||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||
|
|
|
@ -33,18 +33,13 @@ using System.Security.Cryptography;
|
|||
using System.Text;
|
||||
using libsecondlife;
|
||||
using log4net;
|
||||
using Mono.Addins;
|
||||
using OpenSim.Framework;
|
||||
|
||||
[assembly : Addin]
|
||||
[assembly : AddinDependency("OpenSim.Data", "0.5")]
|
||||
|
||||
namespace OpenSim.Data.MySQL
|
||||
{
|
||||
/// <summary>
|
||||
/// A MySQL Interface for the Grid Server
|
||||
/// </summary>
|
||||
[Extension("/OpenSim/GridDataStore")]
|
||||
public class MySQLGridData : GridDataBase
|
||||
{
|
||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||
|
|
|
@ -28,19 +28,13 @@ using System;
|
|||
using System.Reflection;
|
||||
using System.Collections.Generic;
|
||||
using log4net;
|
||||
using Mono.Addins;
|
||||
using OpenSim.Framework;
|
||||
|
||||
// Only one attribute per assembly. See: *GridData.cs
|
||||
// [assembly : Addin]
|
||||
// [assembly : AddinDependency("OpenSim.Data", "0.5")]
|
||||
|
||||
namespace OpenSim.Data.MySQL
|
||||
{
|
||||
/// <summary>
|
||||
/// An interface to the log database for MySQL
|
||||
/// </summary>
|
||||
[Extension("/OpenSim/GridLogData")]
|
||||
internal class MySQLLogData : ILogDataPlugin
|
||||
{
|
||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||
|
|
|
@ -33,18 +33,13 @@ using System.Security.Cryptography;
|
|||
using System.Text;
|
||||
using libsecondlife;
|
||||
using log4net;
|
||||
using Mono.Addins;
|
||||
using OpenSim.Framework;
|
||||
|
||||
[assembly : Addin]
|
||||
[assembly : AddinDependency("OpenSim.Data", "0.5")]
|
||||
|
||||
namespace OpenSim.Data.SQLite
|
||||
{
|
||||
/// <summary>
|
||||
/// A Grid Interface to the SQLite database
|
||||
/// </summary>
|
||||
[Extension("/OpenSim/GridDataStore")]
|
||||
public class SQLiteGridData : GridDataBase
|
||||
{
|
||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||
|
|
|
@ -197,7 +197,9 @@ namespace OpenSim.Framework
|
|||
|
||||
private void on_addinloaderror_(object sender, AddinErrorEventArgs args)
|
||||
{
|
||||
log.Error ("[PLUGINS]: Plugin Error: " + args.Message);
|
||||
log.Error ("[PLUGINS]: Plugin Error: " + args.Message
|
||||
+ ": " + args.Exception.Message
|
||||
+ "\n"+ args.Exception.StackTrace);
|
||||
}
|
||||
|
||||
private void clear_registry_ ()
|
||||
|
|
|
@ -73,18 +73,18 @@ namespace OpenSim.Grid.GridServer
|
|||
provider = String.Join (".", s);
|
||||
|
||||
PluginLoader<IGridDataPlugin> gridloader =
|
||||
new PluginLoader<IGridDataPlugin> (new GridDataStoreInitialiser (connect));
|
||||
new PluginLoader<IGridDataPlugin> (new GridDataInitialiser (connect));
|
||||
|
||||
PluginLoader<ILogDataPlugin> logloader =
|
||||
new PluginLoader<ILogDataPlugin> (new LogDataInitialiser (connect));
|
||||
|
||||
gridloader.AddExtensionPoint ("/OpenSim/GridDataStore");
|
||||
logloader.AddExtensionPoint ("/OpenSim/GridLogData");
|
||||
gridloader.AddExtensionPoint ("/OpenSim/GridData");
|
||||
logloader.AddExtensionPoint ("/OpenSim/LogData");
|
||||
|
||||
// loader will try to load all providers (MySQL, MSSQL, etc)
|
||||
// unless it is constrainted to the correct "id"
|
||||
gridloader.AddFilter ("/OpenSim/GridDataStore", new PluginIdFilter (provider + "GridData"));
|
||||
logloader.AddFilter ("/OpenSim/GridLogData", new PluginIdFilter (provider + "LogData"));
|
||||
//gridloader.AddFilter ("/OpenSim/GridData", new PluginIdFilter (provider + "GridData"));
|
||||
//logloader.AddFilter ("/OpenSim/LogData", new PluginIdFilter (provider + "LogData"));
|
||||
|
||||
gridloader.Load();
|
||||
logloader.Load();
|
||||
|
@ -111,7 +111,7 @@ namespace OpenSim.Grid.GridServer
|
|||
}
|
||||
catch (Exception)
|
||||
{
|
||||
m_log.Warn("[storage]: Unable to write log via ");
|
||||
m_log.Warn("[storage]: Unable to write log via " + plugin.Name);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -26,14 +26,10 @@
|
|||
*
|
||||
*/
|
||||
|
||||
using Mono.Addins;
|
||||
using OpenSim.Framework;
|
||||
|
||||
[assembly : AddinRoot("OpenSim.Grid.GridServer", "0.5")]
|
||||
|
||||
namespace OpenSim.Grid.GridServer
|
||||
{
|
||||
[TypeExtensionPoint("/OpenSim/GridServer")]
|
||||
public interface IGridPlugin : IPlugin
|
||||
{
|
||||
void Initialise(GridServerBase gridServer);
|
||||
|
|
|
@ -25,14 +25,10 @@
|
|||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
using Mono.Addins;
|
||||
using OpenSim.Framework;
|
||||
|
||||
[assembly : AddinRoot("OpenSim", "0.5")]
|
||||
|
||||
namespace OpenSim
|
||||
{
|
||||
[TypeExtensionPoint("/OpenSim/Startup")]
|
||||
public interface IApplicationPlugin : IPlugin
|
||||
{
|
||||
void Initialise(OpenSimBase openSim);
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.ApplicationPlugins.LoadRegions.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/Startup">
|
||||
<Type type="OpenSim.ApplicationPlugins.LoadRegions.LoadRegionsPlugin" />
|
||||
</Extension>
|
||||
</Addin>
|
||||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.ApplicationPlugins.LoadRegions.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/Startup">
|
||||
<Type type="OpenSim.ApplicationPlugins.LoadRegions.LoadRegionsPlugin" />
|
||||
</Extension>
|
||||
</Addin>
|
|
@ -0,0 +1,28 @@
|
|||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.Data.MySQL.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim.Data" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/GridData">
|
||||
<Type type="OpenSim.Data.MySQL.MySQLGridData" />
|
||||
</Extension>
|
||||
<Extension path = "/OpenSim/LogData">
|
||||
<Type type="OpenSim.Data.MySQL.MySQLLogData" />
|
||||
</Extension>
|
||||
</Addin>
|
||||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.Data.MySQL.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim.Data" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/GridData">
|
||||
<Type type="OpenSim.Data.MySQL.MySQLGridData" />
|
||||
</Extension>
|
||||
<Extension path = "/OpenSim/LogData">
|
||||
<Type type="OpenSim.Data.MySQL.MySQLLogData" />
|
||||
</Extension>
|
||||
</Addin>
|
|
@ -0,0 +1,24 @@
|
|||
<Addin id="OpenSim.Data" isroot="true" version="0.5">
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.Grid.GridServer.exe"/>
|
||||
<Import assembly="OpenSim.Data.dll"/>
|
||||
</Runtime>
|
||||
<ExtensionPoint path = "/OpenSim/GridData">
|
||||
<ExtensionNode objectType="OpenSim.Data.IGridDataPlugin"/>
|
||||
</ExtensionPoint>
|
||||
<ExtensionPoint path = "/OpenSim/LogData">
|
||||
<ExtensionNode objectType="OpenSim.Data.ILogDataPlugin"/>
|
||||
</ExtensionPoint>
|
||||
</Addin>
|
||||
<Addin id="OpenSim.Data" isroot="true" version="0.5">
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.Grid.GridServer.exe"/>
|
||||
<Import assembly="OpenSim.Data.dll"/>
|
||||
</Runtime>
|
||||
<ExtensionPoint path = "/OpenSim/GridData">
|
||||
<ExtensionNode objectType="OpenSim.Data.IGridDataPlugin"/>
|
||||
</ExtensionPoint>
|
||||
<ExtensionPoint path = "/OpenSim/LogData">
|
||||
<ExtensionNode objectType="OpenSim.Data.ILogDataPlugin"/>
|
||||
</ExtensionPoint>
|
||||
</Addin>
|
|
@ -0,0 +1,16 @@
|
|||
<Addin id="OpenSim.Grid.GridServer" isroot="true" version="0.5">
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.Grid.GridServer.exe"/>
|
||||
</Runtime>
|
||||
<ExtensionPoint path = "/OpenSim/GridServer">
|
||||
<ExtensionNode objectType="OpenSim.Grid.GridServer.IGridPlugin"/>
|
||||
</ExtensionPoint>
|
||||
</Addin>
|
||||
<Addin id="OpenSim.Grid.GridServer" isroot="true" version="0.5">
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.Grid.GridServer.exe"/>
|
||||
</Runtime>
|
||||
<ExtensionPoint path = "/OpenSim/GridServer">
|
||||
<ExtensionNode objectType="OpenSim.Grid.GridServer.IGridPlugin"/>
|
||||
</ExtensionPoint>
|
||||
</Addin>
|
|
@ -0,0 +1,16 @@
|
|||
<Addin id="OpenSim" isroot="true" version="0.5">
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.exe"/>
|
||||
</Runtime>
|
||||
<ExtensionPoint path = "/OpenSim/Startup">
|
||||
<ExtensionNode objectType="OpenSim.Region.Application.IApplicationPlugin"/>
|
||||
</ExtensionPoint>
|
||||
</Addin>
|
||||
<Addin id="OpenSim" isroot="true" version="0.5">
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.exe"/>
|
||||
</Runtime>
|
||||
<ExtensionPoint path = "/OpenSim/Startup">
|
||||
<ExtensionNode objectType="OpenSim.Region.Application.IApplicationPlugin"/>
|
||||
</ExtensionPoint>
|
||||
</Addin>
|
|
@ -0,0 +1,22 @@
|
|||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.ApplicationPlugins.RemoteController.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/Startup">
|
||||
<Type type="OpenSim.ApplicationPlugins.RemoteController.RemoteAdminPlugin" />
|
||||
</Extension>
|
||||
</Addin>
|
||||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.ApplicationPlugins.RemoteController.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/Startup">
|
||||
<Type type="OpenSim.ApplicationPlugins.RemoteController.RemoteAdminPlugin" />
|
||||
</Extension>
|
||||
</Addin>
|
|
@ -0,0 +1,22 @@
|
|||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.ApplicationPlugins.Rest.Inventory.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/Startup">
|
||||
<Type type="OpenSim.ApplicationPlugins.Rest.Inventory.RestHandler" />
|
||||
</Extension>
|
||||
</Addin>
|
||||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.ApplicationPlugins.Rest.Inventory.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/Startup">
|
||||
<Type type="OpenSim.ApplicationPlugins.Rest.Inventory.RestHandler" />
|
||||
</Extension>
|
||||
</Addin>
|
|
@ -0,0 +1,22 @@
|
|||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.ApplicationPlugins.Rest.Regions.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/Startup">
|
||||
<Type type="OpenSim.ApplicationPlugins.Rest.Regions.RestRegionPlugin" />
|
||||
</Extension>
|
||||
</Addin>
|
||||
<Addin>
|
||||
<Runtime>
|
||||
<Import assembly="OpenSim.ApplicationPlugins.Rest.Regions.dll"/>
|
||||
</Runtime>
|
||||
<Dependencies>
|
||||
<Addin id="OpenSim" version="0.5" />
|
||||
</Dependencies>
|
||||
<Extension path = "/OpenSim/Startup">
|
||||
<Type type="OpenSim.ApplicationPlugins.Rest.Regions.RestRegionPlugin" />
|
||||
</Extension>
|
||||
</Addin>
|
Loading…
Reference in New Issue