Friday, May 18, 2012
 
The best way to analyze your logs! Minimize
 Log4Net Mail archive   

The Log4Net mailing list is a great source of information about using log4Net, in this forum we collect all the messages in the log4net user list and some selected threads from the developer list.

Subject: Problems with NUnit and log4net
Prev Next
You are not authorized to post a reply.

Author Messages
Chris Smith

09/16/2008 11:05 AM  

Hi,

We are using log4net in conjunction with NUnit and MSBuild.

We are testing a cache implementation which requires the usage of
log4net and Common Logging (from the Spring Framework).

When running unit tests, each invocation of a test case which causes a
log entry to be created in turn causes log4net to blow up on the trace
with the following:

log4net:ERROR [TraceAppender] Failed in DoAppend
System.Threading.ThreadAbortException: Thread was being aborted.
   at
System.Diagnostics.StackTrace.GetStackFramesInternal(StackFrameHelper
sfh, Int32 iSkip, Exception e)
   at System.Diagnostics.StackTrace.CaptureStackTrace(Int32 iSkip,
Boolean fNeedFileInfo, Thread targetThread, Exception e)
   at log4net.Core.LocationInfo..ctor(Type
callerStackBoundaryDeclaringType)
   at log4net.Core.LoggingEvent.get_LocationInformation()
   at
log4net.Layout.Pattern.MethodLocationPatternConverter.Convert(TextWriter
writer, LoggingEvent loggingEvent)
   at log4net.Layout.Pattern.PatternLayoutConverter.Convert(TextWriter
writer, Object state)
   at log4net.Util.PatternConverter.Format(TextWriter writer, Object
state)
   at log4net.Layout.PatternLayout.Format(TextWriter writer,
LoggingEvent loggingEvent)
   at log4net.Appender.AppenderSkeleton.RenderLoggingEvent(TextWriter
writer, LoggingEvent loggingEvent)
   at log4net.Appender.AppenderSkeleton.RenderLoggingEvent(LoggingEvent
loggingEvent)
   at log4net.Appender.TraceAppender.Append(LoggingEvent loggingEvent)
   at log4net.Appender.AppenderSkeleton.DoAppend(LoggingEvent
loggingEvent)

Can anyone explain this at all, as I don't know log4net internals at
all?  It is currently causing our build to fail as MSBuild interprets
this as a failure condition.

Many Thanks,

Chris Smith
http://www.intelliflo.com/

You are not authorized to post a reply.
Forums > Log4Net > Log4Net Mail archive > Problems with NUnit and log4net



ActiveForums 3.7

 

 

 

 

 

 

 

 

Log4Net Dashboard

Log analysis and monitoring made easy!

Log4Net Dashboard is a log viewer that can read log statements from a variety of logging output targets.

You can download a free developer version.

  

Check it out!

On the demonstration site you can try it  with live data.demo.l4ndash.com - Try Log4Net Dashboard with live data

The mail archive is a copy of all the mail sent to the mail address: log4net-user@logging.apache.org, organized as a forum.

If you would like to participate in the mail list, send a mail to log4net-user-subscribe@logging.apache.org.

More information about the mailing list is available on: http://logging.apache.org/log4net/support.html

 

A complete topic list is available and can be viewed here (warning, it takes some time to load)

 

Copyright 2005-2008 by FaktNet AS Terms Of Use Privacy Statement