diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianAssetServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianAssetServiceConnector.cs index 9fb7723b1d..201bc7082f 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianAssetServiceConnector.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianAssetServiceConnector.cs @@ -46,7 +46,7 @@ namespace OpenSim.Services.Connectors.SimianGrid /// Connects to the SimianGrid asset service /// [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] - public class SimianAssetServiceConnector : IAssetService, ISharedRegionModule + public class SimianAssetServiceConnector : IAssetService { private static readonly ILog m_log = LogManager.GetLogger( diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianAuthenticationServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianAuthenticationServiceConnector.cs index ec66341477..25e04d7578 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianAuthenticationServiceConnector.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianAuthenticationServiceConnector.cs @@ -44,7 +44,7 @@ namespace OpenSim.Services.Connectors.SimianGrid /// Connects authentication/authorization to the SimianGrid backend /// [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] - public class SimianAuthenticationServiceConnector : IAuthenticationService, ISharedRegionModule + public class SimianAuthenticationServiceConnector : IAuthenticationService { private static readonly ILog m_log = LogManager.GetLogger( diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianAvatarServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianAvatarServiceConnector.cs index 220f143c78..08403b9644 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianAvatarServiceConnector.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianAvatarServiceConnector.cs @@ -48,7 +48,7 @@ namespace OpenSim.Services.Connectors.SimianGrid /// Connects avatar appearance data to the SimianGrid backend /// [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] - public class SimianAvatarServiceConnector : IAvatarService, ISharedRegionModule + public class SimianAvatarServiceConnector : IAvatarService { private static readonly ILog m_log = LogManager.GetLogger( diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianFriendsServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianFriendsServiceConnector.cs index 3952a8c3d0..856381d324 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianFriendsServiceConnector.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianFriendsServiceConnector.cs @@ -47,7 +47,7 @@ namespace OpenSim.Services.Connectors.SimianGrid /// Stores and retrieves friend lists from the SimianGrid backend /// [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] - public class SimianFriendsServiceConnector : IFriendsService, ISharedRegionModule + public class SimianFriendsServiceConnector : IFriendsService { private static readonly ILog m_log = LogManager.GetLogger( diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianGridServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianGridServiceConnector.cs index 16819d174c..c375076514 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianGridServiceConnector.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianGridServiceConnector.cs @@ -51,7 +51,7 @@ namespace OpenSim.Services.Connectors.SimianGrid /// backend /// [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] - public class SimianGridServiceConnector : IGridService, ISharedRegionModule + public class SimianGridServiceConnector : IGridService { private static readonly ILog m_log = LogManager.GetLogger( diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs index c8128999c0..9879295e19 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs @@ -61,7 +61,7 @@ namespace OpenSim.Services.Connectors.SimianGrid /// Connects avatar inventories to the SimianGrid backend /// [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] - public class SimianInventoryServiceConnector : IInventoryService, ISharedRegionModule + public class SimianInventoryServiceConnector : IInventoryService { private static readonly ILog m_log = LogManager.GetLogger( diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianPresenceServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianPresenceServiceConnector.cs index 65de1c513c..45d18241d9 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianPresenceServiceConnector.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianPresenceServiceConnector.cs @@ -51,7 +51,7 @@ namespace OpenSim.Services.Connectors.SimianGrid /// message routing) to the SimianGrid backend /// [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] - public class SimianPresenceServiceConnector : IPresenceService, ISharedRegionModule + public class SimianPresenceServiceConnector : IPresenceService { private static readonly ILog m_log = LogManager.GetLogger( diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianProfiles.cs b/OpenSim/Services/Connectors/SimianGrid/SimianProfiles.cs index 1e19982da2..32f17ae105 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianProfiles.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianProfiles.cs @@ -60,7 +60,7 @@ namespace OpenSim.Services.Connectors.SimianGrid /// backend /// [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] - public class SimianProfiles : INonSharedRegionModule + public class SimianProfiles { private static readonly ILog m_log = LogManager.GetLogger( diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianUserAccountServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianUserAccountServiceConnector.cs index 14097d0bdc..708ced3a8f 100644 --- a/OpenSim/Services/Connectors/SimianGrid/SimianUserAccountServiceConnector.cs +++ b/OpenSim/Services/Connectors/SimianGrid/SimianUserAccountServiceConnector.cs @@ -47,7 +47,7 @@ namespace OpenSim.Services.Connectors.SimianGrid /// users) to the SimianGrid backend /// [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")] - public class SimianUserAccountServiceConnector : IUserAccountService, ISharedRegionModule + public class SimianUserAccountServiceConnector : IUserAccountService { private static readonly ILog m_log = LogManager.GetLogger( diff --git a/OpenSim/Tests/Common/Mock/MockUserAccountService.cs b/OpenSim/Tests/Common/Mock/MockUserAccountService.cs index f5d758a8c2..0769c7aa16 100644 --- a/OpenSim/Tests/Common/Mock/MockUserAccountService.cs +++ b/OpenSim/Tests/Common/Mock/MockUserAccountService.cs @@ -34,6 +34,7 @@ namespace OpenSim.Tests.Common.Mock { public class MockUserAccountService : IUserAccountService { + public MockUserAccountService(IConfigSource config) {} public UserAccount GetUserAccount(UUID scopeID, UUID userID) { return new UserAccount(); } diff --git a/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs b/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs index ab3e7cb976..864e2aa7c3 100644 --- a/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs +++ b/OpenSim/Tests/Common/Setup/SceneSetupHelpers.cs @@ -215,6 +215,9 @@ namespace OpenSim.Tests.Common.Setup testScene.PhysicsScene = physicsPluginManager.GetPhysicsScene("basicphysics", "ZeroMesher", new IniConfigSource(), "test"); + // It's really not a good idea to use static variables as they carry over between tests, leading to + // problems that are extremely hard to debug. Really, these static fields need to be eliminated - + // tests using multiple regions that need to share modules need to find another solution. m_assetService = null; m_inventoryService = null; m_gridService = null; diff --git a/bin/config-include/Standalone.ini b/bin/config-include/Standalone.ini index 30113708a1..54e11af432 100644 --- a/bin/config-include/Standalone.ini +++ b/bin/config-include/Standalone.ini @@ -32,14 +32,12 @@ [AvatarService] LocalServiceModule = "OpenSim.Services.AvatarService.dll:AvatarService" - ConnectionString = "URI=file:avatars.db,version=3" [AuthorizationService] LocalServiceModule = "OpenSim.Services.AuthorizationService.dll:AuthorizationService" [AuthenticationService] LocalServiceModule = "OpenSim.Services.AuthenticationService.dll:PasswordAuthenticationService" - ConnectionString = "URI=file:auth.db,version=3" [GridService] LocalServiceModule = "OpenSim.Services.GridService.dll:GridService" @@ -52,7 +50,6 @@ [UserAccountService] LocalServiceModule = "OpenSim.Services.UserAccountService.dll:UserAccountService" - ConnectionString = "URI=file:userprofiles.db,version=3" ;; These are for creating new accounts AuthenticationService = "OpenSim.Services.AuthenticationService.dll:PasswordAuthenticationService" @@ -62,7 +59,6 @@ [FriendsService] LocalServiceModule = "OpenSim.Services.FriendsService.dll" - ConnectionString = "URI=file:friends.db,version=3" [Friends] Connector = "OpenSim.Services.FriendsService.dll" diff --git a/bin/config-include/StandaloneCommon.ini.example b/bin/config-include/StandaloneCommon.ini.example index 8e21a8c477..f89c67a779 100644 --- a/bin/config-include/StandaloneCommon.ini.example +++ b/bin/config-include/StandaloneCommon.ini.example @@ -1,19 +1,24 @@ +; This is the main configuration file for standalone OpenSim instances + [DatabaseService] ; - ;### Choose the DB + ; ### Choose the DB ; - ;--- For SQLite - StorageProvider = "OpenSim.Data.SQLite.dll" - ;--- For MySql + + ; SQLite + ; Uncomment this line if you want to use sqlite storage + Include-Storage = "config-include/storage/SQLiteStandalone.ini"; + + ; For MySql. + ; Uncomment these lines if you want to use mysql storage + ; Change the connection string to your db details ;StorageProvider = "OpenSim.Data.MySQL.dll" ;ConnectionString = "Data Source=localhost;Database=opensim;User ID=opensim;Password=***;" [AssetService] - DefaultAssetLoader = "OpenSim.Framework.AssetLoader.Filesystem.dll" AssetLoaderArgs = "assets/AssetSets.xml" - [Modules] ;; Choose 0 or 1 cache modules, and the corresponding config file, if it exists. ;; Copy the config .example file into your own .ini file and change configs there @@ -35,10 +40,10 @@ [GridService] ;; For in-memory region storage (default) - StorageProvider = "OpenSim.Data.Null.dll:NullRegionData" + StorageProvider = "OpenSim.Data.Null.dll:NullRegionData" ;;--- For MySql region storage (alternative) - ;StorageProvider = "OpenSim.Data.MySQL.dll:MySqlRegionData" - ;ConnectionString = "Data Source=localhost;Database=opensim;User ID=opensim;Password=***;" + ;StorageProvider = "OpenSim.Data.MySQL.dll:MySqlRegionData" + ;; Next, we can specify properties of regions, including default and fallback regions ;; The syntax is: Region_ = "" ;; where can be DefaultRegion, FallbackRegion, NoDirectLogin, Persistent, LockedOut diff --git a/bin/config-include/storage/SQLiteStandalone.ini b/bin/config-include/storage/SQLiteStandalone.ini new file mode 100644 index 0000000000..1ce03578f2 --- /dev/null +++ b/bin/config-include/storage/SQLiteStandalone.ini @@ -0,0 +1,16 @@ +; These are the initialization settings for running OpenSim Standalone with an SQLite database + +[DatabaseService] + StorageProvider = "OpenSim.Data.SQLite.dll" + +[AvatarService] + ConnectionString = "URI=file:avatars.db,version=3" + +[AuthenticationService] + ConnectionString = "URI=file:auth.db,version=3" + +[UserAccountService] + ConnectionString = "URI=file:userprofiles.db,version=3" + +[FriendsService] + ConnectionString = "URI=file:friends.db,version=3"