Sam, Do you see the same behaviour when using the RemotingAppender directly from .NET code, rather than through a COM wrapper? Have you tried running the remoting example client and server (examples\net\1.0\Remoting) as a stand-alone test?
Nicko > -----Original Message----- > From: Sam Smoot [mailto:[EMAIL PROTECTED] > Sent: 06 April 2005 20:30 > To: Log4NET User > Subject: RemotingAppender error when called through a VB6 wrapper? > > We've made a wrapper so we can use log4net in some older VB6 > apps like so: > > [Guid("8949D706-9D81-4e24-A0DF-FC42E50AEFD9")] > [ComVisible(true)] > [ClassInterface(ClassInterfaceType.AutoDispatch)] > public class Logger { > public Logger() {} > > public void Configure(string xmlConfigurationFilePath) { > > RemotingConfiguration.Configure(xmlConfigurationFilePath); > XmlConfigurator.ConfigureAndWatch(new > FileInfo(xmlConfigurationFilePath)); > } > > public void SetLogger(string loggerName) { > log = LogManager.GetLogger(loggerName); > } > > ILog log; > > public void LogDebug(string message) { > log.Debug(message); > } > > public void LogInfo(string message) { > log.Info(message); > } > > public void LogWarn(string message) { > log.Warn(message); > } > > public void LogError(string message) { > log.Error(message); > } > > public void LogFatal(string message) { > log.Fatal(message); > } > } > > A FileAppender works fine, but we're getting exceptions in > the RemotingAppender setup in the configuration file. Such as the > following: > > [4128] log4net:ERROR [RemotingAppender] Failed in > SendBufferCallback [4128] > System.Runtime.Remoting.RemotingException: Server encountered > an internal error. For more information, turn on > customErrors in the server's .config file. > [4128] > [4128] Server stack trace: > [4128] > [4128] > [4128] Exception rethrown at [0]: > [4128] at > System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage > reqMsg, IMessage retMsg) > [4128] at > System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& > msgData, Int32 type) > [4128] at > log4net.Appender.IRemoteLoggingSink.LogEvents(LoggingEvent[] > events) > [4128] at > log4net.Appender.RemotingAppender.SendBufferCallback(Object state) > [9532] Left. Enter HWND 2c0fba > [9532] Left. Enter HWND 210d56 > > Trying to log to our centralized log server; or the following > when trying a local instance of the log server (we tried > setting the TypeLevelFilters to Full, but no dice): > > [7812] log4net:ERROR [RemotingAppender] Failed in > SendBufferCallback [7812] System.ArgumentOutOfRangeException: > Ticks must be between DateTime.MinValue.Ticks and > DateTime.MaxValue.Ticks. > [7812] Parameter name: ticks > [7812] > [7812] Server stack trace: > [7812] at System.DateTime..ctor(Int64 ticks) > [7812] at > System.Runtime.Serialization.Formatters.Binary.__BinaryParser. ReadDateTime() > [7812] at > System.Runtime.Serialization.Formatters.Binary.__BinaryParser. ReadValue(InternalPrimitiveTypeE > code) > [7812] at > System.Runtime.Serialization.Formatters.Binary.MemberPrimitive > UnTyped.Read(__BinaryParser > input) > [7812] at > System.Runtime.Serialization.Formatters.Binary.__BinaryParser. ReadMemberPrimitiveUnTyped() > [7812] at > System.Runtime.Serialization.Formatters.Binary.__BinaryParser.Run() > [7812] at > System.Runtime.Serialization.Formatters.Binary.ObjectReader.De > serialize(HeaderHandler > handler, __BinaryParser serParser, Boolean fCheck, IMethodCallMessage > methodCallMessage) > [7812] at > System.Runtime.Serialization.Formatters.Binary.BinaryFormatter > .Deserialize(Stream > serializationStream, HeaderHandler handler, Boolean fCheck, > IMethodCallMessage methodCallMessage) > [7812] at > System.Runtime.Serialization.Formatters.Binary.BinaryFormatter > .UnsafeDeserialize(Stream > serializationStream, HeaderHandler handler) > [7812] at > System.Runtime.Remoting.Channels.CoreChannel.DeserializeBinary > RequestMessage(String > objectUri, Stream inputStream, Boolean bStrictBinding, TypeFilterLevel > securityLevel) > [7812] at > System.Runtime.Remoting.Channels.BinaryServerFormatterSink.Pro > cessMessage(IServerChannelSinkStack > sinkStack, IMessage requestMsg, ITransportHeaders > requestHeaders, Stream requestStream, IMessage& responseMsg, > ITransportHeaders& responseHeaders, Stream& responseStream) > [7812] [7812] Exception rethrown at [0]: > [7812] at > System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage > reqMsg, IMessage retMsg) > [7812] at > System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& > msgData, Int32 type) > [7812] at > log4net.Appender.IRemoteLoggingSink.LogEvents(LoggingEvent[] > events) > [7812] at > log4net.Appender.RemotingAppender.SendBufferCallback(Object state) > > Any ideas? >
