aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs4
-rw-r--r--OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs34
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs2
-rw-r--r--OpenSim/Region/CoreModules/Scripting/LSLHttp/UrlModule.cs16
4 files changed, 43 insertions, 13 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs b/OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs
index c7d4283..e73a04a 100644
--- a/OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs
+++ b/OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs
@@ -376,7 +376,7 @@ namespace OpenSim.Region.ClientStack.Linden
376 // TODO: Add EventQueueGet name/description for diagnostics 376 // TODO: Add EventQueueGet name/description for diagnostics
377 MainServer.Instance.AddPollServiceHTTPHandler( 377 MainServer.Instance.AddPollServiceHTTPHandler(
378 eventQueueGetPath, 378 eventQueueGetPath,
379 new PollServiceEventArgs(null, HasEvents, GetEvents, NoEvents, agentID)); 379 new PollServiceEventArgs(null, HasEvents, GetEvents, NoEvents, agentID, 40000));
380 380
381// m_log.DebugFormat( 381// m_log.DebugFormat(
382// "[EVENT QUEUE GET MODULE]: Registered EQG handler {0} for {1} in {2}", 382// "[EVENT QUEUE GET MODULE]: Registered EQG handler {0} for {1} in {2}",
@@ -418,7 +418,7 @@ namespace OpenSim.Region.ClientStack.Linden
418 } 418 }
419 } 419 }
420 420
421 public Hashtable GetEvents(UUID requestID, UUID pAgentId, string request) 421 public Hashtable GetEvents(UUID requestID, UUID pAgentId)
422 { 422 {
423 if (DebugLevel >= 2) 423 if (DebugLevel >= 2)
424 m_log.DebugFormat("POLLED FOR EQ MESSAGES BY {0} in {1}", pAgentId, m_scene.RegionInfo.RegionName); 424 m_log.DebugFormat("POLLED FOR EQ MESSAGES BY {0} in {1}", pAgentId, m_scene.RegionInfo.RegionName);
diff --git a/OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs b/OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs
index 7dd9770..d1afff2 100644
--- a/OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs
+++ b/OpenSim/Region/ClientStack/Linden/Caps/WebFetchInvDescModule.cs
@@ -71,6 +71,11 @@ namespace OpenSim.Region.ClientStack.Linden
71 private IInventoryService m_InventoryService; 71 private IInventoryService m_InventoryService;
72 private ILibraryService m_LibraryService; 72 private ILibraryService m_LibraryService;
73 73
74 private bool m_Enabled;
75
76 private string m_fetchInventoryDescendents2Url;
77 private string m_webFetchInventoryDescendentsUrl;
78
74 private static WebFetchInvDescHandler m_webFetchHandler; 79 private static WebFetchInvDescHandler m_webFetchHandler;
75 80
76 private Dictionary<UUID, string> m_capsDict = new Dictionary<UUID, string>(); 81 private Dictionary<UUID, string> m_capsDict = new Dictionary<UUID, string>();
@@ -83,15 +88,32 @@ namespace OpenSim.Region.ClientStack.Linden
83 88
84 public void Initialise(IConfigSource source) 89 public void Initialise(IConfigSource source)
85 { 90 {
91 IConfig config = source.Configs["ClientStack.LindenCaps"];
92 if (config == null)
93 return;
94
95 m_fetchInventoryDescendents2Url = config.GetString("Cap_FetchInventoryDescendents2", string.Empty);
96 m_webFetchInventoryDescendentsUrl = config.GetString("Cap_WebFetchInventoryDescendents", string.Empty);
97
98 if (m_fetchInventoryDescendents2Url != string.Empty || m_webFetchInventoryDescendentsUrl != string.Empty)
99 {
100 m_Enabled = true;
101 }
86 } 102 }
87 103
88 public void AddRegion(Scene s) 104 public void AddRegion(Scene s)
89 { 105 {
106 if (!m_Enabled)
107 return;
108
90 m_scene = s; 109 m_scene = s;
91 } 110 }
92 111
93 public void RemoveRegion(Scene s) 112 public void RemoveRegion(Scene s)
94 { 113 {
114 if (!m_Enabled)
115 return;
116
95 m_scene.EventManager.OnRegisterCaps -= RegisterCaps; 117 m_scene.EventManager.OnRegisterCaps -= RegisterCaps;
96 m_scene.EventManager.OnDeregisterCaps -= DeregisterCaps; 118 m_scene.EventManager.OnDeregisterCaps -= DeregisterCaps;
97 m_scene = null; 119 m_scene = null;
@@ -99,6 +121,9 @@ namespace OpenSim.Region.ClientStack.Linden
99 121
100 public void RegionLoaded(Scene s) 122 public void RegionLoaded(Scene s)
101 { 123 {
124 if (!m_Enabled)
125 return;
126
102 m_InventoryService = m_scene.InventoryService; 127 m_InventoryService = m_scene.InventoryService;
103 m_LibraryService = m_scene.LibraryService; 128 m_LibraryService = m_scene.LibraryService;
104 129
@@ -156,12 +181,12 @@ namespace OpenSim.Region.ClientStack.Linden
156 private Scene m_scene; 181 private Scene m_scene;
157 182
158 public PollServiceInventoryEventArgs(Scene scene, UUID pId) : 183 public PollServiceInventoryEventArgs(Scene scene, UUID pId) :
159 base(null, null, null, null, pId) 184 base(null, null, null, null, pId, int.MaxValue)
160 { 185 {
161 m_scene = scene; 186 m_scene = scene;
162 187
163 HasEvents = (x, y) => { lock (responses) return responses.ContainsKey(x); }; 188 HasEvents = (x, y) => { lock (responses) return responses.ContainsKey(x); };
164 GetEvents = (x, y, z) => 189 GetEvents = (x, y) =>
165 { 190 {
166 lock (responses) 191 lock (responses)
167 { 192 {
@@ -283,11 +308,15 @@ namespace OpenSim.Region.ClientStack.Linden
283 308
284 private void RegisterCaps(UUID agentID, Caps caps) 309 private void RegisterCaps(UUID agentID, Caps caps)
285 { 310 {
311 if (m_fetchInventoryDescendents2Url == "")
312 return;
313
286 string capUrl = "/CAPS/" + UUID.Random() + "/"; 314 string capUrl = "/CAPS/" + UUID.Random() + "/";
287 315
288 // Register this as a poll service 316 // Register this as a poll service
289 PollServiceInventoryEventArgs args = new PollServiceInventoryEventArgs(m_scene, agentID); 317 PollServiceInventoryEventArgs args = new PollServiceInventoryEventArgs(m_scene, agentID);
290 318
319 args.Type = PollServiceEventArgs.EventType.Inventory;
291 MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args); 320 MainServer.Instance.AddPollServiceHTTPHandler(capUrl, args);
292 321
293 string hostName = m_scene.RegionInfo.ExternalHostName; 322 string hostName = m_scene.RegionInfo.ExternalHostName;
@@ -300,6 +329,7 @@ namespace OpenSim.Region.ClientStack.Linden
300 port = MainServer.Instance.SSLPort; 329 port = MainServer.Instance.SSLPort;
301 protocol = "https"; 330 protocol = "https";
302 } 331 }
332
303 caps.RegisterHandler("FetchInventoryDescendents2", String.Format("{0}://{1}:{2}{3}", protocol, hostName, port, capUrl)); 333 caps.RegisterHandler("FetchInventoryDescendents2", String.Format("{0}://{1}:{2}{3}", protocol, hostName, port, capUrl));
304 334
305 m_capsDict[agentID] = capUrl; 335 m_capsDict[agentID] = capUrl;
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
index e47397d..9784d15 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
@@ -4828,7 +4828,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
4828 4828
4829 public void SendForceClientSelectObjects(List<uint> ObjectIDs) 4829 public void SendForceClientSelectObjects(List<uint> ObjectIDs)
4830 { 4830 {
4831 m_log.WarnFormat("[LLCLIENTVIEW] sending select with {0} objects", ObjectIDs.Count); 4831// m_log.DebugFormat("[LLCLIENTVIEW] sending select with {0} objects", ObjectIDs.Count);
4832 4832
4833 bool firstCall = true; 4833 bool firstCall = true;
4834 const int MAX_OBJECTS_PER_PACKET = 251; 4834 const int MAX_OBJECTS_PER_PACKET = 251;
diff --git a/OpenSim/Region/CoreModules/Scripting/LSLHttp/UrlModule.cs b/OpenSim/Region/CoreModules/Scripting/LSLHttp/UrlModule.cs
index c9cd412..def8162 100644
--- a/OpenSim/Region/CoreModules/Scripting/LSLHttp/UrlModule.cs
+++ b/OpenSim/Region/CoreModules/Scripting/LSLHttp/UrlModule.cs
@@ -235,9 +235,9 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp
235 235
236 string uri = "/lslhttp/" + urlcode.ToString() + "/"; 236 string uri = "/lslhttp/" + urlcode.ToString() + "/";
237 237
238 m_HttpServer.AddPollServiceHTTPHandler( 238 PollServiceEventArgs args = new PollServiceEventArgs(HttpRequestHandler, HasEvents, GetEvents, NoEvents, urlcode, 25000);
239 uri, 239 args.Type = PollServiceEventArgs.EventType.LslHttp;
240 new PollServiceEventArgs(HttpRequestHandler, HasEvents, GetEvents, NoEvents, urlcode)); 240 m_HttpServer.AddPollServiceHTTPHandler(uri, args);
241 241
242 m_log.DebugFormat( 242 m_log.DebugFormat(
243 "[URL MODULE]: Set up incoming request url {0} for {1} in {2} {3}", 243 "[URL MODULE]: Set up incoming request url {0} for {1} in {2} {3}",
@@ -280,9 +280,9 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp
280 280
281 string uri = "/lslhttps/" + urlcode.ToString() + "/"; 281 string uri = "/lslhttps/" + urlcode.ToString() + "/";
282 282
283 m_HttpsServer.AddPollServiceHTTPHandler( 283 PollServiceEventArgs args = new PollServiceEventArgs(HttpRequestHandler, HasEvents, GetEvents, NoEvents, urlcode, 25000);
284 uri, 284 args.Type = PollServiceEventArgs.EventType.LslHttp;
285 new PollServiceEventArgs(HttpRequestHandler, HasEvents, GetEvents, NoEvents, urlcode)); 285 m_HttpsServer.AddPollServiceHTTPHandler(uri, args);
286 286
287 m_log.DebugFormat( 287 m_log.DebugFormat(
288 "[URL MODULE]: Set up incoming secure request url {0} for {1} in {2} {3}", 288 "[URL MODULE]: Set up incoming secure request url {0} for {1} in {2} {3}",
@@ -516,7 +516,7 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp
516 } 516 }
517 } 517 }
518 518
519 private Hashtable GetEvents(UUID requestID, UUID sessionID, string request) 519 private Hashtable GetEvents(UUID requestID, UUID sessionID)
520 { 520 {
521 Hashtable response; 521 Hashtable response;
522 522
@@ -668,4 +668,4 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp
668 ScriptRemoved(itemID); 668 ScriptRemoved(itemID);
669 } 669 }
670 } 670 }
671} \ No newline at end of file 671}