* Removed Simian.IsSimianEnabled() call, changed the SimianGrid connectors to handle initialization as graceful as possible with the current broken way region module initialization is done
* Added config-include/HyperSimianGrid.ini option for connecting to SimianGrid with HyperGrid enabled (work in progress on the SimianGrid side)prebuild-update
parent
21c5377af9
commit
4f79143f3f
|
@ -84,30 +84,23 @@ namespace OpenSim.Services.Connectors.SimianGrid
|
|||
}
|
||||
|
||||
public void Initialise(IConfigSource source)
|
||||
{
|
||||
if (Simian.IsSimianEnabled(source, "AssetServices", this.Name))
|
||||
{
|
||||
IConfig gridConfig = source.Configs["AssetService"];
|
||||
if (gridConfig == null)
|
||||
if (gridConfig != null)
|
||||
{
|
||||
m_log.Error("[SIMIAN ASSET CONNECTOR]: AssetService missing from OpenSim.ini");
|
||||
throw new Exception("Asset connector init error");
|
||||
}
|
||||
|
||||
string serviceUrl = gridConfig.GetString("AssetServerURI");
|
||||
if (String.IsNullOrEmpty(serviceUrl))
|
||||
if (!String.IsNullOrEmpty(serviceUrl))
|
||||
{
|
||||
m_log.Error("[SIMIAN ASSET CONNECTOR]: No AssetServerURI in section AssetService");
|
||||
throw new Exception("Asset connector init error");
|
||||
}
|
||||
|
||||
if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("="))
|
||||
serviceUrl = serviceUrl + '/';
|
||||
|
||||
m_serverUrl = serviceUrl;
|
||||
}
|
||||
}
|
||||
|
||||
if (String.IsNullOrEmpty(m_serverUrl))
|
||||
m_log.Info("[SIMIAN ASSET CONNECTOR]: No AssetServerURI specified, disabling connector");
|
||||
}
|
||||
|
||||
#region IAssetService
|
||||
|
||||
public AssetBase Get(string id)
|
||||
|
|
|
@ -73,24 +73,20 @@ namespace OpenSim.Services.Connectors.SimianGrid
|
|||
|
||||
public void Initialise(IConfigSource source)
|
||||
{
|
||||
if (Simian.IsSimianEnabled(source, "AuthenticationServices", this.Name))
|
||||
IConfig gridConfig = source.Configs["AuthenticationService"];
|
||||
if (gridConfig != null)
|
||||
{
|
||||
IConfig assetConfig = source.Configs["AuthenticationService"];
|
||||
if (assetConfig == null)
|
||||
string serviceUrl = gridConfig.GetString("AuthenticationServerURI");
|
||||
if (!String.IsNullOrEmpty(serviceUrl))
|
||||
{
|
||||
m_log.Error("[SIMIAN AUTH CONNECTOR]: AuthenticationService missing from OpenSim.ini");
|
||||
throw new Exception("Authentication connector init error");
|
||||
if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("="))
|
||||
serviceUrl = serviceUrl + '/';
|
||||
m_serverUrl = serviceUrl;
|
||||
}
|
||||
}
|
||||
|
||||
string serviceURI = assetConfig.GetString("AuthenticationServerURI");
|
||||
if (String.IsNullOrEmpty(serviceURI))
|
||||
{
|
||||
m_log.Error("[SIMIAN AUTH CONNECTOR]: No Server URI named in section AuthenticationService");
|
||||
throw new Exception("Authentication connector init error");
|
||||
}
|
||||
|
||||
m_serverUrl = serviceURI;
|
||||
}
|
||||
if (String.IsNullOrEmpty(m_serverUrl))
|
||||
m_log.Info("[SIMIAN AUTH CONNECTOR]: No AuthenticationServerURI specified, disabling connector");
|
||||
}
|
||||
|
||||
public string Authenticate(UUID principalID, string password, int lifetime)
|
||||
|
|
|
@ -77,30 +77,23 @@ namespace OpenSim.Services.Connectors.SimianGrid
|
|||
}
|
||||
|
||||
public void Initialise(IConfigSource source)
|
||||
{
|
||||
if (Simian.IsSimianEnabled(source, "AvatarServices", this.Name))
|
||||
{
|
||||
IConfig gridConfig = source.Configs["AvatarService"];
|
||||
if (gridConfig == null)
|
||||
if (gridConfig != null)
|
||||
{
|
||||
m_log.Error("[SIMIAN AVATAR CONNECTOR]: AvatarService missing from OpenSim.ini");
|
||||
throw new Exception("Avatar connector init error");
|
||||
}
|
||||
|
||||
string serviceUrl = gridConfig.GetString("AvatarServerURI");
|
||||
if (String.IsNullOrEmpty(serviceUrl))
|
||||
if (!String.IsNullOrEmpty(serviceUrl))
|
||||
{
|
||||
m_log.Error("[SIMIAN AVATAR CONNECTOR]: No AvatarServerURI in section AvatarService");
|
||||
throw new Exception("Avatar connector init error");
|
||||
}
|
||||
|
||||
if (!serviceUrl.EndsWith("/"))
|
||||
if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("="))
|
||||
serviceUrl = serviceUrl + '/';
|
||||
|
||||
m_serverUrl = serviceUrl;
|
||||
}
|
||||
}
|
||||
|
||||
if (String.IsNullOrEmpty(m_serverUrl))
|
||||
m_log.Info("[SIMIAN AVATAR CONNECTOR]: No AvatarServerURI specified, disabling connector");
|
||||
}
|
||||
|
||||
#region IAvatarService
|
||||
|
||||
public AvatarData GetAvatar(UUID userID)
|
||||
|
|
|
@ -31,17 +31,3 @@ using Nini.Config;
|
|||
|
||||
[assembly: Addin("SimianGrid", "1.0")]
|
||||
[assembly: AddinDependency("OpenSim", "0.5")]
|
||||
|
||||
public static class Simian
|
||||
{
|
||||
public static bool IsSimianEnabled(IConfigSource config, string moduleName, string connectorName)
|
||||
{
|
||||
if (config.Configs["Modules"] != null)
|
||||
{
|
||||
string module = config.Configs["Modules"].GetString(moduleName);
|
||||
return !String.IsNullOrEmpty(module) && module.EndsWith(connectorName);
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
|
@ -97,27 +97,23 @@ namespace OpenSim.Services.Connectors.SimianGrid
|
|||
}
|
||||
|
||||
public void Initialise(IConfigSource source)
|
||||
{
|
||||
if (Simian.IsSimianEnabled(source, "GridServices", this.Name))
|
||||
{
|
||||
IConfig gridConfig = source.Configs["GridService"];
|
||||
if (gridConfig == null)
|
||||
if (gridConfig != null)
|
||||
{
|
||||
m_log.Error("[SIMIAN GRID CONNECTOR]: GridService missing from OpenSim.ini");
|
||||
throw new Exception("Grid connector init error");
|
||||
}
|
||||
|
||||
string serviceUrl = gridConfig.GetString("GridServerURI");
|
||||
if (String.IsNullOrEmpty(serviceUrl))
|
||||
if (!String.IsNullOrEmpty(serviceUrl))
|
||||
{
|
||||
m_log.Error("[SIMIAN GRID CONNECTOR]: No Server URI named in section GridService");
|
||||
throw new Exception("Grid connector init error");
|
||||
}
|
||||
|
||||
if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("="))
|
||||
serviceUrl = serviceUrl + '/';
|
||||
m_serverUrl = serviceUrl;
|
||||
}
|
||||
}
|
||||
|
||||
if (String.IsNullOrEmpty(m_serverUrl))
|
||||
m_log.Info("[SIMIAN GRID CONNECTOR]: No GridServerURI specified, disabling connector");
|
||||
}
|
||||
|
||||
#region IGridService
|
||||
|
||||
public string RegisterRegion(UUID scopeID, GridRegion regionInfo)
|
||||
|
|
|
@ -91,23 +91,15 @@ namespace OpenSim.Services.Connectors.SimianGrid
|
|||
}
|
||||
|
||||
public void Initialise(IConfigSource source)
|
||||
{
|
||||
if (Simian.IsSimianEnabled(source, "InventoryServices", this.Name))
|
||||
{
|
||||
IConfig gridConfig = source.Configs["InventoryService"];
|
||||
if (gridConfig == null)
|
||||
if (gridConfig != null)
|
||||
{
|
||||
m_log.Error("[SIMIAN INVENTORY CONNECTOR]: InventoryService missing from OpenSim.ini");
|
||||
throw new Exception("Inventory connector init error");
|
||||
}
|
||||
|
||||
string serviceUrl = gridConfig.GetString("InventoryServerURI");
|
||||
if (String.IsNullOrEmpty(serviceUrl))
|
||||
if (!String.IsNullOrEmpty(serviceUrl))
|
||||
{
|
||||
m_log.Error("[SIMIAN INVENTORY CONNECTOR]: No Server URI named in section InventoryService");
|
||||
throw new Exception("Inventory connector init error");
|
||||
}
|
||||
|
||||
if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("="))
|
||||
serviceUrl = serviceUrl + '/';
|
||||
m_serverUrl = serviceUrl;
|
||||
|
||||
gridConfig = source.Configs["UserAccountService"];
|
||||
|
@ -116,16 +108,16 @@ namespace OpenSim.Services.Connectors.SimianGrid
|
|||
serviceUrl = gridConfig.GetString("UserAccountServerURI");
|
||||
if (!String.IsNullOrEmpty(serviceUrl))
|
||||
m_userServerUrl = serviceUrl;
|
||||
else
|
||||
m_log.Info("[SIMIAN INVENTORY CONNECTOR]: No Server URI named in section UserAccountService");
|
||||
}
|
||||
else
|
||||
{
|
||||
m_log.Warn("[SIMIAN INVENTORY CONNECTOR]: UserAccountService missing from OpenSim.ini");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (String.IsNullOrEmpty(m_serverUrl))
|
||||
m_log.Info("[SIMIAN INVENTORY CONNECTOR]: No InventoryServerURI specified, disabling connector");
|
||||
else if (String.IsNullOrEmpty(m_userServerUrl))
|
||||
m_log.Info("[SIMIAN INVENTORY CONNECTOR]: No UserAccountServerURI specified, disabling connector");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Create the entire inventory for a given user
|
||||
/// </summary>
|
||||
|
|
|
@ -102,27 +102,23 @@ namespace OpenSim.Services.Connectors.SimianGrid
|
|||
}
|
||||
|
||||
public void Initialise(IConfigSource source)
|
||||
{
|
||||
if (Simian.IsSimianEnabled(source, "PresenceServices", this.Name))
|
||||
{
|
||||
IConfig gridConfig = source.Configs["PresenceService"];
|
||||
if (gridConfig == null)
|
||||
if (gridConfig != null)
|
||||
{
|
||||
m_log.Error("[SIMIAN PRESENCE CONNECTOR]: PresenceService missing from OpenSim.ini");
|
||||
throw new Exception("Presence connector init error");
|
||||
}
|
||||
|
||||
string serviceUrl = gridConfig.GetString("PresenceServerURI");
|
||||
if (String.IsNullOrEmpty(serviceUrl))
|
||||
if (!String.IsNullOrEmpty(serviceUrl))
|
||||
{
|
||||
m_log.Error("[SIMIAN PRESENCE CONNECTOR]: No PresenceServerURI in section PresenceService");
|
||||
throw new Exception("Presence connector init error");
|
||||
}
|
||||
|
||||
if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("="))
|
||||
serviceUrl = serviceUrl + '/';
|
||||
m_serverUrl = serviceUrl;
|
||||
}
|
||||
}
|
||||
|
||||
if (String.IsNullOrEmpty(m_serverUrl))
|
||||
m_log.Info("[SIMIAN PRESENCE CONNECTOR]: No PresenceServerURI specified, disabling connector");
|
||||
}
|
||||
|
||||
#region IPresenceService
|
||||
|
||||
public bool LoginAgent(string userID, UUID sessionID, UUID secureSessionID)
|
||||
|
|
|
@ -87,45 +87,21 @@ namespace OpenSim.Services.Connectors.SimianGrid
|
|||
}
|
||||
|
||||
public void Initialise(IConfigSource source)
|
||||
{
|
||||
if (Simian.IsSimianEnabled(source, "UserAccountServices", "SimianUserAccountServiceConnector"))
|
||||
{
|
||||
IConfig gridConfig = source.Configs["UserAccountService"];
|
||||
if (gridConfig == null)
|
||||
if (gridConfig != null)
|
||||
{
|
||||
m_log.Error("[SIMIAN PROFILES]: UserAccountService missing from OpenSim.ini");
|
||||
throw new Exception("Profiles init error");
|
||||
}
|
||||
|
||||
string serviceUrl = gridConfig.GetString("UserAccountServerURI");
|
||||
if (String.IsNullOrEmpty(serviceUrl))
|
||||
if (!String.IsNullOrEmpty(serviceUrl))
|
||||
{
|
||||
m_log.Error("[SIMIAN PROFILES]: No UserAccountServerURI in section UserAccountService");
|
||||
throw new Exception("Profiles init error");
|
||||
}
|
||||
|
||||
if (!serviceUrl.EndsWith("/"))
|
||||
if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("="))
|
||||
serviceUrl = serviceUrl + '/';
|
||||
|
||||
m_serverUrl = serviceUrl;
|
||||
IConfig profilesConfig = source.Configs["Profiles"];
|
||||
if (profilesConfig == null)
|
||||
{
|
||||
// Do not run this module by default.
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
// if profiles aren't enabled, we're not needed.
|
||||
// if we're not specified as the connector to use, then we're not wanted
|
||||
if (profilesConfig.GetString("Module", String.Empty) != Name)
|
||||
{
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
m_log.InfoFormat("[SIMIAN ACCOUNT CONNECTOR]: Initializing {0}", this.Name);
|
||||
}
|
||||
}
|
||||
if (String.IsNullOrEmpty(m_serverUrl))
|
||||
m_log.Info("[SIMIAN PROFILES]: No UserAccountServerURI specified, disabling connector");
|
||||
}
|
||||
|
||||
private void ClientConnectHandler(IClientCore clientCore)
|
||||
|
|
|
@ -77,25 +77,20 @@ namespace OpenSim.Services.Connectors.SimianGrid
|
|||
|
||||
public void Initialise(IConfigSource source)
|
||||
{
|
||||
if (Simian.IsSimianEnabled(source, "UserAccountServices", this.Name))
|
||||
IConfig gridConfig = source.Configs["UserAccountService"];
|
||||
if (gridConfig != null)
|
||||
{
|
||||
IConfig assetConfig = source.Configs["UserAccountService"];
|
||||
if (assetConfig == null)
|
||||
string serviceUrl = gridConfig.GetString("UserAccountServerURI");
|
||||
if (!String.IsNullOrEmpty(serviceUrl))
|
||||
{
|
||||
m_log.Error("[SIMIAN ACCOUNT CONNECTOR]: UserAccountService missing from OpenSim.ini");
|
||||
throw new Exception("User account connector init error");
|
||||
if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("="))
|
||||
serviceUrl = serviceUrl + '/';
|
||||
m_serverUrl = serviceUrl;
|
||||
}
|
||||
}
|
||||
|
||||
string serviceURI = assetConfig.GetString("UserAccountServerURI");
|
||||
if (String.IsNullOrEmpty(serviceURI))
|
||||
{
|
||||
m_log.Error("[SIMIAN ACCOUNT CONNECTOR]: No UserAccountServerURI in section UserAccountService, skipping SimianUserAccountServiceConnector");
|
||||
throw new Exception("User account connector init error");
|
||||
}
|
||||
|
||||
m_accountCache = new ExpiringCache<UUID, UserAccount>();
|
||||
m_serverUrl = serviceURI;
|
||||
}
|
||||
if (String.IsNullOrEmpty(m_serverUrl))
|
||||
m_log.Info("[SIMIAN ACCOUNT CONNECTOR]: No UserAccountServerURI specified, disabling connector");
|
||||
}
|
||||
|
||||
public UserAccount GetUserAccount(UUID scopeID, string firstName, string lastName)
|
||||
|
|
|
@ -1304,6 +1304,7 @@
|
|||
;Include-Grid = "config-include/Grid.ini"
|
||||
;Include-HGGrid = "config-include/GridHypergrid.ini"
|
||||
;Include-SimianGrid = "config-include/SimianGrid.ini"
|
||||
;Include-HyperSimianGrid = "config-include/HyperSimianGrid.ini"
|
||||
|
||||
; Then choose
|
||||
; config-include/StandaloneCommon.ini.example (if you're in standlone) OR
|
||||
|
|
|
@ -0,0 +1,77 @@
|
|||
;;
|
||||
;; Please don't change this file.
|
||||
;; All optional settings are in GridCommon.ini.example,
|
||||
;; which you can copy and change.
|
||||
;;
|
||||
|
||||
;;
|
||||
;; In GridCommon.ini, these are the URLs you would use if SimianGrid is
|
||||
;; installed at http://www.mygrid.com/Grid/
|
||||
;;
|
||||
; AssetServerURI = "http://www.mygrid.com/Grid/?id="
|
||||
; InventoryServerURI = "http://www.mygrid.com/Grid/"
|
||||
; AvatarServerURI = "http://www.mygrid.com/Grid/"
|
||||
; PresenceServerURI = "http://www.mygrid.com/Grid/"
|
||||
; UserAccountServerURI = "http://www.mygrid.com/Grid/"
|
||||
; AuthenticationServerURI = "http://www.mygrid.com/Grid/"
|
||||
; FriendsServerURI = "http://www.mygrid.com/Grid/"
|
||||
; GroupsServerURI = "http://www.mygrid.com/Grid/"
|
||||
|
||||
[Includes]
|
||||
Include-Common = "config-include/GridCommon.ini"
|
||||
|
||||
[Modules]
|
||||
GridServices = "OpenSim.Services.Connectors.dll:SimianGridServiceConnector"
|
||||
PresenceServices = "OpenSim.Services.Connectors.dll:SimianPresenceServiceConnector"
|
||||
UserAccountServices = "OpenSim.Services.Connectors.dll:SimianUserAccountServiceConnector"
|
||||
AuthenticationServices = "OpenSim.Services.Connectors.dll:SimianAuthenticationServiceConnector"
|
||||
AssetServices = "HGAssetBroker"
|
||||
InventoryServices = "HGInventoryBroker"
|
||||
AvatarServices = "OpenSim.Services.Connectors.dll:SimianAvatarServiceConnector"
|
||||
|
||||
NeighbourServices = "RemoteNeighbourServicesConnector"
|
||||
SimulationServices = "RemoteSimulationConnectorModule"
|
||||
EntityTransferModule = "HGEntityTransferModule"
|
||||
InventoryAccessModule = "HGInventoryAccessModule"
|
||||
|
||||
LandServiceInConnector = true
|
||||
NeighbourServiceInConnector = true
|
||||
SimulationServiceInConnector = true
|
||||
LibraryModule = false
|
||||
|
||||
AssetCaching = "FlotsamAssetCache"
|
||||
|
||||
[Friends]
|
||||
Connector = "OpenSim.Services.Connectors.dll:SimianFriendsServiceConnector"
|
||||
|
||||
[GridService]
|
||||
LocalServiceModule = "OpenSim.Services.GridService.dll:GridService"
|
||||
StorageProvider = "OpenSim.Data.Null.dll:NullRegionData"
|
||||
|
||||
AllowHypergridMapSearch = true
|
||||
|
||||
[LibraryService]
|
||||
LocalServiceModule = "OpenSim.Services.InventoryService.dll:LibraryService"
|
||||
LibraryName = "OpenSim Library"
|
||||
DefaultLibrary = "./inventory/Libraries.xml"
|
||||
|
||||
[AssetService]
|
||||
DefaultAssetLoader = "OpenSim.Framework.AssetLoader.Filesystem.dll"
|
||||
LocalGridAssetService = "OpenSim.Services.Connectors.dll:SimianAssetServiceConnector"
|
||||
HypergridAssetService = "OpenSim.Services.Connectors.dll:HGAssetServiceConnector"
|
||||
AssetLoaderArgs = "assets/AssetSets.xml"
|
||||
|
||||
[InventoryService]
|
||||
LocalGridInventoryService = "OpenSim.Services.Connectors.dll:SimianInventoryServiceConnector"
|
||||
|
||||
[Groups]
|
||||
Enabled = true
|
||||
Module = GroupsModule
|
||||
DebugEnabled = false
|
||||
NoticesEnabled = true
|
||||
MessagingModule = GroupsMessagingModule
|
||||
MessagingEnabled = true
|
||||
ServicesConnectorModule = SimianGroupsServicesConnector
|
||||
|
||||
[Profiles]
|
||||
Module = SimianProfiles
|
Loading…
Reference in New Issue