aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorUbitUmarov2014-07-24 17:14:14 +0100
committerUbitUmarov2014-07-24 17:14:14 +0100
commitee951f7a1038eee5f0760674b0cffab9a6d0328f (patch)
tree7252d30c494d73322e97927d2ed60a533b106244 /OpenSim
parentlet BlockingQueue timeout work as its suposed to and not wait for ever (diff)
downloadopensim-SC_OLD-ee951f7a1038eee5f0760674b0cffab9a6d0328f.zip
opensim-SC_OLD-ee951f7a1038eee5f0760674b0cffab9a6d0328f.tar.gz
opensim-SC_OLD-ee951f7a1038eee5f0760674b0cffab9a6d0328f.tar.bz2
opensim-SC_OLD-ee951f7a1038eee5f0760674b0cffab9a6d0328f.tar.xz
EventQueueGetModule: dont reuse queues, we dont know whats there; make
pool silently loose requests for unknown avatars, or they will stay active until timeout after close ( possible not a big problem after not reusing queues ? )
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs19
1 files changed, 9 insertions, 10 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs b/OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs
index ffb53af..e0ce35b 100644
--- a/OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs
+++ b/OpenSim/Region/ClientStack/Linden/Caps/EventQueue/EventQueueGetModule.cs
@@ -307,12 +307,12 @@ namespace OpenSim.Region.ClientStack.Linden
307 lock (m_AvatarQueueUUIDMapping) 307 lock (m_AvatarQueueUUIDMapping)
308 { 308 {
309 // Reuse open queues. The client does! 309 // Reuse open queues. The client does!
310 if (m_AvatarQueueUUIDMapping.ContainsKey(agentID)) 310// if (m_AvatarQueueUUIDMapping.ContainsKey(agentID))
311 { 311// {
312 //m_log.DebugFormat("[EVENTQUEUE]: Found Existing UUID!"); 312 //m_log.DebugFormat("[EVENTQUEUE]: Found Existing UUID!");
313 eventQueueGetUUID = m_AvatarQueueUUIDMapping[agentID]; 313// eventQueueGetUUID = m_AvatarQueueUUIDMapping[agentID];
314 } 314// }
315 else 315// else
316 { 316 {
317 eventQueueGetUUID = UUID.Random(); 317 eventQueueGetUUID = UUID.Random();
318 //m_log.DebugFormat("[EVENTQUEUE]: Using random UUID!"); 318 //m_log.DebugFormat("[EVENTQUEUE]: Using random UUID!");
@@ -345,9 +345,6 @@ namespace OpenSim.Region.ClientStack.Linden
345 345
346 public bool HasEvents(UUID requestID, UUID agentID) 346 public bool HasEvents(UUID requestID, UUID agentID)
347 { 347 {
348 // Don't use this, because of race conditions at agent closing time
349 //Queue<OSD> queue = TryGetQueue(agentID);
350
351 Queue<OSD> queue = GetQueue(agentID); 348 Queue<OSD> queue = GetQueue(agentID);
352 if (queue != null) 349 if (queue != null)
353 lock (queue) 350 lock (queue)
@@ -356,7 +353,8 @@ namespace OpenSim.Region.ClientStack.Linden
356 return queue.Count > 0; 353 return queue.Count > 0;
357 } 354 }
358 355
359 return false; 356 m_log.WarnFormat("POLLED FOR EVENTS BY {0} unknown agent", agentID);
357 return true;
360 } 358 }
361 359
362 /// <summary> 360 /// <summary>
@@ -382,7 +380,8 @@ namespace OpenSim.Region.ClientStack.Linden
382 Queue<OSD> queue = GetQueue(pAgentId); 380 Queue<OSD> queue = GetQueue(pAgentId);
383 if (queue == null) 381 if (queue == null)
384 { 382 {
385 return NoEvents(requestID, pAgentId); 383 //return NoEvents(requestID, pAgentId);
384 return null;
386 } 385 }
387 386
388 OSD element; 387 OSD element;