From 028506cf3cecb3666b0c185d9c25e21bab968c93 Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Thu, 20 Aug 2015 00:18:45 +0200 Subject: Partial plumbing for the agent stateful module features negotiation --- .../Services/Connectors/Simulation/SimulationServiceConnector.cs | 9 ++++++++- OpenSim/Services/HypergridService/GatekeeperService.cs | 2 +- OpenSim/Services/Interfaces/ISimulationService.cs | 3 ++- OpenSim/Services/LLLoginService/LLLoginService.cs | 2 +- 4 files changed, 12 insertions(+), 4 deletions(-) (limited to 'OpenSim/Services') diff --git a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs index b6fde72..a6f90b4 100644 --- a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs +++ b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs @@ -282,7 +282,7 @@ namespace OpenSim.Services.Connectors.Simulation } - public bool QueryAccess(GridRegion destination, UUID agentID, string agentHomeURI, bool viaTeleport, Vector3 position, string myversion, out string version, out string reason) + public bool QueryAccess(GridRegion destination, UUID agentID, string agentHomeURI, bool viaTeleport, Vector3 position, string myversion, List featuresAvailable, out string version, out string reason) { reason = "Failed to contact destination"; version = "Unknown"; @@ -299,6 +299,13 @@ namespace OpenSim.Services.Connectors.Simulation request.Add("viaTeleport", OSD.FromBoolean(viaTeleport)); request.Add("position", OSD.FromString(position.ToString())); request.Add("my_version", OSD.FromString(myversion)); + + OSDArray features = new OSDArray(); + foreach (UUID feature in featuresAvailable) + features.Add(OSD.FromString(feature.ToString())); + + request.Add("features", features); + if (agentHomeURI != null) request.Add("agent_home_uri", OSD.FromString(agentHomeURI)); diff --git a/OpenSim/Services/HypergridService/GatekeeperService.cs b/OpenSim/Services/HypergridService/GatekeeperService.cs index e0038b4..44b26d5 100644 --- a/OpenSim/Services/HypergridService/GatekeeperService.cs +++ b/OpenSim/Services/HypergridService/GatekeeperService.cs @@ -453,7 +453,7 @@ namespace OpenSim.Services.HypergridService if (!m_SimulationService.QueryAccess( destination, aCircuit.AgentID, aCircuit.ServiceURLs["HomeURI"].ToString(), - true, aCircuit.startpos, "SIMULATION/0.3", out version, out reason)) + true, aCircuit.startpos, "SIMULATION/0.3", new List(), out version, out reason)) return false; return m_SimulationService.CreateAgent(source, destination, aCircuit, (uint)loginFlag, out reason); diff --git a/OpenSim/Services/Interfaces/ISimulationService.cs b/OpenSim/Services/Interfaces/ISimulationService.cs index ef014f9..42c414d 100644 --- a/OpenSim/Services/Interfaces/ISimulationService.cs +++ b/OpenSim/Services/Interfaces/ISimulationService.cs @@ -26,6 +26,7 @@ */ using System; +using System.Collections.Generic; using OpenSim.Framework; using OpenMetaverse; @@ -91,7 +92,7 @@ namespace OpenSim.Services.Interfaces /// Version that the target simulator is running /// [out] Optional error message /// True: ok; False: not allowed - bool QueryAccess(GridRegion destination, UUID agentID, string agentHomeURI, bool viaTeleport, Vector3 position, string sversion, out string version, out string reason); + bool QueryAccess(GridRegion destination, UUID agentID, string agentHomeURI, bool viaTeleport, Vector3 position, string sversion, List features, out string version, out string reason); /// /// Message from receiving region to departing region, telling it got contacted by the client. diff --git a/OpenSim/Services/LLLoginService/LLLoginService.cs b/OpenSim/Services/LLLoginService/LLLoginService.cs index 65030a4..d67bc4d 100644 --- a/OpenSim/Services/LLLoginService/LLLoginService.cs +++ b/OpenSim/Services/LLLoginService/LLLoginService.cs @@ -983,7 +983,7 @@ namespace OpenSim.Services.LLLoginService if ( !simConnector.QueryAccess( - region, aCircuit.AgentID, null, true, aCircuit.startpos, "SIMULATION/0.3", out version, out reason)) + region, aCircuit.AgentID, null, true, aCircuit.startpos, "SIMULATION/0.3", new List(), out version, out reason)) return false; return simConnector.CreateAgent(null, region, aCircuit, (uint)flags, out reason); -- cgit v1.1