Chunk server: fix write appenders buffer flush accounting, and logic with client threads by not flushing write appenders that are currently waiting to acquire the mutex, unless low on buffers, and updating the total pending byte count by invoking get flush limit method at the beginning of the flush self method, to properly handle low on buffers flush. Optimize and remove any possible dependencies on ostream [local] formatting in chunk checksum calculation by using ConvertInt class instead ostringstream. Move appenders state change after re-lock to perform the state change with the global lock is acquired.
Chunk server: fix write appenders buffer flush accounting, and logic with client threads by not flushing write appenders that are currently waiting to acquire the mutex, unless low on buffers, and updating the total pending byte count by invoking get flush limit method at the beginning of the flush self method, to properly handle low on buffers flush. Optimize and remove any possible dependencies on ostream [local] formatting in chunk checksum calculation by using ConvertInt class instead ostringstream. Move appenders state change after re-lock to perform the state change with the global lock is acquired.

thebigbrain/qfs,quantcast/qfs,chanwit/qfs,chanwit/qfs,qnu/qfs,qnu/qfs,fengshao0907/qfs,fengshao0907/qfs,thebigbrain/qfs,fengshao0907/qfs,quantcast/qfs,fengshao0907/qfs,fengshao0907/qfs,fengshao0907/qfs,thebigbrain/qfs,chanwit/qfs,quantcast/qfs,qnu/qfs,qnu/qfs,fengshao0907/qfs,quantcast/qfs,qnu/qfs,chanwit/qfs,chanwit/qfs,thebigbrain/qfs,quantcast/qfs,thebigbrain/qfs,qnu/qfs,fengshao0907/qfs,thebigbrain/qfs,qnu/qfs,qnu/qfs,quantcast/qfs,chanwit/qfs,thebigbrain/qfs,thebigbrain/qfs,quantcast/qfs,chanwit/qfs,chanwit/qfs,quantcast/qfs