revalNG / omnithreadlibrary

Automatically exported from code.google.com/p/omnithreadlibrary
0 stars 0 forks source link

TaskGroup example #33

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Hello!

Why does the main UI freeze when stoping all tasks in the TaskGroup test.

Thanks

Original issue reported on code.google.com by david.lo...@gmail.com on 24 Nov 2012 at 11:16

GoogleCodeExporter commented 8 years ago
Because the code calls TerminateAll without a parameter and that blocks until 
all tasks are terminated.

Original comment by gabr42 on 2 Dec 2012 at 6:10

GoogleCodeExporter commented 8 years ago

Original comment by gabr42 on 2 Dec 2012 at 6:10

GoogleCodeExporter commented 8 years ago
Yes but how to avoid this? TerminateAll(0) ? 

Can i create and stop tasks within Parallel.Async() to avoid blocking the main 
UI when stoping and starting thread pool?

Original comment by david.lo...@gmail.com on 2 Dec 2012 at 6:14