check back in to worker pool once work is complete.
reformatted
when shutdown occurs, if data remains in the accumulator, pass it off to a
worker before terminate.
added a synchronous accept for use when you absolutely need to know that the data
has been processed - e.g. on termination
use accept_sync instead of accept in the terminate call so that the terminate
message can't reach the worker before it's done processing whatever is left
in the accumulator.
trap exits so that we can terminate gracefully and clean up data.
make sure we trap exit so that if we have data left over in the buffer, we flush it before death.
trap exit so that we can terminate gracefully
set size of receive buffer to be big.