Add flush of output buffers for logging
Merge pull request #520 from adamrp/rest_data_logger

Add flush of output buffers for logging