Overview | Releases | Download | Docs | Links | Help | RecentChanges

SctService

Many of the services have the following remit:
  1. listen for new data from IS
  2. do something time-consuming with that data.
  3. at the same time be able to respond to other data & status requests.

The SctService package simplifies dividing these two jobs between different threads, so that the listener thread of the program can be freed from time-consuming computation, and can react to further requests (1,3), while one or more worker threads do the CPU-intensive work(2).

Basically, the listener reacts to new data by adding it to a queue, and returning. The worker(s) pop objects off the queue, and perform some work on them.

The implimentation uses a WorkerGroup? class, which creates it's own worker threads. The class is templated with the type of the data which is to be placed in the queue.

The thread library used is that of [boost].