Changes for version 0.02 - 2012-09-03
- kal: - fixed version numbers and time stamper
- fixed not sharing _cmd signaler to new workers
- fixed not sharing _pid to new workers
- added boss_sleep() and workers_sleep() methods
- this causes boss/workers to finish their current task, then enter a sleep state until woken or killed
- added boss_wake() and workers_wake()
- causes boss/workers to wake from a sleep state. if already awake, does nothing.
- added work log
- if worker has a return value, it stores it in a work log. The boss on each cycle will either empty this log or you can assign an optional callback for the boss to process the data. regardless, this log is deleted on each boss thread cycle.
- added a semaphor to lock access to this log. probably best if you only return a pass/fail from a worker. ;)
- fixed some POD commenting
Modules
Creates a "boss" which feeds a queue, which is serviced by a pool of threads called "workers". This module aims to be lightweight with limited features. Its primary aim is to provide simple Boss/Worker thread management while keeping dependencies low.