Prabhu, You're right, NiFi has been using logback 1.1.3 for quite a while now. Looks like we need to investigate upgrading.
I created a JIRA to address this issue: https://issues.apache.org/jira/browse/NIFI-3699 On Wed, Apr 12, 2017 at 7:25 AM prabhu Mahendran <[email protected]> wrote: > For your information,I have try that same procedure in NiFi-1.1.1 also. > > In that also NiFi have logback-classic-1.1.3 and logback-core-1.1.3 jar > only present. > > In conf\logback.xml MaxFileSize and maxHistory in > *TimeBasedRollingPolicy* not work. > > > > On Wed, Apr 12, 2017 at 3:58 PM, prabhu Mahendran <[email protected] > > wrote: > > Jeff, > > Thanks for your mail. > > I need to use log back 1.1.7 in NiFi-0.6.1 . > > Can you suggest any way to change 1.1.3 into 1.1.7? > > On Wed, Apr 12, 2017 at 9:42 AM, Jeff <[email protected]> wrote: > > Hello Prabhu, > > I think you're running into a logback bug [1] that is fixed with 1.1.7. > Unfortunately, it looks like NiFi 0.6.1 is using logback 1.1.3. > > [1] https://jira.qos.ch/browse/LOGBACK-747 > > On Tue, Apr 11, 2017 at 8:37 AM prabhu Mahendran <[email protected]> > wrote: > > In NiFi-0.6.1 ,i have try to reduce size of nifi-app.log to be stored in > local directory. > > In that conf\logback.xml i have configured "MaxFileSize" to be 1MB.I think > this only stores nifi-app.log should be under 1 MB Size only.But it doesn't > do like that.It always store every logs. > > <appender name="APP_FILE" > class="ch.qos.logback.core.rolling.RollingFileAppender"> > <file>logs/nifi-app.log</file> > <rollingPolicy > class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> > <!-- > For daily rollover, use 'app_%d.log'. > For hourly rollover, use 'app_%d{yyyy-MM-dd_HH}.log'. > To GZIP rolled files, replace '.log' with '.log.gz'. > To ZIP rolled files, replace '.log' with '.log.zip'. > --> > > <fileNamePattern>./logs/nifi-app_%d{yyyy-MM-dd_HH}.%i.log</fileNamePattern> > <timeBasedFileNamingAndTriggeringPolicy > class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP"> > <maxFileSize>1MB</maxFileSize> > </timeBasedFileNamingAndTriggeringPolicy> > <!-- keep 30 log files worth of history --> > <maxHistory>1</maxHistory> > </rollingPolicy> > <encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder"> > <pattern>%date %level [%thread] %logger{40} %msg%n</pattern> > <immediateFlush>true</immediateFlush> > </encoder> > </appender> > > Now i need to set 1MB for size of an nifi-app.log. > > *How to set size for nifi-app.log?* > > > >
