Skip to content

Commit

Permalink
[LOGMGR-163] Use the first day of the month when calculating the next…
Browse files Browse the repository at this point in the history
… rollover for monthly file rotations.
  • Loading branch information
jamezp committed Jul 7, 2017
1 parent 994267d commit df973c9
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,8 @@ private void calcNextRollover(final long fromTime) {
case YEAR:
calendar.set(Calendar.MONTH, 0);
case MONTH:
calendar.set(Calendar.DAY_OF_MONTH, 0);
// Needs to be set to the first day of the month
calendar.set(Calendar.DAY_OF_MONTH, 1);
calendar.clear(Calendar.WEEK_OF_MONTH);
case WEEK:
if (period == Period.WEEK) {
Expand Down

0 comments on commit df973c9

Please sign in to comment.