autoresetevent
Is the AutoResetEvent type an appropriate choice for an atomic switch?
Suppose I am processing a large amount of incoming data from multiple threads. I may want for this data to act as a trigger for a specific action when certain criteria are met. However, the action is[详细]
2023-01-15 04:19 分类:问答AutoResetEvent not blocking properly
I have a thread, which creates a variable number of worker threads and distributes tasks between them. This is solved by passing the threads a TaskQueue object, whose implementation you will see below[详细]
2023-01-13 05:51 分类:问答Unit-test passes in Debug, but hangs when Run
I have an odd problem. I have a unit test that keeps getting stuck in Run Mode. When I run the same开发者_开发技巧 test in Debug, with no breakpoints, the test passes every time.[详细]
2023-01-07 18:00 分类:问答Queues And Wait Handles in C#
I\'ve had the following code in my application for some years and have never seen an issue from it. while ((PendingOrders.Count > 0) || (WaitHandle.WaitAny(CommandEventArr) != 1))[详细]
2022-12-28 21:19 分类:问答AutoResetEvent object , waits 60 secs OR event
Im using AutoResetEvent object to block a thread for 60 secs ,, but I would like to开发者_运维知识库 block it for 60 secs or AutoResetEvent.set() event[详细]
2022-12-19 19:55 分类:问答Does AutoResetEvent.WaitOne() frees a slot in the thread pool?
I am trying to synchronize an asynchronous method. The main advantage of the async version is that it frees a slot in the thread pool. I would like to keep this advantage in my开发者_JS百科 sync versi[详细]
2022-12-12 17:30 分类:问答Whats wrong with my AutoResetEvent code?
I have this code which seems pretty straightforward but the AutoResetEvent never gets signalled. Nothing seems to get returned from the web services and the WaitAll just times out after ten seconds. E[详细]
2022-12-12 05:37 分类:问答