Skip to content

Commit

Permalink
ajust for line separator length on different OSes
Browse files Browse the repository at this point in the history
Signed-off-by: Ceki Gulcu <ceki@qos.ch>
  • Loading branch information
ceki committed Sep 6, 2024
1 parent b1b14ee commit 138953e
Showing 1 changed file with 1 addition and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -460,11 +460,6 @@ long logOverMultiplePeriods(ConfigParameters cp) {
int endInactivityIndex = startInactivityIndex + cp.numInactivityPeriods * ticksPerPeriod;
long tickDuration = cp.periodDurationInMillis / ticksPerPeriod;


System.out.println("--------------");
System.out.println("["+buildMessageString(new Date(tbrp.timeBasedFileNamingAndTriggeringPolicy.getCurrentTime()), 21)+"]");
System.out.println("--------------");

for (int i = 0; i <= runLength; i++) {
Date currentDate = new Date(tbrp.timeBasedFileNamingAndTriggeringPolicy.getCurrentTime());
if (i < startInactivityIndex || i > endInactivityIndex) {
Expand Down Expand Up @@ -497,7 +492,7 @@ private static String buildMessageString(Date currentDate, int i) {
String currentDateStr = currentDate.toString();
String iAsString = Integer.toString(i);
sb.append(currentDateStr);
SpacePadder.spacePad(sb, 66 + (3 - iAsString.length() - currentDateStr.length()));
SpacePadder.spacePad(sb, 68 + (3 - iAsString.length() - currentDateStr.length() - CoreConstants.LINE_SEPARATOR_LEN));
sb.append(iAsString);
return sb.toString();
}
Expand Down

0 comments on commit 138953e

Please sign in to comment.