Async Callback on custom queue

133 views Asked by At

I am writing a class which uses the TCP-socket with "BeginRead"

As i see it, whenever data is read, a delegate to the callback function is placed in the threadpool queue whenever data is read (Is this correct?). Now i was wondering if it was possible to place this callback on another queue?

In my program i have 1 work-queue, with its own thread. So i place every event in this queue and never have race-conditions. Now i let the delegate get's invoked on the threadpool, and i immidiately place a new delegate on my own queue. One step too much which i like to avoid if possible.

0

There are 0 answers