diff options
author | Diva Canto | 2010-01-03 11:44:57 -0800 |
---|---|---|
committer | Diva Canto | 2010-01-03 11:44:57 -0800 |
commit | 99efa99585639c94fdb484681663ac7b6f03538e (patch) | |
tree | f74eb3e9c080e381d37b2d936ba9b0c091196f56 /OpenSim/Services | |
parent | * Changed ISimulation interface to take a GridRegion as input arg instead of ... (diff) | |
download | opensim-SC_OLD-99efa99585639c94fdb484681663ac7b6f03538e.zip opensim-SC_OLD-99efa99585639c94fdb484681663ac7b6f03538e.tar.gz opensim-SC_OLD-99efa99585639c94fdb484681663ac7b6f03538e.tar.bz2 opensim-SC_OLD-99efa99585639c94fdb484681663ac7b6f03538e.tar.xz |
Successfully logged into a grid.
Diffstat (limited to 'OpenSim/Services')
-rw-r--r-- | OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs | 13 | ||||
-rw-r--r-- | OpenSim/Services/LLLoginService/LLLoginService.cs | 11 |
2 files changed, 18 insertions, 6 deletions
diff --git a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs index fcf07c7..dc532d0 100644 --- a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs +++ b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs | |||
@@ -39,6 +39,7 @@ using GridRegion = OpenSim.Services.Interfaces.GridRegion; | |||
39 | using OpenMetaverse; | 39 | using OpenMetaverse; |
40 | using OpenMetaverse.StructuredData; | 40 | using OpenMetaverse.StructuredData; |
41 | using log4net; | 41 | using log4net; |
42 | using Nini.Config; | ||
42 | 43 | ||
43 | namespace OpenSim.Services.Connectors.Simulation | 44 | namespace OpenSim.Services.Connectors.Simulation |
44 | { | 45 | { |
@@ -52,7 +53,7 @@ namespace OpenSim.Services.Connectors.Simulation | |||
52 | { | 53 | { |
53 | } | 54 | } |
54 | 55 | ||
55 | public SimulationServiceConnector(GridRegion region) | 56 | public SimulationServiceConnector(IConfigSource config) |
56 | { | 57 | { |
57 | //m_Region = region; | 58 | //m_Region = region; |
58 | } | 59 | } |
@@ -68,6 +69,13 @@ namespace OpenSim.Services.Connectors.Simulation | |||
68 | { | 69 | { |
69 | reason = String.Empty; | 70 | reason = String.Empty; |
70 | 71 | ||
72 | if (destination == null) | ||
73 | { | ||
74 | reason = "Destination is null"; | ||
75 | m_log.Debug("[REMOTE SIMULATION CONNECTOR]: Given destination is null"); | ||
76 | return false; | ||
77 | } | ||
78 | |||
71 | // Eventually, we want to use a caps url instead of the agentID | 79 | // Eventually, we want to use a caps url instead of the agentID |
72 | string uri = string.Empty; | 80 | string uri = string.Empty; |
73 | try | 81 | try |
@@ -128,7 +136,8 @@ namespace OpenSim.Services.Connectors.Simulation | |||
128 | AgentCreateRequest.ContentLength = buffer.Length; //Count bytes to send | 136 | AgentCreateRequest.ContentLength = buffer.Length; //Count bytes to send |
129 | os = AgentCreateRequest.GetRequestStream(); | 137 | os = AgentCreateRequest.GetRequestStream(); |
130 | os.Write(buffer, 0, strBuffer.Length); //Send it | 138 | os.Write(buffer, 0, strBuffer.Length); //Send it |
131 | //m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: Posted CreateChildAgent request to remote sim {0}", uri); | 139 | m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: Posted CreateAgent request to remote sim {0}, region {1}, x={2} y={3}", |
140 | uri, destination.RegionName, destination.RegionLocX, destination.RegionLocY); | ||
132 | } | 141 | } |
133 | //catch (WebException ex) | 142 | //catch (WebException ex) |
134 | catch | 143 | catch |
diff --git a/OpenSim/Services/LLLoginService/LLLoginService.cs b/OpenSim/Services/LLLoginService/LLLoginService.cs index 638fa9f..2ae552f 100644 --- a/OpenSim/Services/LLLoginService/LLLoginService.cs +++ b/OpenSim/Services/LLLoginService/LLLoginService.cs | |||
@@ -26,11 +26,11 @@ namespace OpenSim.Services.LLLoginService | |||
26 | private IGridService m_GridService; | 26 | private IGridService m_GridService; |
27 | private IPresenceService m_PresenceService; | 27 | private IPresenceService m_PresenceService; |
28 | private ISimulationService m_LocalSimulationService; | 28 | private ISimulationService m_LocalSimulationService; |
29 | private ISimulationService m_RemoteSimulationService; | ||
29 | private ILibraryService m_LibraryService; | 30 | private ILibraryService m_LibraryService; |
30 | private IAvatarService m_AvatarService; | 31 | private IAvatarService m_AvatarService; |
31 | 32 | ||
32 | private string m_DefaultRegionName; | 33 | private string m_DefaultRegionName; |
33 | private string m_RemoteSimulationDll; | ||
34 | private string m_WelcomeMessage; | 34 | private string m_WelcomeMessage; |
35 | private bool m_RequireInventory; | 35 | private bool m_RequireInventory; |
36 | 36 | ||
@@ -47,9 +47,9 @@ namespace OpenSim.Services.LLLoginService | |||
47 | string presenceService = serverConfig.GetString("PresenceService", String.Empty); | 47 | string presenceService = serverConfig.GetString("PresenceService", String.Empty); |
48 | string libService = serverConfig.GetString("LibraryService", String.Empty); | 48 | string libService = serverConfig.GetString("LibraryService", String.Empty); |
49 | string avatarService = serverConfig.GetString("AvatarService", String.Empty); | 49 | string avatarService = serverConfig.GetString("AvatarService", String.Empty); |
50 | string simulationService = serverConfig.GetString("SimulationService", String.Empty); | ||
50 | 51 | ||
51 | m_DefaultRegionName = serverConfig.GetString("DefaultRegion", String.Empty); | 52 | m_DefaultRegionName = serverConfig.GetString("DefaultRegion", String.Empty); |
52 | m_RemoteSimulationDll = serverConfig.GetString("RemoteSimulationService", String.Empty); | ||
53 | m_WelcomeMessage = serverConfig.GetString("WelcomeMessage", "Welcome to OpenSim!"); | 53 | m_WelcomeMessage = serverConfig.GetString("WelcomeMessage", "Welcome to OpenSim!"); |
54 | m_RequireInventory = serverConfig.GetBoolean("RequireInventory", true); | 54 | m_RequireInventory = serverConfig.GetBoolean("RequireInventory", true); |
55 | 55 | ||
@@ -67,6 +67,8 @@ namespace OpenSim.Services.LLLoginService | |||
67 | m_PresenceService = ServerUtils.LoadPlugin<IPresenceService>(presenceService, args); | 67 | m_PresenceService = ServerUtils.LoadPlugin<IPresenceService>(presenceService, args); |
68 | if (avatarService != string.Empty) | 68 | if (avatarService != string.Empty) |
69 | m_AvatarService = ServerUtils.LoadPlugin<IAvatarService>(avatarService, args); | 69 | m_AvatarService = ServerUtils.LoadPlugin<IAvatarService>(avatarService, args); |
70 | if (simulationService != string.Empty) | ||
71 | m_RemoteSimulationService = ServerUtils.LoadPlugin<ISimulationService>(simulationService, args); | ||
70 | // | 72 | // |
71 | // deal with the services given as argument | 73 | // deal with the services given as argument |
72 | // | 74 | // |
@@ -184,8 +186,8 @@ namespace OpenSim.Services.LLLoginService | |||
184 | // independent login servers have just a remoteSimulationDll | 186 | // independent login servers have just a remoteSimulationDll |
185 | if (!startLocation.Contains("@") && (m_LocalSimulationService != null)) | 187 | if (!startLocation.Contains("@") && (m_LocalSimulationService != null)) |
186 | simConnector = m_LocalSimulationService; | 188 | simConnector = m_LocalSimulationService; |
187 | else if (m_RemoteSimulationDll != string.Empty) | 189 | else if (m_RemoteSimulationService != null) |
188 | simConnector = ServerUtils.LoadPlugin<ISimulationService>(m_RemoteSimulationDll, args); | 190 | simConnector = m_RemoteSimulationService; |
189 | if (simConnector != null) | 191 | if (simConnector != null) |
190 | { | 192 | { |
191 | circuitCode = (uint)Util.RandomClass.Next(); ; | 193 | circuitCode = (uint)Util.RandomClass.Next(); ; |
@@ -362,6 +364,7 @@ namespace OpenSim.Services.LLLoginService | |||
362 | //aCircuit.BaseFolder = irrelevant | 364 | //aCircuit.BaseFolder = irrelevant |
363 | aCircuit.CapsPath = CapsUtil.GetRandomCapsObjectPath(); | 365 | aCircuit.CapsPath = CapsUtil.GetRandomCapsObjectPath(); |
364 | aCircuit.child = false; // the first login agent is root | 366 | aCircuit.child = false; // the first login agent is root |
367 | aCircuit.ChildrenCapSeeds = new Dictionary<ulong, string>(); | ||
365 | aCircuit.circuitcode = circuit; | 368 | aCircuit.circuitcode = circuit; |
366 | aCircuit.firstname = account.FirstName; | 369 | aCircuit.firstname = account.FirstName; |
367 | //aCircuit.InventoryFolder = irrelevant | 370 | //aCircuit.InventoryFolder = irrelevant |