From 5cf6a6f8302b4f03d45c21f0731978da1d3ddcab Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Tue, 30 Dec 2014 07:58:42 -0800 Subject: WARNING: BREAKING CHANGES FOR REGION MODULE DEVELOPMENT. This cleans up Opensim's use of mono addins. In particular, the extension points /OpenSim/RegionModules and /OpenSim/WindModule moved from OpenSim.exe to OpenSim.Region.Framework.dll. From here on, developers of region modules should declare their dlls to be dependent on OpenSim.Region.Framework, starting with version 0.8.1 Additional changes: - Addins version uniformly updated to 0.8.1. These numbers should be compatible with the release numbers or else it becomes very confusing. - Mono addins directives moved from files addins.xml to embedded directives in the class and assembly declarations, to make it all consistent --- OpenSim/Addons/Groups/Properties/AssemblyInfo.cs | 2 +- OpenSim/Addons/OfflineIM/Properties/AssemblyInfo.cs | 2 +- .../LoadRegions/LoadRegionsPlugin.cs | 2 ++ .../LoadRegions/Properties/AssemblyInfo.cs | 8 ++++++-- .../Resources/LoadRegionsPlugin.addin.xml | 11 ----------- .../Properties/AssemblyInfo.cs | 3 +++ .../RegionModulesControllerPlugin.cs | 1 + .../RegionModulesControllerPlugin.addin.xml | 13 ------------- .../RemoteController/Properties/AssemblyInfo.cs | 3 +++ .../RemoteController/RemoteAdminPlugin.cs | 2 ++ .../Resources/RemoteAdminPlugin.addin.xml | 11 ----------- OpenSim/Region/Application/IApplicationPlugin.cs | 2 ++ .../Region/Application/Properties/AssemblyInfo.cs | 4 ++++ .../Linden/Caps/BunchOfCaps/BunchOfCapsModule.cs | 2 +- .../Region/CoreModules/Properties/AssemblyInfo.cs | 2 +- OpenSim/Region/DataSnapshot/DataSnapshotManager.cs | 2 +- .../Region/Framework/Interfaces/IRegionModuleBase.cs | 1 + .../Region/Framework/Interfaces/IWindModelPlugin.cs | 3 +++ OpenSim/Region/Framework/Properties/AssemblyInfo.cs | 3 +++ .../OptionalModules/Properties/AssemblyInfo.cs | 2 +- OpenSim/Region/UserStatistics/WebStatsModule.cs | 2 +- OpenSim/Services/Connectors/SimianGrid/SimianGrid.cs | 2 +- bin/OpenSim.addin.xml | 20 -------------------- 23 files changed, 38 insertions(+), 65 deletions(-) delete mode 100644 OpenSim/ApplicationPlugins/LoadRegions/Resources/LoadRegionsPlugin.addin.xml delete mode 100644 OpenSim/ApplicationPlugins/RegionModulesController/Resources/RegionModulesControllerPlugin.addin.xml delete mode 100644 OpenSim/ApplicationPlugins/RemoteController/Resources/RemoteAdminPlugin.addin.xml delete mode 100644 bin/OpenSim.addin.xml diff --git a/OpenSim/Addons/Groups/Properties/AssemblyInfo.cs b/OpenSim/Addons/Groups/Properties/AssemblyInfo.cs index abafd34..aa31a14 100644 --- a/OpenSim/Addons/Groups/Properties/AssemblyInfo.cs +++ b/OpenSim/Addons/Groups/Properties/AssemblyInfo.cs @@ -33,4 +33,4 @@ using Mono.Addins; [assembly: AssemblyVersion("0.8.1.*")] [assembly: Addin("OpenSim.Groups", "0.1")] -[assembly: AddinDependency("OpenSim", "0.8.1")] +[assembly: AddinDependency("OpenSim.Region.Framework", "0.8.1")] diff --git a/OpenSim/Addons/OfflineIM/Properties/AssemblyInfo.cs b/OpenSim/Addons/OfflineIM/Properties/AssemblyInfo.cs index 0c9a576..054e1fb 100644 --- a/OpenSim/Addons/OfflineIM/Properties/AssemblyInfo.cs +++ b/OpenSim/Addons/OfflineIM/Properties/AssemblyInfo.cs @@ -33,4 +33,4 @@ using Mono.Addins; [assembly: AssemblyVersion("0.8.1.*")] [assembly: Addin("OpenSim.OfflineIM", "0.1")] -[assembly: AddinDependency("OpenSim", "0.8.1")] +[assembly: AddinDependency("OpenSim.Region.Framework", "0.8.1")] diff --git a/OpenSim/ApplicationPlugins/LoadRegions/LoadRegionsPlugin.cs b/OpenSim/ApplicationPlugins/LoadRegions/LoadRegionsPlugin.cs index 3455411..74d9ae4 100644 --- a/OpenSim/ApplicationPlugins/LoadRegions/LoadRegionsPlugin.cs +++ b/OpenSim/ApplicationPlugins/LoadRegions/LoadRegionsPlugin.cs @@ -40,9 +40,11 @@ using OpenSim.Region.CoreModules.Scripting.DynamicTexture; using OpenSim.Region.CoreModules.Scripting.LoadImageURL; using OpenSim.Region.CoreModules.Scripting.XMLRPC; using OpenSim.Services.Interfaces; +using Mono.Addins; namespace OpenSim.ApplicationPlugins.LoadRegions { + [Extension(Path="/OpenSim/Startup", Id="LoadRegions", NodeName="Plugin")] public class LoadRegionsPlugin : IApplicationPlugin, IRegionCreator { private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); diff --git a/OpenSim/ApplicationPlugins/LoadRegions/Properties/AssemblyInfo.cs b/OpenSim/ApplicationPlugins/LoadRegions/Properties/AssemblyInfo.cs index 89d24ac..d289e78 100644 --- a/OpenSim/ApplicationPlugins/LoadRegions/Properties/AssemblyInfo.cs +++ b/OpenSim/ApplicationPlugins/LoadRegions/Properties/AssemblyInfo.cs @@ -27,16 +27,17 @@ using System.Reflection; using System.Runtime.InteropServices; +using Mono.Addins; // General information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. -[assembly : AssemblyTitle("OpenSim.Addin")] +[assembly : AssemblyTitle("OpenSim.ApplicationPlugins.LoadRegions")] [assembly : AssemblyDescription("")] [assembly : AssemblyConfiguration("")] [assembly : AssemblyCompany("http://opensimulator.org")] -[assembly : AssemblyProduct("OpenSim.Addin")] +[assembly : AssemblyProduct("OpenSim")] [assembly : AssemblyCopyright("Copyright © OpenSimulator.org Developers 2007-2009")] [assembly : AssemblyTrademark("")] [assembly : AssemblyCulture("")] @@ -63,3 +64,6 @@ using System.Runtime.InteropServices; // [assembly: AssemblyVersion("0.7.6.*")] [assembly : AssemblyVersion("0.8.1.*")] + +[assembly: Addin("OpenSim.ApplicationPlugins.LoadRegions", "0.1")] +[assembly: AddinDependency("OpenSim", "0.8.1")] diff --git a/OpenSim/ApplicationPlugins/LoadRegions/Resources/LoadRegionsPlugin.addin.xml b/OpenSim/ApplicationPlugins/LoadRegions/Resources/LoadRegionsPlugin.addin.xml deleted file mode 100644 index 840a1b4..0000000 --- a/OpenSim/ApplicationPlugins/LoadRegions/Resources/LoadRegionsPlugin.addin.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - diff --git a/OpenSim/ApplicationPlugins/RegionModulesController/Properties/AssemblyInfo.cs b/OpenSim/ApplicationPlugins/RegionModulesController/Properties/AssemblyInfo.cs index 0ada5af..edef4d5 100644 --- a/OpenSim/ApplicationPlugins/RegionModulesController/Properties/AssemblyInfo.cs +++ b/OpenSim/ApplicationPlugins/RegionModulesController/Properties/AssemblyInfo.cs @@ -1,6 +1,7 @@ using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; +using Mono.Addins; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information @@ -31,3 +32,5 @@ using System.Runtime.InteropServices; // [assembly: AssemblyVersion("0.8.1.*")] +[assembly: Addin("OpenSim.ApplicationPlugins.RegionModulesController", "0.1")] +[assembly: AddinDependency("OpenSim", "0.8.1")] diff --git a/OpenSim/ApplicationPlugins/RegionModulesController/RegionModulesControllerPlugin.cs b/OpenSim/ApplicationPlugins/RegionModulesController/RegionModulesControllerPlugin.cs index e03483a..86f71d9 100644 --- a/OpenSim/ApplicationPlugins/RegionModulesController/RegionModulesControllerPlugin.cs +++ b/OpenSim/ApplicationPlugins/RegionModulesController/RegionModulesControllerPlugin.cs @@ -38,6 +38,7 @@ using OpenSim.Region.Framework.Scenes; namespace OpenSim.ApplicationPlugins.RegionModulesController { + [Extension(Path = "/OpenSim/Startup", Id = "LoadRegions", NodeName = "Plugin")] public class RegionModulesControllerPlugin : IRegionModulesController, IApplicationPlugin { diff --git a/OpenSim/ApplicationPlugins/RegionModulesController/Resources/RegionModulesControllerPlugin.addin.xml b/OpenSim/ApplicationPlugins/RegionModulesController/Resources/RegionModulesControllerPlugin.addin.xml deleted file mode 100644 index c537922..0000000 --- a/OpenSim/ApplicationPlugins/RegionModulesController/Resources/RegionModulesControllerPlugin.addin.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - - - - diff --git a/OpenSim/ApplicationPlugins/RemoteController/Properties/AssemblyInfo.cs b/OpenSim/ApplicationPlugins/RemoteController/Properties/AssemblyInfo.cs index 245288f..7e9f6eb 100644 --- a/OpenSim/ApplicationPlugins/RemoteController/Properties/AssemblyInfo.cs +++ b/OpenSim/ApplicationPlugins/RemoteController/Properties/AssemblyInfo.cs @@ -1,6 +1,7 @@ using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; +using Mono.Addins; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information @@ -31,3 +32,5 @@ using System.Runtime.InteropServices; // [assembly: AssemblyVersion("0.8.1.*")] +[assembly: Addin("OpenSim.ApplicationPlugins.RemoteController", "0.1")] +[assembly: AddinDependency("OpenSim", "0.8.1")] diff --git a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs index 1e6e68b..3096323 100644 --- a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs +++ b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs @@ -39,6 +39,7 @@ using log4net; using Nini.Config; using Nwc.XmlRpc; using OpenMetaverse; +using Mono.Addins; using OpenSim; using OpenSim.Framework; using OpenSim.Framework.Communications; @@ -56,6 +57,7 @@ using RegionInfo = OpenSim.Framework.RegionInfo; namespace OpenSim.ApplicationPlugins.RemoteController { + [Extension(Path = "/OpenSim/Startup", Id = "LoadRegions", NodeName = "Plugin")] public class RemoteAdminPlugin : IApplicationPlugin { private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); diff --git a/OpenSim/ApplicationPlugins/RemoteController/Resources/RemoteAdminPlugin.addin.xml b/OpenSim/ApplicationPlugins/RemoteController/Resources/RemoteAdminPlugin.addin.xml deleted file mode 100644 index b0859f3..0000000 --- a/OpenSim/ApplicationPlugins/RemoteController/Resources/RemoteAdminPlugin.addin.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - diff --git a/OpenSim/Region/Application/IApplicationPlugin.cs b/OpenSim/Region/Application/IApplicationPlugin.cs index 6e6d48c..a3fa66c 100644 --- a/OpenSim/Region/Application/IApplicationPlugin.cs +++ b/OpenSim/Region/Application/IApplicationPlugin.cs @@ -26,12 +26,14 @@ */ using OpenSim.Framework; +using Mono.Addins; namespace OpenSim { /// /// OpenSimulator Application Plugin framework interface /// + [TypeExtensionPoint(NodeName="Plugin", NodeType = typeof(PluginExtensionNode), Path="/OpenSim/Startup")] public interface IApplicationPlugin : IPlugin { /// diff --git a/OpenSim/Region/Application/Properties/AssemblyInfo.cs b/OpenSim/Region/Application/Properties/AssemblyInfo.cs index 45d89c8..3e61575 100644 --- a/OpenSim/Region/Application/Properties/AssemblyInfo.cs +++ b/OpenSim/Region/Application/Properties/AssemblyInfo.cs @@ -1,6 +1,7 @@ using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; +using Mono.Addins; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information @@ -30,3 +31,6 @@ using System.Runtime.InteropServices; // Revision // [assembly: AssemblyVersion("0.8.1.*")] + +[assembly: AddinRoot("OpenSim", "0.8.1")] +[assembly: ImportAddinAssembly("Opensim.Framework.dll")] diff --git a/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCapsModule.cs b/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCapsModule.cs index 9a0a5d5..b05af22 100644 --- a/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCapsModule.cs +++ b/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCapsModule.cs @@ -41,7 +41,7 @@ using OpenSim.Region.Framework.Scenes; using Caps = OpenSim.Framework.Capabilities.Caps; [assembly: Addin("LindenCaps", "0.1")] -[assembly: AddinDependency("OpenSim", "0.8.1")] +[assembly: AddinDependency("OpenSim.Region.Framework", "0.8.1")] namespace OpenSim.Region.ClientStack.Linden { diff --git a/OpenSim/Region/CoreModules/Properties/AssemblyInfo.cs b/OpenSim/Region/CoreModules/Properties/AssemblyInfo.cs index 8b832a1..8cafa12 100644 --- a/OpenSim/Region/CoreModules/Properties/AssemblyInfo.cs +++ b/OpenSim/Region/CoreModules/Properties/AssemblyInfo.cs @@ -34,5 +34,5 @@ using Mono.Addins; [assembly: Addin("OpenSim.Region.CoreModules", "0.1")] -[assembly: AddinDependency("OpenSim", "0.8.1")] +[assembly: AddinDependency("OpenSim.Region.Framework", "0.8.1")] diff --git a/OpenSim/Region/DataSnapshot/DataSnapshotManager.cs b/OpenSim/Region/DataSnapshot/DataSnapshotManager.cs index 8bcb178..9d3ae5e 100644 --- a/OpenSim/Region/DataSnapshot/DataSnapshotManager.cs +++ b/OpenSim/Region/DataSnapshot/DataSnapshotManager.cs @@ -43,7 +43,7 @@ using OpenSim.Region.Framework.Interfaces; using OpenSim.Region.Framework.Scenes; [assembly: Addin("DataSnapshot", "0.1")] -[assembly: AddinDependency("OpenSim", "0.8.1")] +[assembly: AddinDependency("OpenSim.Region.Framework", "0.8.1")] namespace OpenSim.Region.DataSnapshot { diff --git a/OpenSim/Region/Framework/Interfaces/IRegionModuleBase.cs b/OpenSim/Region/Framework/Interfaces/IRegionModuleBase.cs index 9b1e4ca..2089bce 100644 --- a/OpenSim/Region/Framework/Interfaces/IRegionModuleBase.cs +++ b/OpenSim/Region/Framework/Interfaces/IRegionModuleBase.cs @@ -32,6 +32,7 @@ using OpenSim.Region.Framework.Scenes; namespace OpenSim.Region.Framework.Interfaces { + [TypeExtensionPoint(Path = "/OpenSim/RegionModules", NodeName="RegionModule")] public interface IRegionModuleBase { /// diff --git a/OpenSim/Region/Framework/Interfaces/IWindModelPlugin.cs b/OpenSim/Region/Framework/Interfaces/IWindModelPlugin.cs index b087c8b..16b6024 100644 --- a/OpenSim/Region/Framework/Interfaces/IWindModelPlugin.cs +++ b/OpenSim/Region/Framework/Interfaces/IWindModelPlugin.cs @@ -33,8 +33,11 @@ using OpenSim.Framework; using OpenMetaverse; using OpenSim.Region.Framework.Scenes; +using Mono.Addins; + namespace OpenSim.Region.Framework.Interfaces { + [TypeExtensionPoint(Path = "/OpenSim/WindModule", NodeName = "WindModel")] public interface IWindModelPlugin : IPlugin { /// diff --git a/OpenSim/Region/Framework/Properties/AssemblyInfo.cs b/OpenSim/Region/Framework/Properties/AssemblyInfo.cs index 3692e28..6fe2892 100644 --- a/OpenSim/Region/Framework/Properties/AssemblyInfo.cs +++ b/OpenSim/Region/Framework/Properties/AssemblyInfo.cs @@ -1,6 +1,7 @@ using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; +using Mono.Addins; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information @@ -22,6 +23,7 @@ using System.Runtime.InteropServices; // The following GUID is for the ID of the typelib if this project is exposed to COM [assembly: Guid("d25e7aed-7f55-4bb8-9970-0d7d978ea8a5")] + // Version information for an assembly consists of the following four values: // // Major Version @@ -30,4 +32,5 @@ using System.Runtime.InteropServices; // Revision // [assembly: AssemblyVersion("0.8.1.*")] +[assembly: AddinRoot("OpenSim.Region.Framework", "0.8.1")] diff --git a/OpenSim/Region/OptionalModules/Properties/AssemblyInfo.cs b/OpenSim/Region/OptionalModules/Properties/AssemblyInfo.cs index 2fd412c..3f53229 100644 --- a/OpenSim/Region/OptionalModules/Properties/AssemblyInfo.cs +++ b/OpenSim/Region/OptionalModules/Properties/AssemblyInfo.cs @@ -34,4 +34,4 @@ using Mono.Addins; [assembly: Addin("OpenSim.Region.OptionalModules", "0.1")] -[assembly: AddinDependency("OpenSim", "0.8.1")] +[assembly: AddinDependency("OpenSim.Region.Framework", "0.8.1")] diff --git a/OpenSim/Region/UserStatistics/WebStatsModule.cs b/OpenSim/Region/UserStatistics/WebStatsModule.cs index 7e57e64..57a2502 100644 --- a/OpenSim/Region/UserStatistics/WebStatsModule.cs +++ b/OpenSim/Region/UserStatistics/WebStatsModule.cs @@ -51,7 +51,7 @@ using OSD = OpenMetaverse.StructuredData.OSD; using OSDMap = OpenMetaverse.StructuredData.OSDMap; [assembly: Addin("WebStats", "1.0")] -[assembly: AddinDependency("OpenSim", "0.8.1")] +[assembly: AddinDependency("OpenSim.Region.Framework", "0.8.1")] namespace OpenSim.Region.UserStatistics { diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianGrid.cs b/OpenSim/Services/Connectors/SimianGrid/SimianGrid.cs index e9cad54..46fda23 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianGrid.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianGrid.cs @@ -40,7 +40,7 @@ using OpenMetaverse; using OpenMetaverse.StructuredData; [assembly: Addin("SimianGrid", "1.0")] -[assembly: AddinDependency("OpenSim", "0.8.1")] +[assembly: AddinDependency("OpenSim.Region.Framework", "0.8.1")] namespace OpenSim.Services.Connectors.SimianGrid { diff --git a/bin/OpenSim.addin.xml b/bin/OpenSim.addin.xml deleted file mode 100644 index 305344a..0000000 --- a/bin/OpenSim.addin.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - - - - - - - - - - - - - -- cgit v1.1