logging-log4net-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kumar.Velug...@ubs.com
Subject AdoNetAppender:
Date Thu, 18 May 2006 15:02:58 GMT

> Hi
> 
> I am trying to log messages to Oracle 9i database table 'Log". I am
> getting error while initializing AdoNetAppender...following is the
> log...
> 
> log4net:ERROR DOMConfigurator: Could not create Appender
> [AdoNetAppender_Oracle] of type [log4net.Appender.AdoNetAppender].
> Reported error follows.
> log4net:ERROR DOMConfigurator: Could not create Appender
> [AdoNetAppender_Oracle] of type [log4net.Appender.AdoNetAppender].
> Reported error follows.
> System.TypeLoadException: Could not load type
> log4net.Appender.AdoNetAppender from assembly log4net-net-1.1,
> Version=1.2.0.30316, Culture=neutral, PublicKeyToken=null.
>    at System.Reflection.Assembly.GetType(String name, Boolean
> throwOnError)
>    at log4net.helpers.SystemInfo.GetTypeFromString(Assembly
> relativeAssembly, String typeName, Boolean throwOnError)
>    at log4net.helpers.SystemInfo.GetTypeFromString(String typeName,
> Boolean throwOnError)
>    at
> log4net.Repository.Hierarchy.DOMHierarchyConfigurator.ParseAppender(Xm
> lElement appenderElement)
> log4net:ERROR DOMConfigurator: Appender named [AdoNetAppender_Oracle]
> not found.
> System.TypeLoadException: Could not load type
> log4net.Appender.AdoNetAppender from assembly log4net-net-1.1,
> Version=1.2.0.30316, Culture=neutral, PublicKeyToken=null.
>    at System.Reflection.Assembly.GetType(String name, Boolean
> throwOnError)
>    at log4net.helpers.SystemInfo.GetTypeFromString(Assembly
> relativeAssembly, String typeName, Boolean throwOnError)
>    at log4net.helpers.SystemInfo.GetTypeFromString(String typeName,
> Boolean throwOnError)
>    at
> log4net.Repository.Hierarchy.DOMHierarchyConfigurator.ParseAppender(Xm
> lElement appenderElement)
> log4net:ERROR DOMConfigurator: Appender named [AdoNetAppender_Oracle]
> not found.
> 
> 
> Configuration section ....
> 
> 	<appender name="AdoNetAppender_Oracle"
> type="log4net.Appender.AdoNetAppender">
> 		<connectionType
> value="System.Data.OracleClient.OracleConnection,
> System.Data.OracleClient, Version=1.0.5000.0, Culture=neutral,
> PublicKeyToken=b77a5c561934e089" />
> 		<connectionString value="data source=****.WORLD;User
> ID=****;Password=*****;" />
> 		<commandText value="INSERT INTO Log
> (Datetime,Thread,Log_Level,Logger,Message) VALUES (:log_date, :thread,
> :log_level, :logger, :message)" />
> 		<bufferSize value="128" />
> 		<parameter>
> 			<parameterName value=":log_date" />
> 			<dbType value="DateTime" />
> 			<layout type="log4net.Layout.RawTimeStampLayout"
> />
> 		</parameter>
> 		<parameter>
> 			<parameterName value=":thread" />
> 			<dbType value="String" />
> 			<size value="255" />
> 			<layout type="log4net.Layout.PatternLayout">
> 				<conversionPattern value="%thread" />
> 			</layout>
> 		</parameter>
> 		<parameter>
> 			<pParameterName value=":log_level" />
> 			<dbType value="String" />
> 			<size value="50" />
> 			<layout type="log4net.Layout.PatternLayout">
> 				<conversionPattern value="%level" />
> 			</layout>
> 		</parameter>
> 		<parameter>
> 			<parameterName value=":logger" />
> 			<dbType value="String" />
> 			<size value="255" />
> 			<layout type="log4net.Layout.PatternLayout">
> 				<conversionPattern value="%logger" />
> 			</layout>
> 		</parameter>
> 		<parameter>
> 			<parameterName value=":message" />
> 			<dbType value="String" />
> 			<size value="4000" />
> 			<layout type="log4net.Layout.PatternLayout">
> 				<conversionPattern value="%message" />
> 			</layout>
> 		</parameter>
> 	</appender>
> 		<!-- Setup the root category, add the aplenders and set
> the default level -->
> 		<root>
> 			<level value="ALL" />
> 			<appender-ref ref="AdoNetAppender_Oracle" />
> 			<appender-ref ref="RollingLogFile" />
> 		</root>
> 
> I greatly appreciate any feed back in rectifying this error. Do I need
> to explicitly activate options in the code?
> 
> Thanks,
> Kumar
> 

Mime
View raw message