aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/BlockingQueue.cs (unfollow)
Commit message (Collapse)AuthorFilesLines
2013-07-18Revert "Revert "I confuse myself. Let's try this variable name instead.""Diva Canto1-3/+3
This reverts commit 52dc7b2a96a28798d55d07d79d003ce5e3d35216.
2013-07-18Revert "Revert "Do the same trick that dahlia did for Dequeue(timeout)""Diva Canto1-2/+3
This reverts commit 5495df74436d6c0039a1500d979a964b003abfdf.
2013-07-18Revert "Revert "Didn't mean to commit this change in BlockingQueue.cs""Diva Canto1-1/+1
This reverts commit fda91d93dad1fa6f901e8db5829aa8b70477c97e.
2013-07-18Reverting the reverts I did yesterday. cpu-branch has now beenDiva Canto1-1/+1
successfully tested, and I'm merging back those changes, which proved to be good. Revert "Revert "Cleared up much confusion in PollServiceRequestManager. Here's the history:"" This reverts commit fa2370b32ee57a07f27501152c3c705a883b13d8.
2013-07-17Revert "Cleared up much confusion in PollServiceRequestManager. Here's the ↵Diva Canto1-1/+1
history:" This reverts commit e46459ef21e1ee5ceaeca70365a7c881d33b09ce.
2013-07-17Revert "Didn't mean to commit this change in BlockingQueue.cs"Diva Canto1-1/+1
This reverts commit 0f5b616fb0ebf9207b3cc81771622ed1290ea7d6.
2013-07-17Revert "Do the same trick that dahlia did for Dequeue(timeout)"Diva Canto1-3/+2
This reverts commit af792bc7f2504e9ccf1c8ae7568919785dc397c9.
2013-07-17Revert "I confuse myself. Let's try this variable name instead."Diva Canto1-3/+3
This reverts commit 1d3deda10cf85abd68a5f904d6698ae597a67cc0.
2013-07-17I confuse myself. Let's try this variable name instead.Diva Canto1-3/+3
2013-07-17Do the same trick that dahlia did for Dequeue(timeout)Diva Canto1-2/+3
2013-07-17Didn't mean to commit this change in BlockingQueue.csDiva Canto1-1/+1
2013-07-17Cleared up much confusion in PollServiceRequestManager. Here's the history:Diva Canto1-1/+1
When Melanie added the web fetch inventory throttle to core, she made the long poll requests (EQs) effectively be handled on an active loop. All those requests, if they existed, were being constantly dequeued, checked for events (which most often they didn't have), and requeued again. This was an active loop thread on a 100ms cycle! This fixes the issue. Now the inventory requests, if they aren't ready to be served, are placed directly back in the queue, but the long poll requests aren't placed there until there are events ready to be sent or timeout has been reached. This puts the LongPollServiceWatcherThread back to 1sec cycle, as it was before.
2013-07-16minor: Add warning method doc about possibly inconsistent results returned ↵Justin Clark-Casey (justincc)1-1/+19
from BlockingQueue.Contains(), Count() and GetQueueArray()
2013-07-16Revert "Revert "MSDN documentation is unclear about whether exiting a lock() ↵Justin Clark-Casey (justincc)1-5/+8
block will trigger a Monitor.Wait() to exit, so avoid some locks that don't actually affect the state of the internal queues in the BlockingQueue class."" This reverts commit 21a09ad3ad42b24bce4fc04c6bcd6f7d9a80af08. After more analysis and discussion, it is apparant that the Count(), Contains() and GetQueueArray() cannot be made thread-safe anyway without external locking And this change appears to have a positive impact on performance. I still believe that Monitor.Exit() will not release any thread for Monitor.Wait(), as per http://msdn.microsoft.com/en-gb/library/vstudio/system.threading.monitor.exit%28v=vs.100%29.aspx so this should in theory make no difference, though mono implementation issues could possibly be coming into play.
2013-07-16Revert "MSDN documentation is unclear about whether exiting a lock() block ↵Justin Clark-Casey (justincc)1-8/+5
will trigger a Monitor.Wait() to exit, so avoid some locks that don't actually affect the state of the internal queues in the BlockingQueue class." This reverts commit 42e2a0d66eaa7e322bce817e9e2cc9a288de167b Reverting because unfortunately this introduces race conditions because Contains(), Count() and GetQueueArray() may now end up returning the wrong result if another thread performs a simultaneous update on m_queue. Code such as PollServiceRequestManager.Stop() relies on the count being correct otherwise a request may be lost. Also, though some of the internal queue methods do not affect state, they are not thread-safe and could return the wrong result generating the same problem lock() generates Monitor.Enter() and Monitor.Exit() under the covers. Monitor.Exit() does not cause Monitor.Wait() to exist, only Pulse() and PulseAll() will do this Reverted with agreement.
2013-07-16MSDN documentation is unclear about whether exiting a lock() block will ↵dahlia1-5/+8
trigger a Monitor.Wait() to exit, so avoid some locks that don't actually affect the state of the internal queues in the BlockingQueue class.
2009-10-19Formatting cleanup.Jeff Ames1-3/+3
2009-10-01Fixing LLClientView memory leakJames J Greensky1-1/+4
Fixing LLClientView memory leak by disposing of all timers utilized in LLClientView as they contain references to the callback method. This required the use of the Terminate and Close infrastructure that was already in place but was not being utilized.
2009-06-01Minor: Change OpenSim to OpenSimulator in older copyright headers and ↵Jeff Ames1-1/+1
LICENSE.txt.
2009-03-13* Support loading empty folders in an iarJustin Clarke Casey1-0/+1
2008-11-09Update svn properties. Add copyright headers. Minor formatting cleanup.Jeff Ames1-1/+1
2008-11-08* Fixed a major memory leak in packet processing - PacketQueue.Close is ↵Adam Frisby1-0/+9
never called, causing the PacketQueue for dead clients to be preserved (including it's contents). * This patch is highly experimental and may cause clients to not be able to connect, if this is the case, it will be rolled back in approximately 5 minutes.
2008-09-27- adding Dequeue with a timeout to the BlockingQueueHomer Horwitz1-0/+17
2008-07-23Update svn properties. Formatting cleanup. Remove a compiler warning.Jeff Ames1-2/+2
2008-07-22Refactor the packet scheduling out of ClientView. Add intelligentMelanie Thielker1-3/+17
resending, timeouts, packet discarding. Add notification event for packet discarding. Add priority scheduling for packet queues. Add outgoing duplicate detection facility. Correct packet sequencing. Make provisions for automatic server side throttle adjustments (comes in next installment)
2008-04-29* Spring cleaning.Adam Frisby1-6/+6
* Added new generic "Location" class to handle 2D integer locations. Going to use it to replace all RegionHandle and X,Y coordinate references throughout the entire project. You have been warned.
2008-04-24replace hard tabs with 4 spaces to be consistant in the source.Sean Dague1-3/+3
Please adjust your editors to not use hard tabs.
2008-04-14Possible fix for the 100% CPU issue. I've not fully Sean Dague1-2/+8
confirmed that this fixes the issue, however functional correctness of BlockingQueue requires that these locks be put into place anyway.
2008-03-18Formatting cleanup.Jeff Ames1-26/+26
2008-03-04Merged 3Di code that provides scene and avatar serialization, and plugin ↵Johan Berntsson1-0/+5
support for region move/split/merge. See ThirdParty/3Di/README.txt. Unless the new modules are used there should be no noticeable changes when running OpenSim.
2008-02-09Mostly debugging verbosity which I shall very shortly comment out.Justin Clarke Casey1-1/+6
Just want to try this out on windows quickly.
2008-01-03* Added lock to Contains to avoid enumeration exceptionslbsa711-1/+4
2008-01-02* Trying to address TextureSender issueslbsa711-9/+16
* The BlockingQueue exposes Contains so we can make sure we don't add a TextureSender to the queue if there's already one present * introduced some TryGetValue and various code convention stuff
2007-12-27* Optimized usingslbsa711-2/+2
* shortened references * Removed redundant 'this' * Normalized EOF
2007-12-22minor refactorJustin Clarke Casey1-1/+1
2007-12-10saved OpenSim source code from the giant rampaging unterminated copyright ↵Jeff Ames1-2/+2
notice of doom
2007-10-31* Moved OpenSim/Framework/General to OpenSim/Framework for great justice.lbsa711-0/+0
2007-10-30* Optimized usingslbsa711-1/+1
* Shortened type references * Removed redundant 'this' qualifier
2007-10-29as per the "Filesystem cleanup for OpenSim repository" mailing list thread. ↵MW1-1/+1
Have flattened the OpenSim.Framework project/namespace. The problem is that the namespace is still wrong as its "OpenSim.Framework" while the directory is "OpenSim\Framework\General" , so we need to decide if we change the directory or correct the namespace. Note this has lead to a big flat project, but I think a lot of the files we most likely don't even use any longer. And others belong in other projects/namespaces anyway.
2007-09-10mass update of urls in source code to new websiteSean Dague1-1/+1
2007-07-16changed to native line ending encodingSean Dague1-58/+58
2007-07-03* Optimized usings (the 'LL ate my scripts' commit)lbsa711-3/+1
* added some licensing info