Flush data from a thread

Summary:
This helps stabalize timing differences between nodes.  It also solves a major issue with the @throttle approach:

Basically with @throttle, the write callback would fire for the first
value in an interval, it would immediatly flush and then throttle would
block for the next second.

In essence, each flush would flush part of the previous second's data and part of the next second's data.

Test Plan: none

Reviewers: ankur

Differential Revision: http://grizzly.memsql.com/D3921