add function: setFlushRate()