final DateTime end = start.plusMinutes(66);
DateTime now = start;
int val = 1;
while (now.isBefore(end)) {
aggregateCounterRepository.increment(counterName, val++, now);
now = now.plus(Duration.standardMinutes(1));
}
// Include 66th minute's value
aggregateCounterRepository.increment(counterName, val++, now);
long[] counts = aggregateCounterRepository.getCounts(counterName, new Interval(start, end), AggregateCountResolution.minute).getCounts();
// the counts.length should be 66 + 1 to include the 66th minute's count