Click here to Skip to main content
13,087,566 members (97,215 online)
Click here to Skip to main content
Alternatives (1)
Add your own
alternative version

Tagged as


33 bookmarked
Posted 23 Jan 2011

Simple Blocking Queue for Thread Communication and Inter-thread Invocation

A generic class to be used as a conveyor for data and tasks between threads


Members may post updates or alternatives to this current article in order to show different approaches or add new features.

24 Jan 2011
In .NET 4.0, you can use:New Concurrent.BlockingCollection(New Queue)This even has an option on the constructor to let you specify a maximum queue depth. If it reaches this depth, a call to Add will block until the consumer thread takes something out of the queue.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Sergey Alexandrovich Kryukov
United States United States
No Biography provided

| | Privacy | Terms of Use | Mobile
Web04 | 2.8.170813.1 | Last Updated 23 Jan 2011
Article Copyright 2011 by Sergey Alexandrovich Kryukov
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid