Added synchronize example
Added option to disable worker thread to avoid losing work on shutdown