Commit graph

2 commits

Author SHA1 Message Date
Gavin Andresen f50105486f
More robust CScheduler unit test
On a busy or slow system, the CScheduler unit test could fail because it
assumed all threads would be done after a couple of milliseconds.

Replace the hard-coded sleep with CScheduler stop() method that
will cleanly exit the servicing threads when all tasks are completely
finished.
2015-05-16 17:59:23 -04:00
Gavin Andresen 928b950e3b
CScheduler class for lightweight task scheduling
Simple class to manage a task queue that is serviced by one or
more threads.
2015-05-14 10:37:19 -04:00