Use boost::thread to dispatch buffered queries
Merge branch 'fix_callback_performance' into develop