[logback-user] Config file failures unexplained in list or JIRA

RobOaks roboaks at comcast.net
Tue Nov 27 21:24:59 CET 2012


Anyone? It would be so helpful to know whether these features have been
deprecated, I've encountered recently introduced defects,  or whether I'm
just doing something wrong. I'm hoping for the latter. 


RobOaks wrote:
> 
> I am encountering several initialization errors with the logback.xml file
> (below) that do not seem to be addressed in either this mailing list or
> JIRA. I am running Logback 1.0.7 with SLF4J 1.7.2. 
> 
> During initialization I receive the following Logback errors:
> 1. No applicable action for [outputPatternAsHeader]. Try as I might, I can
> not get Logback to recognize this property.
> 2. No applicable action for [immediateFlush]. This error may be expected,
> as I was able to glean from the list and JIRA that this property has been
> eliminated. Please confirm.
> 3. no applicable action for [withJansi] / There is no conversion class
> registered for composite conversion word [highlight]. I am including
> jansi-1.8.jar in the classpath but, obviously, this wouldn’t even come
> into play if withJansi isn’t even recognized.
> 4. Could not find Janino library on the class path. Skipping conditional
> processing. Both commons-compiler.jar and janino.jar 2.6.1 are on the
> classpath. I understand that there are potential issues with the use of
> conditional processing because of Janino and I’m wondering if I should
> abandon this feature, though it makes the config file significantly more
> elegant.
> 
> Here is the config file:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <configuration debug="true">
> 	<property name="rootLevel" value="DEBUG"/>
> 	<property name="deployment" value="DEV"/>
> 	<property name="logFileFolder" value="c:/tmp/its"/>
> 	<property name="logFileName" value="Idcp"/>
> 	<property name="baseLayoutPattern" value="%logger{}.%method - %msg%n"/>
> 	<property name="fileLayoutPattern" value="%-5level
> ${baseLayoutPattern}"/>
> 	<property name="consoleLayoutPattern" value="%highlight(%-5level)
> ${baseLayoutPattern}"/>
> 	<property name="flowRowLayoutPattern" value="%msg%n"/>
> 	<property name="rollingPolicyPattern"
> value="${logFileFolder}/%d{yyyy-MM-dd}--${logFileName}.log"/>
> 	<property name="rollingPolicyMaxHistory" value="7"/>
> 	<!-- General purpose file appender -->
> 	<appender name="file"
> class="ch.qos.logback.core.rolling.RollingFileAppender">
> 		<file>${logFileFolder}/${logFileName}.log</file>
> 		<rollingPolicy
> class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
> 			<fileNamePattern>${rollingPolicyPattern}</fileNamePattern>
> 			<maxHistory>${rollingPolicyMaxHistory}</maxHistory>
> 		</rollingPolicy>
> 		<encoder>
> 			<pattern>${fileLayoutPattern}</pattern>
> 			<!-- this quadruples logging throughput -->
> 			<immediateFlush>false</immediateFlush>
> 			<outputPatternAsHeader>true</outputPatternAsHeader>
> 		</encoder>
> 	</appender>
> 	<!-- Flow row file appender -->
> 	<appender name="fileFlowRow"
> class="ch.qos.logback.core.rolling.RollingFileAppender">
> 		<file>${logFileFolder}/${logFileName}.log</file>
> 		<rollingPolicy
> class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
> 			<fileNamePattern>${rollingPolicyPattern}</fileNamePattern>
> 			<maxHistory>${rollingPolicyMaxHistory}</maxHistory>
> 		</rollingPolicy>
> 		<encoder>
> 			<pattern>${flowRowLayoutPattern}</pattern>
> 			<!-- this quadruples logging throughput -->
> 			<immediateFlush>false</immediateFlush>
> 			<outputPatternAsHeader>true</outputPatternAsHeader>
> 		</encoder>
> 	</appender>
> 	<!-- General console appender -->
> 	<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
> 		<withJansi>true</withJansi>
> 		<encoder>
> 			<pattern>${consoleLayoutPattern}</pattern>
> 		</encoder>
> 	</appender>
> 	<!-- Flow row console appender -->
> 	<appender name="consoleFlowRow"
> class="ch.qos.logback.core.ConsoleAppender">
> 		<encoder>
> 			<pattern>${flowRowLayoutPattern}</pattern>
> 		</encoder>
> 	</appender>
> 	<!-- Flow row logger -->
> 	<logger name="idcpFlowRow" level="INHERITED">
> 		<appender-ref ref="fileFlowRow"/>
> 		<if condition='!property("deployment").contains("PROD")'>
> 			<then>
> 				<appender-ref ref="consoleFlowRow"/>
> 			</then>
> 		</if>
> 	</logger>
> 	<!-- Root logger only sets level -->
> 	<root level="${rootLevel}">
> 		<appender-ref ref="file"/>
> 		<if condition='!property("deployment").contains("PROD")'>
> 			<then>
> 				<appender-ref ref="console"/>
> 			</then>
> 		</if>
> 	</root>
> </configuration>
> 
> If I did something stupid or missed an explanation of these failures in
> the list, I apologize in advance.
> 
> Thanks for your help.
> 

-- 
View this message in context: http://old.nabble.com/Config-file-failures-unexplained-in-list-or-JIRA-tp34713039p34729410.html
Sent from the Logback User mailing list archive at Nabble.com.



More information about the Logback-user mailing list