One more module: EventQueueGetModule. Also making it non-optional for this dll.
parent
fb7bbe167a
commit
4ac857f902
|
@ -55,8 +55,8 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||||
public OSDMap body;
|
public OSDMap body;
|
||||||
}
|
}
|
||||||
|
|
||||||
//[Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")]
|
[Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule")]
|
||||||
public class EventQueueGetModule : IEventQueue, IRegionModule
|
public class EventQueueGetModule : IEventQueue, INonSharedRegionModule
|
||||||
{
|
{
|
||||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||||
|
|
||||||
|
@ -66,8 +66,6 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||||
public int DebugLevel { get; set; }
|
public int DebugLevel { get; set; }
|
||||||
|
|
||||||
protected Scene m_scene;
|
protected Scene m_scene;
|
||||||
private IConfigSource m_gConfig;
|
|
||||||
bool enabledYN;
|
|
||||||
|
|
||||||
private Dictionary<UUID, int> m_ids = new Dictionary<UUID, int>();
|
private Dictionary<UUID, int> m_ids = new Dictionary<UUID, int>();
|
||||||
|
|
||||||
|
@ -75,34 +73,17 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||||
private Dictionary<UUID, UUID> m_QueueUUIDAvatarMapping = new Dictionary<UUID, UUID>();
|
private Dictionary<UUID, UUID> m_QueueUUIDAvatarMapping = new Dictionary<UUID, UUID>();
|
||||||
private Dictionary<UUID, UUID> m_AvatarQueueUUIDMapping = new Dictionary<UUID, UUID>();
|
private Dictionary<UUID, UUID> m_AvatarQueueUUIDMapping = new Dictionary<UUID, UUID>();
|
||||||
|
|
||||||
#region IRegionModule methods
|
#region INonSharedRegionModule methods
|
||||||
public virtual void Initialise(Scene scene, IConfigSource config)
|
public virtual void Initialise(IConfigSource config)
|
||||||
{
|
{
|
||||||
m_gConfig = config;
|
}
|
||||||
|
|
||||||
IConfig startupConfig = m_gConfig.Configs["Startup"];
|
public void AddRegion(Scene scene)
|
||||||
|
|
||||||
ReadConfigAndPopulate(scene, startupConfig, "Startup");
|
|
||||||
|
|
||||||
if (enabledYN)
|
|
||||||
{
|
{
|
||||||
m_scene = scene;
|
m_scene = scene;
|
||||||
scene.RegisterModuleInterface<IEventQueue>(this);
|
scene.RegisterModuleInterface<IEventQueue>(this);
|
||||||
|
|
||||||
// Register fallback handler
|
|
||||||
// Why does EQG Fail on region crossings!
|
|
||||||
|
|
||||||
//scene.CommsManager.HttpServer.AddLLSDHandler("/CAPS/EQG/", EventQueueFallBack);
|
|
||||||
|
|
||||||
// scene.EventManager.OnNewClient += OnNewClient;
|
|
||||||
|
|
||||||
// TODO: Leaving these open, or closing them when we
|
|
||||||
// become a child is incorrect. It messes up TP in a big
|
|
||||||
// way. CAPS/EQ need to be active as long as the UDP
|
|
||||||
// circuit is there.
|
|
||||||
|
|
||||||
scene.EventManager.OnClientClosed += ClientClosed;
|
scene.EventManager.OnClientClosed += ClientClosed;
|
||||||
|
|
||||||
scene.EventManager.OnMakeChildAgent += MakeChildAgent;
|
scene.EventManager.OnMakeChildAgent += MakeChildAgent;
|
||||||
scene.EventManager.OnRegisterCaps += OnRegisterCaps;
|
scene.EventManager.OnRegisterCaps += OnRegisterCaps;
|
||||||
|
|
||||||
|
@ -117,18 +98,21 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||||
+ " >= 2 - turns on poll notification",
|
+ " >= 2 - turns on poll notification",
|
||||||
HandleDebugEq);
|
HandleDebugEq);
|
||||||
}
|
}
|
||||||
else
|
|
||||||
|
public void RemoveRegion(Scene scene)
|
||||||
{
|
{
|
||||||
m_gConfig = null;
|
if (m_scene != scene)
|
||||||
}
|
return;
|
||||||
|
|
||||||
|
scene.EventManager.OnClientClosed -= ClientClosed;
|
||||||
|
scene.EventManager.OnMakeChildAgent -= MakeChildAgent;
|
||||||
|
scene.EventManager.OnRegisterCaps -= OnRegisterCaps;
|
||||||
|
|
||||||
|
scene.UnregisterModuleInterface<IEventQueue>(this);
|
||||||
|
m_scene = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ReadConfigAndPopulate(Scene scene, IConfig startupConfig, string p)
|
public void RegionLoaded(Scene scene)
|
||||||
{
|
|
||||||
enabledYN = startupConfig.GetBoolean("EventQueue", true);
|
|
||||||
}
|
|
||||||
|
|
||||||
public void PostInitialise()
|
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -141,10 +125,11 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||||
get { return "EventQueueGetModule"; }
|
get { return "EventQueueGetModule"; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool IsSharedModule
|
public Type ReplaceableInterface
|
||||||
{
|
{
|
||||||
get { return false; }
|
get { return null; }
|
||||||
}
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
protected void HandleDebugEq(string module, string[] args)
|
protected void HandleDebugEq(string module, string[] args)
|
||||||
|
|
|
@ -57,9 +57,6 @@
|
||||||
; ## CLIENTS
|
; ## CLIENTS
|
||||||
; ##
|
; ##
|
||||||
|
|
||||||
; Enables EventQueueGet Service.
|
|
||||||
EventQueue = true
|
|
||||||
|
|
||||||
; Set this to the DLL containing the client stack to use.
|
; Set this to the DLL containing the client stack to use.
|
||||||
clientstack_plugin="OpenSim.Region.ClientStack.LindenUDP.dll"
|
clientstack_plugin="OpenSim.Region.ClientStack.LindenUDP.dll"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue