aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules/ServiceConnectorsOut
diff options
context:
space:
mode:
authorDiva Canto2010-01-07 15:53:55 -0800
committerDiva Canto2010-01-07 15:53:55 -0800
commitf11a97f12d328af8bb39b92fec5cb5780983b66a (patch)
tree00f96f853b91e105786b416dd18f2c76e56fd1fd /OpenSim/Region/CoreModules/ServiceConnectorsOut
parentMerge branch 'master' into presence-refactor (diff)
downloadopensim-SC_OLD-f11a97f12d328af8bb39b92fec5cb5780983b66a.zip
opensim-SC_OLD-f11a97f12d328af8bb39b92fec5cb5780983b66a.tar.gz
opensim-SC_OLD-f11a97f12d328af8bb39b92fec5cb5780983b66a.tar.bz2
opensim-SC_OLD-f11a97f12d328af8bb39b92fec5cb5780983b66a.tar.xz
* Finished SimulationServiceConnector
* Started rerouting calls to UserService. * Compiles. May run.
Diffstat (limited to 'OpenSim/Region/CoreModules/ServiceConnectorsOut')
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsOut/Authorization/RemoteAuthorizationServiceConnector.cs6
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/RemotePresenceServiceConnector.cs2
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs19
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs11
4 files changed, 20 insertions, 18 deletions
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Authorization/RemoteAuthorizationServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Authorization/RemoteAuthorizationServiceConnector.cs
index 68499f3..01a2615 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Authorization/RemoteAuthorizationServiceConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Authorization/RemoteAuthorizationServiceConnector.cs
@@ -139,9 +139,9 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Authorization
139 139
140 if (scene != null) 140 if (scene != null)
141 { 141 {
142 UserProfileData profile = scene.CommsManager.UserService.GetUserProfile(new UUID(userID)); 142 UserAccount account = scene.UserAccountService.GetUserAccount(UUID.Zero, userID);
143 isAuthorized = IsAuthorizedForRegion(userID, profile.FirstName, profile.SurName, 143 isAuthorized = IsAuthorizedForRegion(userID, account.FirstName, account.LastName,
144 profile.Email, scene.RegionInfo.RegionName, regionID, out message); 144 account.Email, scene.RegionInfo.RegionName, regionID, out message);
145 } 145 }
146 else 146 else
147 { 147 {
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/RemotePresenceServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/RemotePresenceServiceConnector.cs
index e8e140a..6c69570 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/RemotePresenceServiceConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/RemotePresenceServiceConnector.cs
@@ -59,7 +59,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Presence
59 59
60 public string Name 60 public string Name
61 { 61 {
62 get { return "RemotePresenceServiceConnector"; } 62 get { return "RemotePresenceServicesConnector"; }
63 } 63 }
64 64
65 public void Initialise(IConfigSource source) 65 public void Initialise(IConfigSource source)
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs
index 074bfb5..c6c6af0 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs
@@ -172,12 +172,12 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation
172 { 172 {
173 if (s.RegionInfo.RegionHandle == destination.RegionHandle) 173 if (s.RegionInfo.RegionHandle == destination.RegionHandle)
174 { 174 {
175// m_log.DebugFormat("[LOCAL COMMS]: Found region {0} to send SendCreateChildAgent", regionHandle); 175 m_log.DebugFormat("[LOCAL COMMS]: Found region {0} to send SendCreateChildAgent", destination.RegionName);
176 return s.NewUserConnection(aCircuit, teleportFlags, out reason); 176 return s.NewUserConnection(aCircuit, teleportFlags, out reason);
177 } 177 }
178 } 178 }
179 179
180// m_log.DebugFormat("[LOCAL COMMS]: Did not find region {0} for SendCreateChildAgent", regionHandle); 180 m_log.DebugFormat("[LOCAL COMMS]: Did not find region {0} for SendCreateChildAgent", destination.RegionName);
181 reason = "Did not find region " + destination.RegionName; 181 reason = "Did not find region " + destination.RegionName;
182 return false; 182 return false;
183 } 183 }
@@ -241,14 +241,11 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation
241 return false; 241 return false;
242 } 242 }
243 243
244 public bool ReleaseAgent(GridRegion destination, UUID id, string uri) 244 public bool ReleaseAgent(UUID origin, UUID id, string uri)
245 { 245 {
246 if (destination == null)
247 return false;
248
249 foreach (Scene s in m_sceneList) 246 foreach (Scene s in m_sceneList)
250 { 247 {
251 if (s.RegionInfo.RegionHandle == destination.RegionHandle) 248 if (s.RegionInfo.RegionID == origin)
252 { 249 {
253 //m_log.Debug("[LOCAL COMMS]: Found region to SendReleaseAgent"); 250 //m_log.Debug("[LOCAL COMMS]: Found region to SendReleaseAgent");
254 return s.IncomingReleaseAgent(id); 251 return s.IncomingReleaseAgent(id);
@@ -334,6 +331,14 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation
334 return false; 331 return false;
335 } 332 }
336 333
334 public bool IsLocalRegion(UUID id)
335 {
336 foreach (Scene s in m_sceneList)
337 if (s.RegionInfo.RegionID == id)
338 return true;
339 return false;
340 }
341
337 #endregion 342 #endregion
338 } 343 }
339} 344}
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs
index c9cc368..f485cd1 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs
@@ -245,18 +245,15 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation
245 245
246 } 246 }
247 247
248 public bool ReleaseAgent(GridRegion destination, UUID id, string uri) 248 public bool ReleaseAgent(UUID origin, UUID id, string uri)
249 { 249 {
250 if (destination == null)
251 return false;
252
253 // Try local first 250 // Try local first
254 if (m_localBackend.ReleaseAgent(destination, id, uri)) 251 if (m_localBackend.ReleaseAgent(origin, id, uri))
255 return true; 252 return true;
256 253
257 // else do the remote thing 254 // else do the remote thing
258 if (!m_localBackend.IsLocalRegion(destination.RegionHandle)) 255 if (!m_localBackend.IsLocalRegion(origin))
259 return m_remoteConnector.ReleaseAgent(destination, id, uri); 256 return m_remoteConnector.ReleaseAgent(origin, id, uri);
260 257
261 return false; 258 return false;
262 } 259 }