From a7309d90dacf503b0170ad911289c33e9ab42821 Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Sun, 17 Jan 2010 08:40:05 -0800 Subject: [PATCH] * Added ServiceURLs to AgentCircuitData. * Fixed a configuration buglet introduced yesterday in StandaloneHypergrid.ini. --- OpenSim/Framework/AgentCircuitData.cs | 21 +++++++++++++++++++ .../Hypergrid/GatekeeperServerConnector.cs | 2 -- .../Hypergrid/HypergridServiceConnector.cs | 2 +- .../Services/HypergridService/HGCommands.cs | 1 + .../Services/LLLoginService/LLLoginService.cs | 1 + bin/config-include/StandaloneHypergrid.ini | 2 +- 6 files changed, 25 insertions(+), 4 deletions(-) diff --git a/OpenSim/Framework/AgentCircuitData.cs b/OpenSim/Framework/AgentCircuitData.cs index e655aa46d4..a3b999e332 100644 --- a/OpenSim/Framework/AgentCircuitData.cs +++ b/OpenSim/Framework/AgentCircuitData.cs @@ -101,6 +101,8 @@ namespace OpenSim.Framework /// public Vector3 startpos; + public Dictionary ServiceURLs; + public AgentCircuitData() { } @@ -187,6 +189,16 @@ namespace OpenSim.Framework } } + if (ServiceURLs != null && ServiceURLs.Count > 0) + { + OSDArray urls = new OSDArray(ServiceURLs.Count * 2); + foreach (KeyValuePair kvp in ServiceURLs) + { + urls.Add(OSD.FromString(kvp.Key)); + urls.Add(OSD.FromString((kvp.Value == null) ? string.Empty : kvp.Value.ToString())); + } + } + return args; } @@ -270,6 +282,15 @@ namespace OpenSim.Framework Appearance.SetAttachments(attachments); } + ServiceURLs = new Dictionary(); + if (args.ContainsKey("service_urls") && args["service_urls"] != null && (args["service_urls"]).Type == OSDType.Array) + { + OSDArray urls = (OSDArray)(args["service_urls"]); + for (int i = 0; i < urls.Count / 2; i++) + { + ServiceURLs[urls[i * 2].AsString()] = urls[(i * 2) + 1].AsString(); + } + } } } diff --git a/OpenSim/Server/Handlers/Hypergrid/GatekeeperServerConnector.cs b/OpenSim/Server/Handlers/Hypergrid/GatekeeperServerConnector.cs index ec8dde413f..762ea7997f 100644 --- a/OpenSim/Server/Handlers/Hypergrid/GatekeeperServerConnector.cs +++ b/OpenSim/Server/Handlers/Hypergrid/GatekeeperServerConnector.cs @@ -86,8 +86,6 @@ namespace OpenSim.Server.Handlers.Hypergrid //string portstr = (string)requestData["port"]; string name = (string)requestData["region_name"]; - m_log.DebugFormat("[HGrid]: Hyperlink request"); - UUID regionID = UUID.Zero; string imageURL = string.Empty; ulong regionHandle = 0; diff --git a/OpenSim/Services/Connectors/Hypergrid/HypergridServiceConnector.cs b/OpenSim/Services/Connectors/Hypergrid/HypergridServiceConnector.cs index 460acae63b..0bb1c0e994 100644 --- a/OpenSim/Services/Connectors/Hypergrid/HypergridServiceConnector.cs +++ b/OpenSim/Services/Connectors/Hypergrid/HypergridServiceConnector.cs @@ -70,7 +70,7 @@ namespace OpenSim.Services.Connectors.Hypergrid XmlRpcRequest request = new XmlRpcRequest("link_region", paramList); string uri = "http://" + info.ExternalEndPoint.Address + ":" + info.HttpPort + "/"; - m_log.Debug("[HGrid]: Linking to " + uri); + //m_log.Debug("[HGrid]: Linking to " + uri); XmlRpcResponse response = null; try { diff --git a/OpenSim/Services/HypergridService/HGCommands.cs b/OpenSim/Services/HypergridService/HGCommands.cs index f48fd70506..78ba46d6ab 100644 --- a/OpenSim/Services/HypergridService/HGCommands.cs +++ b/OpenSim/Services/HypergridService/HGCommands.cs @@ -159,6 +159,7 @@ namespace OpenSim.Services.HypergridService string reason = string.Empty; if (m_HypergridService.TryLinkRegionToCoords(mapName, xloc, yloc, out reason) == null) MainConsole.Instance.Output("Failed to link region: " + reason); + MainConsole.Instance.Output("Hyperlink estalished"); } else { diff --git a/OpenSim/Services/LLLoginService/LLLoginService.cs b/OpenSim/Services/LLLoginService/LLLoginService.cs index b0e36f1bcb..6f92388b12 100644 --- a/OpenSim/Services/LLLoginService/LLLoginService.cs +++ b/OpenSim/Services/LLLoginService/LLLoginService.cs @@ -438,6 +438,7 @@ namespace OpenSim.Services.LLLoginService aCircuit.SecureSessionID = secureSession; aCircuit.SessionID = session; aCircuit.startpos = position; + aCircuit.ServiceURLs = account.ServiceURLs; if (simConnector.CreateAgent(region, aCircuit, 0, out reason)) return aCircuit; diff --git a/bin/config-include/StandaloneHypergrid.ini b/bin/config-include/StandaloneHypergrid.ini index cd09091d61..79a8775cda 100644 --- a/bin/config-include/StandaloneHypergrid.ini +++ b/bin/config-include/StandaloneHypergrid.ini @@ -69,7 +69,7 @@ Realm = "regions" [HypergridService] - GridService = "OpenSim.Region.CoreModules.dll:LocalGridServicesConnector" + GridService = "OpenSim.Services.GridService.dll:GridService" AssetService = "OpenSim.Services.AssetService.dll:AssetService" [GatekeeperService]