Thank you for the suggestion<br /><br />I've tried it, and it seems to set the aux part on application launch, but not on new log creation. So, specifically, right now I get:<br /><br />2012-06-11.1201.1.log (creation time 12:01, application launched)<br />2012-06-11.1201.2.log (creation time e.g. 12:05, rollover due to size)<br />2012-06-11.1201.3.log (creation time e.g. 12:10, rollover due to size)<br /><br /><br />What I'm trying to achieve is the following:<br /><br />2012-06-11.1201.1.log (creation time 12:01, application launched)<br />2012-06-11.1205.2.log (creation time e.g. 12:05, rollover due to size)<br />2012-06-11.1210.3.log (creation time e.g. 12:10, rollover due to size)<br /><br />The rollover, according to policies in effect, occurs on log size or every day. <br />What could be the issue here?<br> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div style="font-family: times new roman, new
york, times, serif; font-size: 12pt;"> <div dir="ltr" > <font size="2" face="Arial"> <hr size="1"> <b><span style="font-weight:bold;">From:</span></b> ceki <ceki@qos.ch><br> <b><span style="font-weight: bold;">To:</span></b> logback users list <logback-user@qos.ch> <br> <b><span style="font-weight: bold;">Sent:</span></b> Friday, June 8, 2012 3:57:11 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: [logback-user] Log rollover: activate based on size but keep "creation date" in file name?<br> </font> </div> <br>Hi Yura,<BR><BR>Have you tried auxiliary timestamps in fileNamePattern? For example,<BR><BR> %d{yyyy-MM-dd}-%d{HHmm,aux}.%{i},log<BR><BR>The primary date token, %d{yyyy-MM-dd}, determines roll over period,<BR>i.e. 24 hours, where the auxiliary pattern, %d{HHmm,aux} contributes<BR>to the file name of the archived log files.<BR><BR>For more details, refer to docs on
TimeBasedRollingPolicy's<BR>fileNamePattern [1].<BR><BR>HTH,<BR><BR>[1] <a href="http://logback.qos.ch/manual/appenders.html#TimeBasedRollingPolicy" target=_blank >http://logback.qos.ch/manual/appenders.html#TimeBasedRollingPolicy</a><BR><BR>-- <BR>Ceki<BR><a href="http://twitter.com/#!/ceki" target=_blank >http://twitter.com/#!/ceki</a><BR><BR>On 08.06.2012 20:12, Yura Levandovskyy wrote:<BR>> Hello,<BR>><BR>> I'm trying to configure a naming scheme that would result in longs in<BR>> the format of %d{yyyy-MM-dd-HHmm}.%i.log, however the time should<BR>> indicate log creation time, not current time.<BR>><BR>> New log is created in 2 situations: on application launch<BR>> <rolloverOnStart>true</rolloverOnStart> or <maxFileSize>1MB</maxFileSize>.<BR>><BR>> However, because of the naming format, the log gets put in a different<BR>> location every minute. Is there a way to only set the log name
on<BR>> creation and then write to it until next rollover?<BR>><BR>> Thank you<BR>><BR>><BR><BR>_______________________________________________<BR>Logback-user mailing list<BR><a ymailto="mailto:Logback-user@qos.ch" href="mailto:Logback-user@qos.ch">Logback-user@qos.ch</a><BR><a href="http://mailman.qos.ch/mailman/listinfo/logback-user" target=_blank >http://mailman.qos.ch/mailman/listinfo/logback-user</a><BR><br><br> </div> </div>