示例#1
0
        private void OnSessionFaulted(object sender, SessionFaultedEventArgs e)
        {
            var sessionId = (Guid)e.Context.Properties[SmtpServerConstants.SessionId];

            this._logger.LogDebug($"Session with id {sessionId} faulted with: {e.Exception.Message}");

            e.Context.Properties.Remove(SmtpServerConstants.Scope);
        }
 private void SmtpServer_SessionFaulted(object sender, SessionFaultedEventArgs e)
 {
     this.logger.LogError($"Session Faulted. Properties: {String.Join(", ", e.Context?.Properties?.Select(x => x.Key) ?? Enumerable.Empty<string>())}");
     this.logger.LogError(e.Exception?.ToString());
 }
示例#3
0
 static void OnSessionFaulted(object sender, SessionFaultedEventArgs e)
 {
     Console.WriteLine("SessionFaulted: {0}", e.Context.Properties[EndpointListener.RemoteEndPointKey]);
     Console.WriteLine(e.Exception.Message);
 }
 static void OnSessionFaulted(object sender, SessionFaultedEventArgs e)
 {
     Console.WriteLine("Session Faulted: {0}", e.Exception);
 }
示例#5
0
 void OnSessionFaulted(object sender, SessionFaultedEventArgs e)
 {
     _log.Trace(e.Exception, "Session faulted");
 }