NetworkServersInfo removed from CommsManager.
parent
cddd48aeea
commit
751e70af78
|
@ -36,9 +36,6 @@ using OpenSim.Framework.Communications.Cache;
|
||||||
using OpenSim.Framework.Communications.Osp;
|
using OpenSim.Framework.Communications.Osp;
|
||||||
using OpenSim.Framework.Servers;
|
using OpenSim.Framework.Servers;
|
||||||
using OpenSim.Framework.Servers.HttpServer;
|
using OpenSim.Framework.Servers.HttpServer;
|
||||||
using OpenSim.Region.Communications.Hypergrid;
|
|
||||||
using OpenSim.Region.Communications.Local;
|
|
||||||
using OpenSim.Region.Communications.OGS1;
|
|
||||||
|
|
||||||
namespace OpenSim.ApplicationPlugins.CreateCommsManager
|
namespace OpenSim.ApplicationPlugins.CreateCommsManager
|
||||||
{
|
{
|
||||||
|
@ -155,18 +152,12 @@ namespace OpenSim.ApplicationPlugins.CreateCommsManager
|
||||||
/// <param name="libraryRootFolder"></param>
|
/// <param name="libraryRootFolder"></param>
|
||||||
protected virtual void InitialiseStandaloneServices(LibraryRootFolder libraryRootFolder)
|
protected virtual void InitialiseStandaloneServices(LibraryRootFolder libraryRootFolder)
|
||||||
{
|
{
|
||||||
m_commsManager
|
|
||||||
= new CommunicationsLocal(
|
|
||||||
m_openSim.ConfigurationSettings, m_openSim.NetServersInfo,
|
|
||||||
libraryRootFolder);
|
|
||||||
|
|
||||||
CreateGridInfoService();
|
CreateGridInfoService();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected virtual void InitialiseGridServices(LibraryRootFolder libraryRootFolder)
|
protected virtual void InitialiseGridServices(LibraryRootFolder libraryRootFolder)
|
||||||
{
|
{
|
||||||
m_commsManager
|
|
||||||
= new CommunicationsOGS1(m_openSim.NetServersInfo, libraryRootFolder);
|
|
||||||
|
|
||||||
m_httpServer.AddStreamHandler(new OpenSim.SimStatusHandler());
|
m_httpServer.AddStreamHandler(new OpenSim.SimStatusHandler());
|
||||||
m_httpServer.AddStreamHandler(new OpenSim.XSimStatusHandler(m_openSim));
|
m_httpServer.AddStreamHandler(new OpenSim.XSimStatusHandler(m_openSim));
|
||||||
|
@ -176,20 +167,12 @@ namespace OpenSim.ApplicationPlugins.CreateCommsManager
|
||||||
|
|
||||||
protected virtual void InitialiseHGStandaloneServices(LibraryRootFolder libraryRootFolder)
|
protected virtual void InitialiseHGStandaloneServices(LibraryRootFolder libraryRootFolder)
|
||||||
{
|
{
|
||||||
m_commsManager
|
|
||||||
= new HGCommunicationsStandalone(
|
|
||||||
m_openSim.ConfigurationSettings, m_openSim.NetServersInfo, m_httpServer,
|
|
||||||
libraryRootFolder, false);
|
|
||||||
|
|
||||||
CreateGridInfoService();
|
CreateGridInfoService();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected virtual void InitialiseHGGridServices(LibraryRootFolder libraryRootFolder)
|
protected virtual void InitialiseHGGridServices(LibraryRootFolder libraryRootFolder)
|
||||||
{
|
{
|
||||||
m_commsManager
|
|
||||||
= new HGCommunicationsGridMode(
|
|
||||||
m_openSim.NetServersInfo,
|
|
||||||
m_openSim.SceneManager, libraryRootFolder);
|
|
||||||
|
|
||||||
m_httpServer.AddStreamHandler(new OpenSim.SimStatusHandler());
|
m_httpServer.AddStreamHandler(new OpenSim.SimStatusHandler());
|
||||||
m_httpServer.AddStreamHandler(new OpenSim.XSimStatusHandler(m_openSim));
|
m_httpServer.AddStreamHandler(new OpenSim.XSimStatusHandler(m_openSim));
|
||||||
|
|
|
@ -45,12 +45,6 @@ namespace OpenSim.Framework.Communications
|
||||||
{
|
{
|
||||||
//private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
//private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||||
|
|
||||||
public NetworkServersInfo NetworkServersInfo
|
|
||||||
{
|
|
||||||
get { return m_networkServersInfo; }
|
|
||||||
}
|
|
||||||
protected NetworkServersInfo m_networkServersInfo;
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Constructor
|
/// Constructor
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -58,7 +52,6 @@ namespace OpenSim.Framework.Communications
|
||||||
public CommunicationsManager(NetworkServersInfo serversInfo,
|
public CommunicationsManager(NetworkServersInfo serversInfo,
|
||||||
LibraryRootFolder libraryRootFolder)
|
LibraryRootFolder libraryRootFolder)
|
||||||
{
|
{
|
||||||
m_networkServersInfo = serversInfo;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -119,14 +119,15 @@ namespace OpenSim.Region.CoreModules.InterGrid
|
||||||
|
|
||||||
Hashtable requestData = (Hashtable)req.Params[0];
|
Hashtable requestData = (Hashtable)req.Params[0];
|
||||||
|
|
||||||
if ((!requestData.Contains("password") || (string)requestData["password"] != m_com.NetworkServersInfo.GridRecvKey))
|
// REFACTORING PROBLEM. This authorization needs to be replaced with some other
|
||||||
{
|
//if ((!requestData.Contains("password") || (string)requestData["password"] != m_com.NetworkServersInfo.GridRecvKey))
|
||||||
responseData["accepted"] = false;
|
//{
|
||||||
responseData["success"] = false;
|
// responseData["accepted"] = false;
|
||||||
responseData["error"] = "Invalid Key";
|
// responseData["success"] = false;
|
||||||
response.Value = responseData;
|
// responseData["error"] = "Invalid Key";
|
||||||
return response;
|
// response.Value = responseData;
|
||||||
}
|
// return response;
|
||||||
|
//}
|
||||||
|
|
||||||
string message = (string)requestData["message"];
|
string message = (string)requestData["message"];
|
||||||
string user = (string)requestData["user"];
|
string user = (string)requestData["user"];
|
||||||
|
|
|
@ -528,9 +528,9 @@ namespace OpenSim.Region.CoreModules.InterGrid
|
||||||
userProfile.PasswordHash = "$1$";
|
userProfile.PasswordHash = "$1$";
|
||||||
userProfile.PasswordSalt = "";
|
userProfile.PasswordSalt = "";
|
||||||
userProfile.SurName = agentData.lastname;
|
userProfile.SurName = agentData.lastname;
|
||||||
userProfile.UserAssetURI = homeScene.CommsManager.NetworkServersInfo.AssetURL;
|
//userProfile.UserAssetURI = homeScene.CommsManager.NetworkServersInfo.AssetURL;
|
||||||
userProfile.UserFlags = 0;
|
userProfile.UserFlags = 0;
|
||||||
userProfile.UserInventoryURI = homeScene.CommsManager.NetworkServersInfo.InventoryURL;
|
//userProfile.UserInventoryURI = homeScene.CommsManager.NetworkServersInfo.InventoryURL;
|
||||||
userProfile.WantDoMask = 0;
|
userProfile.WantDoMask = 0;
|
||||||
userProfile.WebLoginKey = UUID.Random();
|
userProfile.WebLoginKey = UUID.Random();
|
||||||
|
|
||||||
|
|
|
@ -155,12 +155,6 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Grid
|
||||||
|
|
||||||
((ISharedRegionModule)m_GridServiceConnector).AddRegion(scene);
|
((ISharedRegionModule)m_GridServiceConnector).AddRegion(scene);
|
||||||
|
|
||||||
// Yikes!! Remove this as soon as user services get refactored
|
|
||||||
LocalAssetServerURI = scene.CommsManager.NetworkServersInfo.AssetURL;
|
|
||||||
LocalInventoryServerURI = scene.CommsManager.NetworkServersInfo.InventoryURL;
|
|
||||||
LocalUserServerURI = scene.CommsManager.NetworkServersInfo.UserURL;
|
|
||||||
HGNetworkServersInfo.Init(LocalAssetServerURI, LocalInventoryServerURI, LocalUserServerURI);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void RemoveRegion(Scene scene)
|
public void RemoveRegion(Scene scene)
|
||||||
|
@ -760,7 +754,9 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Grid
|
||||||
|
|
||||||
protected bool IsComingHome(ForeignUserProfileData userData)
|
protected bool IsComingHome(ForeignUserProfileData userData)
|
||||||
{
|
{
|
||||||
return (userData.UserServerURI == LocalUserServerURI);
|
return false;
|
||||||
|
// REFACTORING PROBLEM
|
||||||
|
//return (userData.UserServerURI == LocalUserServerURI);
|
||||||
}
|
}
|
||||||
|
|
||||||
// REFACTORING PROBLEM
|
// REFACTORING PROBLEM
|
||||||
|
@ -787,13 +783,16 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Grid
|
||||||
|
|
||||||
protected bool IsLocalUser(UserAccount account)
|
protected bool IsLocalUser(UserAccount account)
|
||||||
{
|
{
|
||||||
if (account != null &&
|
return true;
|
||||||
account.ServiceURLs.ContainsKey("HomeURI") &&
|
|
||||||
account.ServiceURLs["HomeURI"] != null)
|
|
||||||
|
|
||||||
return (account.ServiceURLs["HomeURI"].ToString() == LocalUserServerURI);
|
// REFACTORING PROBLEM
|
||||||
|
//if (account != null &&
|
||||||
|
// account.ServiceURLs.ContainsKey("HomeURI") &&
|
||||||
|
// account.ServiceURLs["HomeURI"] != null)
|
||||||
|
|
||||||
return false;
|
// return (account.ServiceURLs["HomeURI"].ToString() == LocalUserServerURI);
|
||||||
|
|
||||||
|
//return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -61,9 +61,11 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Inventory
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
if (m_LocalGridInventoryURI == null || m_LocalGridInventoryURI == "")
|
return string.Empty;
|
||||||
m_LocalGridInventoryURI = m_Scene.CommsManager.NetworkServersInfo.InventoryURL;
|
// REFACTORING PROBLEM
|
||||||
return m_LocalGridInventoryURI;
|
//if (m_LocalGridInventoryURI == null || m_LocalGridInventoryURI == "")
|
||||||
|
// m_LocalGridInventoryURI = m_Scene.CommsManager.NetworkServersInfo.InventoryURL;
|
||||||
|
//return m_LocalGridInventoryURI;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -33,7 +33,6 @@ using OpenMetaverse;
|
||||||
using OpenSim.Framework;
|
using OpenSim.Framework;
|
||||||
using OpenSim.Framework.Communications;
|
using OpenSim.Framework.Communications;
|
||||||
using OpenSim.Framework.Communications.Cache;
|
using OpenSim.Framework.Communications.Cache;
|
||||||
using OpenSim.Region.Communications.Local;
|
|
||||||
using OpenSim.Region.Framework.Scenes;
|
using OpenSim.Region.Framework.Scenes;
|
||||||
using OpenSim.Tests.Common;
|
using OpenSim.Tests.Common;
|
||||||
using OpenSim.Tests.Common.Mock;
|
using OpenSim.Tests.Common.Mock;
|
||||||
|
|
|
@ -33,7 +33,6 @@ using OpenMetaverse;
|
||||||
using OpenSim.Framework;
|
using OpenSim.Framework;
|
||||||
using OpenSim.Framework.Communications;
|
using OpenSim.Framework.Communications;
|
||||||
using OpenSim.Framework.Communications.Cache;
|
using OpenSim.Framework.Communications.Cache;
|
||||||
using OpenSim.Region.Communications.Local;
|
|
||||||
using OpenSim.Region.Framework.Scenes;
|
using OpenSim.Region.Framework.Scenes;
|
||||||
using OpenSim.Tests.Common;
|
using OpenSim.Tests.Common;
|
||||||
using OpenSim.Tests.Common.Mock;
|
using OpenSim.Tests.Common.Mock;
|
||||||
|
|
|
@ -1159,12 +1159,13 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups
|
||||||
m_log.WarnFormat("[GROUPS]: Could not find a user profile for {0} / {1}", client.Name, client.AgentId);
|
m_log.WarnFormat("[GROUPS]: Could not find a user profile for {0} / {1}", client.Name, client.AgentId);
|
||||||
|
|
||||||
// Default to local user service and hope for the best?
|
// Default to local user service and hope for the best?
|
||||||
info.RequestID.UserServiceURL = m_sceneList[0].CommsManager.NetworkServersInfo.UserURL;
|
// REFACTORING PROBLEM
|
||||||
|
//info.RequestID.UserServiceURL = m_sceneList[0].CommsManager.NetworkServersInfo.UserURL;
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
string domain = m_sceneList[0].CommsManager.NetworkServersInfo.UserURL;
|
string domain = string.Empty; //m_sceneList[0].CommsManager.NetworkServersInfo.UserURL;
|
||||||
if (account.ServiceURLs["HomeURI"] != null)
|
if (account.ServiceURLs["HomeURI"] != null)
|
||||||
domain = account.ServiceURLs["HomeURI"].ToString();
|
domain = account.ServiceURLs["HomeURI"].ToString();
|
||||||
// They're a local user, use this:
|
// They're a local user, use this:
|
||||||
|
|
|
@ -30,7 +30,6 @@ using OpenSim.Framework.Communications;
|
||||||
using OpenSim.Framework.Communications.Cache;
|
using OpenSim.Framework.Communications.Cache;
|
||||||
using OpenSim.Framework.Servers;
|
using OpenSim.Framework.Servers;
|
||||||
using OpenSim.Framework.Servers.HttpServer;
|
using OpenSim.Framework.Servers.HttpServer;
|
||||||
using OpenSim.Region.Communications.Local;
|
|
||||||
using OpenSim.Data;
|
using OpenSim.Data;
|
||||||
|
|
||||||
namespace OpenSim.Tests.Common.Mock
|
namespace OpenSim.Tests.Common.Mock
|
||||||
|
|
|
@ -28,7 +28,6 @@
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
using OpenSim.Framework.Communications;
|
using OpenSim.Framework.Communications;
|
||||||
using OpenSim.Framework.Communications.Cache;
|
using OpenSim.Framework.Communications.Cache;
|
||||||
using OpenSim.Region.Communications.Local;
|
|
||||||
|
|
||||||
namespace OpenSim.Tests.Common.Setup
|
namespace OpenSim.Tests.Common.Setup
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue