Fix for replenishing schedule
This fixes the unusual replenish per rate schedule, where the replenish
was scheduled as: 1 minute – (n - 1) * timeLapse. It was unintended to
be firstly replenished in 1 minute. Meaning, it should have been
scheduled as (n) * timeLapse.
It is ambiguous why scheduleAtFixedRate method is not executed after an
initial delay, and considers the initial delay variable as a first
period. However, by walking through the previous versions, since it is
evident that scheduleAtFixedRate method indeed considers the initial
delay as the first period, this fixes accordingly.
Change-Id: I36273b8f70acab470a2322e7b091f1031acf23f7
4 files changed