diff options
author | Melanie | 2011-05-03 14:26:18 +0100 |
---|---|---|
committer | Melanie | 2011-05-03 14:26:18 +0100 |
commit | af55eda16b1025796a61289a0ab84b26e6444627 (patch) | |
tree | 6449c15b8f54240cfef62d606fab88a185f75f03 /OpenSim/Services/Connectors | |
parent | Merge branch 'master' into careminster-presence-refactor (diff) | |
parent | Increased timeout for fat UpdateAgent to 200secs. Nebadon's 3800-prim alien a... (diff) | |
download | opensim-SC-af55eda16b1025796a61289a0ab84b26e6444627.zip opensim-SC-af55eda16b1025796a61289a0ab84b26e6444627.tar.gz opensim-SC-af55eda16b1025796a61289a0ab84b26e6444627.tar.bz2 opensim-SC-af55eda16b1025796a61289a0ab84b26e6444627.tar.xz |
Merge branch 'master' into careminster-presence-refactor
Diffstat (limited to 'OpenSim/Services/Connectors')
-rw-r--r-- | OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs | 2 | ||||
-rw-r--r-- | OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs | 35 |
2 files changed, 20 insertions, 17 deletions
diff --git a/OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs b/OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs index 1aa3282..bc0bc54 100644 --- a/OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs +++ b/OpenSim/Services/Connectors/Hypergrid/GatekeeperServiceConnector.cs | |||
@@ -306,7 +306,7 @@ namespace OpenSim.Services.Connectors.Hypergrid | |||
306 | args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString()); | 306 | args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString()); |
307 | args["teleport_flags"] = OSD.FromString(flags.ToString()); | 307 | args["teleport_flags"] = OSD.FromString(flags.ToString()); |
308 | 308 | ||
309 | OSDMap result = WebUtil.PostToService(uri,args); | 309 | OSDMap result = WebUtil.PostToService(uri, args, 20000); |
310 | if (result["Success"].AsBoolean()) | 310 | if (result["Success"].AsBoolean()) |
311 | { | 311 | { |
312 | OSDMap unpacked = (OSDMap)result["_Result"]; | 312 | OSDMap unpacked = (OSDMap)result["_Result"]; |
diff --git a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs index 6ce0a47..0ad9121 100644 --- a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs +++ b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs | |||
@@ -102,7 +102,7 @@ namespace OpenSim.Services.Connectors.Simulation | |||
102 | args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString()); | 102 | args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString()); |
103 | args["teleport_flags"] = OSD.FromString(flags.ToString()); | 103 | args["teleport_flags"] = OSD.FromString(flags.ToString()); |
104 | 104 | ||
105 | OSDMap result = WebUtil.PostToService(uri, args, 5000); | 105 | OSDMap result = WebUtil.PostToService(uri, args, 20000); |
106 | if (result["Success"].AsBoolean()) | 106 | if (result["Success"].AsBoolean()) |
107 | return true; | 107 | return true; |
108 | 108 | ||
@@ -126,7 +126,7 @@ namespace OpenSim.Services.Connectors.Simulation | |||
126 | /// </summary> | 126 | /// </summary> |
127 | public bool UpdateAgent(GridRegion destination, AgentData data) | 127 | public bool UpdateAgent(GridRegion destination, AgentData data) |
128 | { | 128 | { |
129 | return UpdateAgent(destination, (IAgentData)data); | 129 | return UpdateAgent(destination, (IAgentData)data, 200000); // yes, 200 seconds |
130 | } | 130 | } |
131 | 131 | ||
132 | /// <summary> | 132 | /// <summary> |
@@ -181,7 +181,7 @@ namespace OpenSim.Services.Connectors.Simulation | |||
181 | } | 181 | } |
182 | } | 182 | } |
183 | 183 | ||
184 | UpdateAgent(destination,(IAgentData)pos); | 184 | UpdateAgent(destination, (IAgentData)pos, 10000); |
185 | } | 185 | } |
186 | 186 | ||
187 | // unreachable | 187 | // unreachable |
@@ -191,7 +191,7 @@ namespace OpenSim.Services.Connectors.Simulation | |||
191 | /// <summary> | 191 | /// <summary> |
192 | /// This is the worker function to send AgentData to a neighbor region | 192 | /// This is the worker function to send AgentData to a neighbor region |
193 | /// </summary> | 193 | /// </summary> |
194 | private bool UpdateAgent(GridRegion destination, IAgentData cAgentData) | 194 | private bool UpdateAgent(GridRegion destination, IAgentData cAgentData, int timeout) |
195 | { | 195 | { |
196 | // m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: UpdateAgent start"); | 196 | // m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: UpdateAgent start"); |
197 | 197 | ||
@@ -207,7 +207,7 @@ namespace OpenSim.Services.Connectors.Simulation | |||
207 | args["destination_name"] = OSD.FromString(destination.RegionName); | 207 | args["destination_name"] = OSD.FromString(destination.RegionName); |
208 | args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString()); | 208 | args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString()); |
209 | 209 | ||
210 | OSDMap result = WebUtil.PutToService(uri,args); | 210 | OSDMap result = WebUtil.PutToService(uri, args, timeout); |
211 | return result["Success"].AsBoolean(); | 211 | return result["Success"].AsBoolean(); |
212 | } | 212 | } |
213 | catch (Exception e) | 213 | catch (Exception e) |
@@ -233,7 +233,7 @@ namespace OpenSim.Services.Connectors.Simulation | |||
233 | 233 | ||
234 | try | 234 | try |
235 | { | 235 | { |
236 | OSDMap result = WebUtil.GetFromService(uri); | 236 | OSDMap result = WebUtil.GetFromService(uri, 10000); |
237 | if (result["Success"].AsBoolean()) | 237 | if (result["Success"].AsBoolean()) |
238 | { | 238 | { |
239 | // OSDMap args = Util.GetOSDMap(result["_RawResult"].AsString()); | 239 | // OSDMap args = Util.GetOSDMap(result["_RawResult"].AsString()); |
@@ -275,27 +275,30 @@ namespace OpenSim.Services.Connectors.Simulation | |||
275 | try | 275 | try |
276 | { | 276 | { |
277 | OSDMap result = WebUtil.ServiceOSDRequest(uri, request, "QUERYACCESS", 10000); | 277 | OSDMap result = WebUtil.ServiceOSDRequest(uri, request, "QUERYACCESS", 10000); |
278 | OSDMap data = (OSDMap)result["_Result"]; | ||
279 | |||
280 | bool success = result["success"].AsBoolean(); | 278 | bool success = result["success"].AsBoolean(); |
281 | reason = data["reason"].AsString(); | 279 | if (result.ContainsKey("_Result")) |
282 | if (data["version"] != null && data["version"].AsString() != string.Empty) | 280 | { |
283 | version = data["version"].AsString(); | 281 | OSDMap data = (OSDMap)result["_Result"]; |
284 | 282 | ||
285 | m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: QueryAccess to {0} returned {1} version {2} ({3})", uri, success, version, data["version"].AsString()); | 283 | reason = data["reason"].AsString(); |
284 | if (data["version"] != null && data["version"].AsString() != string.Empty) | ||
285 | version = data["version"].AsString(); | ||
286 | |||
287 | m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: QueryAccess to {0} returned {1} version {2} ({3})", uri, success, version, data["version"].AsString()); | ||
288 | } | ||
286 | 289 | ||
287 | if (!success) | 290 | if (!success) |
288 | { | 291 | { |
289 | if (data.ContainsKey("Message")) | 292 | if (result.ContainsKey("Message")) |
290 | { | 293 | { |
291 | string message = data["Message"].AsString(); | 294 | string message = result["Message"].AsString(); |
292 | if (message == "Service request failed: [MethodNotAllowed] MethodNotAllowed") // Old style region | 295 | if (message == "Service request failed: [MethodNotAllowed] MethodNotAllowed") // Old style region |
293 | { | 296 | { |
294 | m_log.Info("[REMOTE SIMULATION CONNECTOR]: The above web util error was caused by a TP to a sim that doesn't support QUERYACCESS and can be ignored"); | 297 | m_log.Info("[REMOTE SIMULATION CONNECTOR]: The above web util error was caused by a TP to a sim that doesn't support QUERYACCESS and can be ignored"); |
295 | return true; | 298 | return true; |
296 | } | 299 | } |
297 | 300 | ||
298 | reason = data["Message"]; | 301 | reason = result["Message"]; |
299 | } | 302 | } |
300 | else | 303 | else |
301 | { | 304 | { |
@@ -401,7 +404,7 @@ namespace OpenSim.Services.Connectors.Simulation | |||
401 | args["destination_name"] = OSD.FromString(destination.RegionName); | 404 | args["destination_name"] = OSD.FromString(destination.RegionName); |
402 | args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString()); | 405 | args["destination_uuid"] = OSD.FromString(destination.RegionID.ToString()); |
403 | 406 | ||
404 | WebUtil.PostToService(uri, args); | 407 | WebUtil.PostToService(uri, args, 40000); |
405 | } | 408 | } |
406 | catch (Exception e) | 409 | catch (Exception e) |
407 | { | 410 | { |