Fixed consume_period by estimating chunk inter-arrival time