logging-log4net-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nicko Cadell" <ni...@neoworks.com>
Subject RE: Error using RemotingAppender: can't find assembly log4net
Date Wed, 08 Dec 2004 19:18:17 GMT
It looks like the exception is being generated by the remoting server in
the ObjectReader.Deserialize methods. This is then being thrown back to
the client.

How have you setup the remoting server listening on 8085?

Nicko 

> -----Original Message-----
> From: Simon Wallis [mailto:mailing@wallis.ca] 
> Sent: 08 December 2004 19:08
> To: log4net-user@logging.apache.org
> Subject: Error using RemotingAppender: can't find assembly log4net
> 
> Hi, I'm trying to use the RemotingAppender. I got the client 
> and server sample code working fine. Now I'm trying to use 
> the appender in my own code but I'm getting an error that I 
> can't figure out. When I run my own app (acting as the 
> client) I see this stack trace in DebugView:
> 
> [9596] log4net:ERROR [RemotingAppender] Failed in DoAppend 
> [9596] System.Runtime.Serialization.SerializationException: 
> Cannot find the assembly log4net, Version=1.2.0.30714, 
> Culture=neutral, PublicKeyToken=9be3b600b03054c9. 
> [9596]
> [9596] Server stack trace: 
> [9596]    at 
> System.Runtime.Serialization.Formatters.Binary.BinaryAssemblyI
> nfo.GetAssembly() 
> [9596]    at 
> System.Runtime.Serialization.Formatters.Binary.ObjectReader.Ge
> tType(BinaryAssemblyInfo assemblyInfo, String name) 
> [9596]    at 
> System.Runtime.Serialization.Formatters.Binary.BinaryConverter
> .TypeFromInfo(BinaryTypeEnum binaryTypeEnum, Object 
> typeInformation, ObjectReader objectReader, 
> BinaryAssemblyInfo assemblyInfo, InternalPrimitiveTypeE& 
> primitiveTypeEnum, String& typeString, Type& type, Boolean& 
> isVariant) 
> [9596]    at 
> System.Runtime.Serialization.Formatters.Binary.__BinaryParser.
> ReadArray(BinaryHeaderEnum binaryHeaderEnum) 
> [9596]    at 
> System.Runtime.Serialization.Formatters.Binary.__BinaryParser.Run() 
> [9596]    at 
> System.Runtime.Serialization.Formatters.Binary.ObjectReader.De
> serialize(HeaderHandler handler, __BinaryParser serParser, 
> Boolean fCheck, IMethodCallMessage methodCallMessage) 
> [9596]    at 
> System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
> .Deserialize(Stream serializationStream, HeaderHandler 
> handler, Boolean fCheck, IMethodCallMessage methodCallMessage) 
> [9596]    at 
> System.Runtime.Remoting.Channels.CoreChannel.DeserializeBinary
> RequestMessage(String objectUri, Stream inputStream, Boolean 
> bStrictBinding, TypeFilterLevel securityLevel) 
> [9596]    at 
> System.Runtime.Remoting.Channels.BinaryServerFormatterSink.Pro
> cessMessage(IServerChannelSinkStack sinkStack, IMessage 
> requestMsg, ITransportHeaders requestHeaders, Stream 
> requestStream, IMessage& responseMsg, ITransportHeaders& 
> responseHeaders, Stream& responseStream)
> [9596]
> [9596] Exception rethrown at [0]: 
> [9596]    at 
> System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(
> IMessage reqMsg, IMessage retMsg) 
> [9596]    at 
> System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(Messag
> eData& msgData, Int32 type) 
> [9596]    at 
> log4net.Appender.IRemoteLoggingSink.LogEvents(LoggingEvent[] events) 
> [9596]    at 
> log4net.Appender.RemotingAppender.SendBuffer(LoggingEvent[] events) 
> [9596]    at 
> log4net.Appender.BufferingAppenderSkeleton.Append(LoggingEvent
>  loggingEvent) 
> [9596]    at 
> log4net.Appender.AppenderSkeleton.DoAppend(LoggingEvent loggingEvent) 
> 
> 
> Here is my config:
> 
> <appender name="RemotingAppender" 
> type="log4net.Appender.RemotingAppender" >
> 	<sink value="tcp://localhost:8085/LoggingSink" />
> 	<lossy value="false" />
> 	<bufferSize value="1" />
> 	<onlyFixPartialEventData value="true" /> </appender>
> 
> As far as I can see, it is exactly the same as the client 
> sample code (except mine is not in the app's .config file), 
> yet the sample code works and mine doesn't. Other appenders 
> work with my code, just not the RemotingAppender.
> 
> Simon.
> 
> 

Mime
View raw message