OpenSimExtras

Move the experimental extra features functionality into the GridService. This sends default values for map, search and destination guide, plus ExportSupported control to the region on startup. Please watch http://opensimulator.org/wiki/SimulatorFeatures_Extras for changes and documentation.
bullet-2.82
BlueWall 2014-08-03 20:33:40 -04:00
parent e36e416637
commit 10a8d2852e
15 changed files with 182 additions and 434 deletions

View File

@ -27,17 +27,18 @@
using System; using System;
using System.Collections; using System.Collections;
using System.Collections.Generic;
using System.Reflection; using System.Reflection;
using log4net; using log4net;
using Nini.Config; using Nini.Config;
using Mono.Addins; using Mono.Addins;
using OpenMetaverse; using OpenMetaverse;
using OpenMetaverse.StructuredData; using OpenMetaverse.StructuredData;
using OpenSim.Framework; //using OpenSim.Framework;
using OpenSim.Framework.Servers.HttpServer; using OpenSim.Framework.Servers.HttpServer;
using OpenSim.Region.Framework.Interfaces; using OpenSim.Region.Framework.Interfaces;
using OpenSim.Region.Framework.Scenes; using OpenSim.Region.Framework.Scenes;
using OpenSim.Services.Interfaces; // using OpenSim.Services.Interfaces;
using Caps = OpenSim.Framework.Capabilities.Caps; using Caps = OpenSim.Framework.Capabilities.Caps;
namespace OpenSim.Region.ClientStack.Linden namespace OpenSim.Region.ClientStack.Linden
@ -63,8 +64,6 @@ namespace OpenSim.Region.ClientStack.Linden
private Scene m_scene; private Scene m_scene;
bool m_AllowOverride = true;
/// <summary> /// <summary>
/// Simulator features /// Simulator features
/// </summary> /// </summary>
@ -81,25 +80,11 @@ namespace OpenSim.Region.ClientStack.Linden
IConfig config = source.Configs["SimulatorFeatures"]; IConfig config = source.Configs["SimulatorFeatures"];
if (config != null) if (config != null)
{ {
string featuresURI = config.GetString("ExtraFeaturesServiceURI", string.Empty); // These are normaly set in their respective modules
m_SearchURL = config.GetString("SearchServerURI", m_SearchURL);
if (string.IsNullOrEmpty(featuresURI)) m_DestinationGuideURL = config.GetString ("DestinationGuideURI", m_DestinationGuideURL);
{ m_ExportSupported = config.GetBoolean("ExportSupported", m_ExportSupported);
m_log.Info("ExtraFeaturesServiceURI is undefined. The grid's ExtraFeatures will not be available to regions in this instance.");
}
else
{
GetGridExtraFeatures(featuresURI);
}
if (m_AllowOverride)
{
m_SearchURL = config.GetString("SearchServerURI", m_SearchURL);
m_DestinationGuideURL = config.GetString ("DestinationGuideURI", m_DestinationGuideURL);
m_ExportSupported = config.GetBoolean("ExportSupported", m_ExportSupported);
}
} }
AddDefaultFeatures(); AddDefaultFeatures();
@ -120,6 +105,7 @@ namespace OpenSim.Region.ClientStack.Linden
public void RegionLoaded(Scene s) public void RegionLoaded(Scene s)
{ {
GetGridExtraFeatures(s);
} }
public void PostInitialise() public void PostInitialise()
@ -169,11 +155,11 @@ namespace OpenSim.Region.ClientStack.Linden
else else
extrasMap = new OSDMap(); extrasMap = new OSDMap();
if (m_SearchURL != string.Empty && m_AllowOverride == true) if (m_SearchURL != string.Empty)
extrasMap["search-server-url"] = m_SearchURL; extrasMap["search-server-url"] = m_SearchURL;
if (!string.IsNullOrEmpty(m_DestinationGuideURL) && m_AllowOverride == true) if (!string.IsNullOrEmpty(m_DestinationGuideURL))
extrasMap["destination-guide-url"] = m_DestinationGuideURL; extrasMap["destination-guide-url"] = m_DestinationGuideURL;
if (m_ExportSupported && m_AllowOverride == true) if (m_ExportSupported)
extrasMap["ExportSupported"] = true; extrasMap["ExportSupported"] = true;
if (extrasMap.Count > 0) if (extrasMap.Count > 0)
@ -233,9 +219,7 @@ namespace OpenSim.Region.ClientStack.Linden
SimulatorFeaturesRequestDelegate handlerOnSimulatorFeaturesRequest = OnSimulatorFeaturesRequest; SimulatorFeaturesRequestDelegate handlerOnSimulatorFeaturesRequest = OnSimulatorFeaturesRequest;
// We will not trigger the event if m_AllowOverride == False if (handlerOnSimulatorFeaturesRequest != null)
// See Robust.ini/Robust.HG.ini [GridExtraFeatures] - AllowRegionOverride
if (handlerOnSimulatorFeaturesRequest != null && m_AllowOverride == true)
handlerOnSimulatorFeaturesRequest(agentID, ref copy); handlerOnSimulatorFeaturesRequest(agentID, ref copy);
//Send back data //Send back data
@ -255,32 +239,22 @@ namespace OpenSim.Region.ClientStack.Linden
/// <param name='featuresURI'> /// <param name='featuresURI'>
/// The URI Robust uses to handle the get_extra_features request /// The URI Robust uses to handle the get_extra_features request
/// </param> /// </param>
private void GetGridExtraFeatures(string featuresURI) private void GetGridExtraFeatures(Scene scene)
{ {
JsonRpcRequestManager rpc = new JsonRpcRequestManager (); Dictionary<string, object> extraFeatures = scene.GridService.GetExtraFeatures();
OSDMap parameters = new OSDMap ();
OSD Params = (OSD)parameters;
if (!rpc.JsonRpcRequest (ref Params, "get_extra_features", featuresURI, UUID.Random ().ToString ()))
{
m_log.Error("[SIMFEATURES]: Could not retrieve extra features from grid. Please check configuration.");
return;
}
parameters = (OSDMap)Params;
OSDMap features = (OSDMap)parameters ["result"];
if(features.ContainsKey("region_override"))
m_AllowOverride = features ["region_override"].AsBoolean () ;
else
m_AllowOverride = true;
OSDMap test = (OSDMap)features ["extra_features"];
lock (m_features) lock (m_features)
{ {
OSDMap extrasMap = new OSDMap(); OSDMap extrasMap = new OSDMap();
foreach (string key in test.Keys)
foreach(string key in extraFeatures.Keys)
{ {
extrasMap[key] = test[key]; extrasMap[key] = (string)extraFeatures[key];
if (key == "ExportSupported")
{
bool.TryParse(extraFeatures[key].ToString(), out m_ExportSupported);
}
} }
m_features["OpenSimExtras"] = extrasMap; m_features["OpenSimExtras"] = extrasMap;
} }

View File

@ -1,129 +0,0 @@
/*
* Copyright (c) Contributors, http://opensimulator.org/
* See CONTRIBUTORS.TXT for a full list of copyright holders.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* * Neither the name of the OpenSimulator Project nor the
* names of its contributors may be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
using System;
using System.Reflection;
using System.Collections.Generic;
using log4net;
using Mono.Addins;
using Nini.Config;
using OpenSim.Framework;
using OpenSim.Framework.Servers;
using OpenSim.Region.Framework.Scenes;
using OpenSim.Region.Framework.Interfaces;
using OpenSim.Server.Base;
using OpenSim.Server.Handlers.Base;
using OpenSim.Server.Handlers.Grid;
using OpenSim.Services.Interfaces;
using OpenSim.Framework.Servers.HttpServer;
namespace OpenSim.Region.CoreModules.ServiceConnectorsIn.Grid
{
[Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule", Id = "LocalGridFeaturesServiceInConnector")]
public class LocalGridExtraFeaturesServiceInConnector : ISharedRegionModule
{
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
private static bool m_Enabled = false;
private IConfigSource m_Config;
bool m_Registered = false;
#region Region Module interface
public void Initialise(IConfigSource config)
{
m_Config = config;
IConfig moduleConfig = config.Configs["Modules"];
if (moduleConfig != null)
{
string name = moduleConfig.GetString("GridExtraFeaturesServiceInConnector", "");
if (name == Name)
{
m_log.Info("[GridExtraFeatures]: GridExtraFeatures Service In Connector enabled");
InitializeService(config);
}
}
}
public void InitializeService(IConfigSource config)
{
GridExtraFeaturesHandlers handler = new GridExtraFeaturesHandlers(config);
IHttpServer Server = MainServer.Instance;
Server.AddJsonRPCHandler("get_extra_features", handler.JsonGetGridFeaturesMethod);
}
public void PostInitialise()
{
}
public void Close()
{
}
public Type ReplaceableInterface
{
get { return null; }
}
public string Name
{
get { return "LocalGridExtraFeaturesServiceInConnector"; }
}
public void AddRegion(Scene scene)
{
if (!m_Enabled)
return;
}
public void RemoveRegion(Scene scene)
{
if (!m_Enabled)
return;
}
public void RegionLoaded(Scene scene)
{
if (!m_Enabled)
return;
if (!m_Registered)
{
m_Registered = true;
m_log.Info("[GRID EXTRA FEATURES]: Starting...");
new GridExtraFeaturesServerInConnector(m_Config, MainServer.Instance, "GridExtraFeaturesService");
}
}
#endregion
}
}

View File

@ -278,6 +278,11 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Grid
return m_GridService.GetRegionFlags(scopeID, regionID); return m_GridService.GetRegionFlags(scopeID, regionID);
} }
public Dictionary<string, object> GetExtraFeatures()
{
return m_GridService.GetExtraFeatures();
}
#endregion #endregion
public void HandleShowNeighboursCommand(string module, string[] cmdparams) public void HandleShowNeighboursCommand(string module, string[] cmdparams)

View File

@ -28,6 +28,7 @@
using log4net; using log4net;
using Mono.Addins; using Mono.Addins;
using System; using System;
using System.Collections;
using System.Collections.Generic; using System.Collections.Generic;
using System.Reflection; using System.Reflection;
using Nini.Config; using Nini.Config;
@ -349,6 +350,17 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Grid
return flags; return flags;
} }
public Dictionary<string, object> GetExtraFeatures()
{
Dictionary<string, object> extraFeatures;
extraFeatures = m_LocalGridService.GetExtraFeatures();
if (extraFeatures.Count == 0)
extraFeatures = m_RemoteGridService.GetExtraFeatures();
return extraFeatures;
}
#endregion #endregion
} }
} }

View File

@ -1,127 +0,0 @@
/*
* Copyright (c) Contributors, http://opensimulator.org/
* See CONTRIBUTORS.TXT for a full list of copyright holders.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* * Neither the name of the OpenSimulator Project nor the
* names of its contributors may be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
using System;
using System.Collections;
using System.IO;
using System.Net;
using System.Reflection;
using System.Security;
using System.Text;
using log4net;
using Nini.Config;
using Nwc.XmlRpc;
using OpenSim.Framework;
using OpenSim.Framework.Servers.HttpServer;
using OpenMetaverse.StructuredData;
namespace OpenSim.Server.Handlers.Grid
{
/// <summary>
/// Grid extra features handlers.
/// <para>Allows grid level configuration of OpenSimExtra items.</para>
/// <para>Option to control region override of these settings.</para>
/// </summary>
public class GridExtraFeaturesHandlers
{
private static readonly ILog m_Log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
private Hashtable m_ExtraFeatures = new Hashtable();
private bool m_AllowRegionOverride = true;
public GridExtraFeaturesHandlers(IConfigSource configSource)
{
try
{
IConfig featuresCfg = configSource.Configs["GridExtraFeatures"];
foreach( string key in featuresCfg.GetKeys())
{
if(key != "AllowRegionOverride")
{
string value = featuresCfg.GetString(key);
// map the value to the viewer supported extra features
// add additional ones here as support is added in the viewer
// and place the configuration option in [GridExtraFeatures].
switch(key)
{
case "SearchServerURI":
m_ExtraFeatures["search-server-url"] = value;
break;
case "MapImageServerURI":
m_ExtraFeatures["map-server-url"] = value;
break;
case "DestinationGuideURI":
m_ExtraFeatures["destination-guide-url"] = value;
break;
case "ExportSupported":
m_ExtraFeatures["ExportSupported"] = value;
break;
case "WhisperDistance":
m_ExtraFeatures["whisper-range"] = value;
break;
case "SayDistance":
m_ExtraFeatures["say-range"] = value;
break;
case "ShoutDistance":
m_ExtraFeatures["shout-range"] = value;
break;
default:
m_Log.InfoFormat("{0} not yet supported.");
break;
}
}
else
m_AllowRegionOverride = featuresCfg.GetBoolean(key);
}
}
catch (Exception)
{
m_Log.Warn("[GRID EXTRA FEATURES SERVICE]: Cannot get grid features from config source, allowing region override");
}
}
public bool JsonGetGridFeaturesMethod(OSDMap json, ref JsonRpcResponse response)
{
OSDMap features = new OSDMap();
OSDMap json_map = new OSDMap();
foreach (string key in m_ExtraFeatures.Keys)
{
features[key] = OSD.FromString(m_ExtraFeatures[key].ToString());
}
json_map["extra_features"] = features;
json_map["region_override"] = m_AllowRegionOverride.ToString();
response.Result = json_map;
return true;
}
}
}

View File

@ -1,50 +0,0 @@
/*
* Copyright (c) Contributors, http://opensimulator.org/
* See CONTRIBUTORS.TXT for a full list of copyright holders.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* * Neither the name of the OpenSimulator Project nor the
* names of its contributors may be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
using System;
using System.Collections.Generic;
using System.Reflection;
using log4net;
using OpenMetaverse;
using Nini.Config;
using OpenSim.Framework;
using OpenSim.Framework.Servers.HttpServer;
using OpenSim.Server.Handlers.Base;
namespace OpenSim.Server.Handlers.Grid
{
public class GridExtraFeaturesServerInConnector : ServiceConnector
{
public GridExtraFeaturesServerInConnector(IConfigSource config, IHttpServer server, string configName) :
base(config, server, configName)
{
GridExtraFeaturesHandlers handler = new GridExtraFeaturesHandlers(config);
server.AddJsonRPCHandler("get_extra_features", handler.JsonGetGridFeaturesMethod);
}
}
}

View File

@ -122,6 +122,9 @@ namespace OpenSim.Server.Handlers.Grid
case "get_region_flags": case "get_region_flags":
return GetRegionFlags(request); return GetRegionFlags(request);
case "get_grid_extra_features":
return GetGridExtraFeatures(request);
} }
m_log.DebugFormat("[GRID HANDLER]: unknown method request {0}", method); m_log.DebugFormat("[GRID HANDLER]: unknown method request {0}", method);
@ -578,6 +581,22 @@ namespace OpenSim.Server.Handlers.Grid
//m_log.DebugFormat("[GRID HANDLER]: resp string: {0}", xmlString); //m_log.DebugFormat("[GRID HANDLER]: resp string: {0}", xmlString);
return Util.UTF8NoBomEncoding.GetBytes(xmlString); return Util.UTF8NoBomEncoding.GetBytes(xmlString);
} }
byte[] GetGridExtraFeatures(Dictionary<string, object> request)
{
Dictionary<string, object> result = new Dictionary<string, object> ();
Dictionary<string, object> extraFeatures = m_GridService.GetExtraFeatures ();
foreach (string key in extraFeatures.Keys)
{
result [key] = extraFeatures [key];
}
string xmlString = ServerUtils.BuildXmlResponse(result);
return Util.UTF8NoBomEncoding.GetBytes(xmlString);
}
#endregion #endregion

View File

@ -719,6 +719,45 @@ namespace OpenSim.Services.Connectors
return flags; return flags;
} }
public Dictionary<string, object> GetExtraFeatures()
{
Dictionary<string, object> sendData = new Dictionary<string, object>();
Dictionary<string, object> extraFeatures = new Dictionary<string, object>();
sendData["METHOD"] = "get_grid_extra_features";
string reply = string.Empty;
string uri = m_ServerURI + "/grid";
try
{
reply = SynchronousRestFormsRequester.MakeRequest("POST",
uri,
ServerUtils.BuildQueryString(sendData), m_Auth);
}
catch (Exception e)
{
m_log.DebugFormat("[GRID CONNECTOR]: GetExtraFeatures - Exception when contacting grid server at {0}: {1}", uri, e.Message);
return extraFeatures;
}
if (reply != string.Empty)
{
Dictionary<string, object> replyData = ServerUtils.ParseXmlResponse(reply);
if ((replyData != null) && replyData.Count > 0)
{
foreach (string key in replyData.Keys)
{
extraFeatures[key] = replyData[key].ToString();
}
}
}
else
m_log.DebugFormat("[GRID CONNECTOR]: GetExtraServiceURLs received null reply");
return extraFeatures;
}
#endregion #endregion
} }

View File

@ -402,6 +402,13 @@ namespace OpenSim.Services.Connectors.SimianGrid
return -1; return -1;
} }
} }
public Dictionary<string, object> GetExtraFeatures()
{
/// See SimulatorFeaturesModule - Need to get map, search and destination guide
Dictionary<string, object> extraFeatures = new Dictionary<string, object>();
return extraFeatures;
}
#endregion IGridService #endregion IGridService

View File

@ -59,6 +59,8 @@ namespace OpenSim.Services.GridService
protected bool m_SuppressVarregionOverlapCheckOnRegistration = false; protected bool m_SuppressVarregionOverlapCheckOnRegistration = false;
private static Dictionary<string,object> m_ExtraFeatures = new Dictionary<string, object>();
public GridService(IConfigSource config) public GridService(IConfigSource config)
: base(config) : base(config)
{ {
@ -139,10 +141,38 @@ namespace OpenSim.Services.GridService
HandleSetFlags); HandleSetFlags);
} }
if (!suppressConsoleCommands)
SetExtraServiceURLs(config);
m_HypergridLinker = new HypergridLinker(m_config, this, m_Database); m_HypergridLinker = new HypergridLinker(m_config, this, m_Database);
} }
} }
private void SetExtraServiceURLs(IConfigSource config)
{
IConfig loginConfig = config.Configs["LoginService"];
IConfig gridConfig = config.Configs["GridService"];
if (loginConfig == null || gridConfig == null)
return;
string configVal;
configVal = loginConfig.GetString("SearchURL", string.Empty);
if (!string.IsNullOrEmpty(configVal))
m_ExtraFeatures["search-server-url"] = configVal;
configVal = loginConfig.GetString("MapTileURL", string.Empty);
if (!string.IsNullOrEmpty(configVal))
m_ExtraFeatures["map-server-url"] = configVal;
configVal = loginConfig.GetString("DestinationGuide", string.Empty);
if (!string.IsNullOrEmpty(configVal))
m_ExtraFeatures["destination-guide-url"] = configVal;
m_ExtraFeatures["ExportSupported"] = gridConfig.GetString("ExportSupported", "true");
}
#region IGridService #region IGridService
public string RegisterRegion(UUID scopeID, GridRegion regionInfos) public string RegisterRegion(UUID scopeID, GridRegion regionInfos)
@ -928,5 +958,18 @@ namespace OpenSim.Services.GridService
m_Database.Store(r); m_Database.Store(r);
} }
} }
/// <summary>
/// Gets the grid extra service URls we wish for the region to send in OpenSimExtras to dynamically refresh
/// parameters in the viewer used to access services like map, search and destination guides.
/// <para>see "SimulatorFeaturesModule" </para>
/// </summary>
/// <returns>
/// The grid extra service URls.
/// </returns>
public Dictionary<string,object> GetExtraFeatures()
{
return m_ExtraFeatures;
}
} }
} }

View File

@ -26,6 +26,7 @@
*/ */
using System; using System;
using System.Collections;
using System.Collections.Generic; using System.Collections.Generic;
using System.Net; using System.Net;
using System.Net.Sockets; using System.Net.Sockets;
@ -119,6 +120,8 @@ namespace OpenSim.Services.Interfaces
/// <param name='scopeID'></param> /// <param name='scopeID'></param>
/// <param name='regionID'></param> /// <param name='regionID'></param>
int GetRegionFlags(UUID scopeID, UUID regionID); int GetRegionFlags(UUID scopeID, UUID regionID);
Dictionary<string,object> GetExtraFeatures();
} }
public class GridRegion public class GridRegion

View File

@ -538,21 +538,18 @@
[SimulatorFeatures] [SimulatorFeatures]
;# {ExtraFeaturesServiceURI} {} {URL to the grid ExtraFeatures Service} {}
;; The grid can supply global values for extra simulator features to be
;; passed to supporting viewers. The grid may choose to disallow local
;; settings.
; ExtraFeaturesServiceURI = "http://127.0.0.1:9000/"
;# {MapImageServerURI} {} {URL for the map server} {}
; Experimental new information sent in SimulatorFeatures cap for Kokua
; viewers
; meant to override the MapImage and search server url given at login, and varying
; on a sim-basis.
; Viewers that don't understand it, will ignore it
;MapImageServerURI = "http://127.0.0.1:9000/"
;# {SearchServerURI} {} {URL of the search server} {} ;# {SearchServerURI} {} {URL of the search server} {}
;; This is identical to the Robust LoginService SearchURL setting
;; and will override that value if set here. The Robust setting
;; provides a working default for the grid and setting here is
;; optional.
;SearchServerURI = "http://127.0.0.1:9000/" ;SearchServerURI = "http://127.0.0.1:9000/"
;# {DestinationGuideURI} {} {URL of the destination guide} {} ;# {DestinationGuideURI} {} {URL of the destination guide} {}
;;
;; This serves the same purpose as the DestinationGuideURI in the
;; LoginService setting in the Robust server. This will override
;; the Robust setting if desired as an option.
;DestinationGuideURI = "http://127.0.0.1:9000/" ;DestinationGuideURI = "http://127.0.0.1:9000/"

View File

@ -45,7 +45,6 @@ InventoryInConnector = "8003/OpenSim.Server.Handlers.dll:XInventoryInConnector"
;VoiceConnector = "8004/OpenSim.Server.Handlers.dll:FreeswitchServerConnector" ;VoiceConnector = "8004/OpenSim.Server.Handlers.dll:FreeswitchServerConnector"
GridServiceConnector = "8003/OpenSim.Server.Handlers.dll:GridServiceConnector" GridServiceConnector = "8003/OpenSim.Server.Handlers.dll:GridServiceConnector"
GridInfoServerInConnector = "8002/OpenSim.Server.Handlers.dll:GridInfoServerInConnector" GridInfoServerInConnector = "8002/OpenSim.Server.Handlers.dll:GridInfoServerInConnector"
GridExtraFeaturesServerInConnector = "8002/OpenSim.Server.Handlers.dll:GridExtraFeaturesServerInConnector"
AuthenticationServiceConnector = "8003/OpenSim.Server.Handlers.dll:AuthenticationServiceConnector" AuthenticationServiceConnector = "8003/OpenSim.Server.Handlers.dll:AuthenticationServiceConnector"
OpenIdServerConnector = "8002/OpenSim.Server.Handlers.dll:OpenIdServerConnector" OpenIdServerConnector = "8002/OpenSim.Server.Handlers.dll:OpenIdServerConnector"
AvatarServiceConnector = "8003/OpenSim.Server.Handlers.dll:AvatarServiceConnector" AvatarServiceConnector = "8003/OpenSim.Server.Handlers.dll:AvatarServiceConnector"
@ -217,6 +216,10 @@ HGAssetServiceConnector = "HGAssetService@8002/OpenSim.Server.Handlers.dll:Asset
;; Allow Hyperlinks to be created at the console ;; Allow Hyperlinks to be created at the console
HypergridLinker = true HypergridLinker = true
;; Allow supporting viewers to export content
;; Set to false to prevent export
ExportSupported = true
;; If you have this set under [Hypergrid], no need to set it here, leave it commented ;; If you have this set under [Hypergrid], no need to set it here, leave it commented
; GatekeeperURI = "http://127.0.0.1:8002" ; GatekeeperURI = "http://127.0.0.1:8002"
@ -366,6 +369,9 @@ HGAssetServiceConnector = "HGAssetService@8002/OpenSim.Server.Handlers.dll:Asset
; For V2 map ; For V2 map
MapTileURL = "http://127.0.0.1:8002"; MapTileURL = "http://127.0.0.1:8002";
; Url to search service
; SearchURL = "http://127.0.0.1:8002";
; For V2/3 Web Profiles ; For V2/3 Web Profiles
; Work in progress: The ProfileServerURL/OpenIDServerURL are ; Work in progress: The ProfileServerURL/OpenIDServerURL are
; being used in a development viewer as support for webprofiles ; being used in a development viewer as support for webprofiles
@ -485,38 +491,6 @@ HGAssetServiceConnector = "HGAssetService@8002/OpenSim.Server.Handlers.dll:Asset
; this is the entry point for all user-related HG services ; this is the entry point for all user-related HG services
; uas = http://127.0.0.1:8002/ ; uas = http://127.0.0.1:8002/
[GridExtraFeatures]
; These are propagated out to the regions as default settings for the
; SimulatorFeatures to be sent to user's viewer when they teleport via
; Hypergrid into this grid.
;
; Allow regions to override our defaults.
;AllowRegionOverride = true
; Search Server URI
;SearchServerURI = "http://example.com:8200/"
; Map Server URI
;MapImageServerURI = "http://example.com:8200/"
; Grid Destination Guide URI
;DestinationGuideURI = "http://example.com:8200/"
; Chat Whisper Distance
;WhisperDistance = 10
; Chat Say Distance
;SayDistance = 20
; Chat Shout Distance
;ShoutDistance = 100
; Grid Allow Export
;ExportSupported = true
[GatekeeperService] [GatekeeperService]
LocalServiceModule = "OpenSim.Services.HypergridService.dll:GatekeeperService" LocalServiceModule = "OpenSim.Services.HypergridService.dll:GatekeeperService"
;; for the service ;; for the service

View File

@ -36,7 +36,6 @@ InventoryInConnector = "8003/OpenSim.Server.Handlers.dll:XInventoryInConnector"
;VoiceConnector = "8004/OpenSim.Server.Handlers.dll:FreeswitchServerConnector" ;VoiceConnector = "8004/OpenSim.Server.Handlers.dll:FreeswitchServerConnector"
GridServiceConnector = "8003/OpenSim.Server.Handlers.dll:GridServiceConnector" GridServiceConnector = "8003/OpenSim.Server.Handlers.dll:GridServiceConnector"
GridInfoServerInConnector = "8002/OpenSim.Server.Handlers.dll:GridInfoServerInConnector" GridInfoServerInConnector = "8002/OpenSim.Server.Handlers.dll:GridInfoServerInConnector"
GridExtraFeaturesServerInConnector = "8002/OpenSim.Server.Handlers.dll:GridExtraFeaturesServerInConnector"
AuthenticationServiceConnector = "8003/OpenSim.Server.Handlers.dll:AuthenticationServiceConnector" AuthenticationServiceConnector = "8003/OpenSim.Server.Handlers.dll:AuthenticationServiceConnector"
OpenIdServerConnector = "8002/OpenSim.Server.Handlers.dll:OpenIdServerConnector" OpenIdServerConnector = "8002/OpenSim.Server.Handlers.dll:OpenIdServerConnector"
AvatarServiceConnector = "8003/OpenSim.Server.Handlers.dll:AvatarServiceConnector" AvatarServiceConnector = "8003/OpenSim.Server.Handlers.dll:AvatarServiceConnector"
@ -178,6 +177,10 @@ MapGetServiceConnector = "8002/OpenSim.Server.Handlers.dll:MapGetServiceConnecto
; Region_Welcome_Area = "DefaultRegion, FallbackRegion" ; Region_Welcome_Area = "DefaultRegion, FallbackRegion"
; (replace spaces with underscore) ; (replace spaces with underscore)
;; Allow supporting viewers to export content
;; Set to false to prevent export
ExportSupported = true
; * This is the configuration for the freeswitch server in grid mode ; * This is the configuration for the freeswitch server in grid mode
[FreeswitchService] [FreeswitchService]
LocalServiceModule = "OpenSim.Services.FreeswitchService.dll:FreeswitchService" LocalServiceModule = "OpenSim.Services.FreeswitchService.dll:FreeswitchService"
@ -325,6 +328,9 @@ MapGetServiceConnector = "8002/OpenSim.Server.Handlers.dll:MapGetServiceConnecto
; For V2 map ; For V2 map
MapTileURL = "http://127.0.0.1:8002"; MapTileURL = "http://127.0.0.1:8002";
; Url to search service
; SearchURL = "http://127.0.0.1:8002";
; For V2/3 Web Profiles ; For V2/3 Web Profiles
; Work in progress: The ProfileServerURL/OpenIDServerURL are ; Work in progress: The ProfileServerURL/OpenIDServerURL are
; being used in a development viewer as support for webprofiles ; being used in a development viewer as support for webprofiles
@ -457,38 +463,6 @@ MapGetServiceConnector = "8002/OpenSim.Server.Handlers.dll:MapGetServiceConnecto
; password help: optional: page providing password assistance for users of your grid ; password help: optional: page providing password assistance for users of your grid
;password = http://127.0.0.1/password ;password = http://127.0.0.1/password
[GridExtraFeatures]
; These are propagated out to the regions as default settings for the
; SimulatorFeatures to be sent to user's viewer when they teleport via
; Hypergrid into this grid.
;
; Allow regions to override our defaults.
;AllowRegionOverride = true
; Search Server URI
;SearchServerURI = "http://example.com:8200/"
; Map Server URI
;MapImageServerURI = "http://example.com:8200/"
; Grid Destination Guide URI
;DestinationGuideURI = "http://example.com:8200/"
; Chat Whisper Distance
;WhisperDistance = 10
; Chat Say Distance
;SayDistance = 20
; Chat Shout Distance
;ShoutDistance = 100
; Grid Allow Export
;ExportSupported = true
[UserProfilesService] [UserProfilesService]
LocalServiceModule = "OpenSim.Services.UserProfilesService.dll:UserProfilesService" LocalServiceModule = "OpenSim.Services.UserProfilesService.dll:UserProfilesService"
Enabled = false Enabled = false

View File

@ -105,6 +105,10 @@
;; For example: ;; For example:
Region_Welcome_Area = "DefaultRegion, FallbackRegion" Region_Welcome_Area = "DefaultRegion, FallbackRegion"
;; Allow supporting viewers to export content
;; Set to false to prevent export
ExportSupported = true
; === HG ONLY === ; === HG ONLY ===
;; If you have this set under [Hypergrid], no need to set it here, leave it commented ;; If you have this set under [Hypergrid], no need to set it here, leave it commented
; GatekeeperURI="http://127.0.0.1:9000" ; GatekeeperURI="http://127.0.0.1:9000"
@ -128,6 +132,9 @@
;; For Viewer 2 ;; For Viewer 2
MapTileURL = "http://127.0.0.1:9000/" MapTileURL = "http://127.0.0.1:9000/"
; Url to search service
; SearchURL = "http://127.0.0.1:8002";
; The minimum user level required for a user to be able to login. 0 by default ; The minimum user level required for a user to be able to login. 0 by default
; If you disable a particular user's account then you can set their login level below this number. ; If you disable a particular user's account then you can set their login level below this number.
; You can also change this level from the console though these changes will not be persisted. ; You can also change this level from the console though these changes will not be persisted.