+1 vote
by (130 points)

we have a Mitel application that is using Rebex to send emails via EWS and see intermittent issues where emails get sent multiple time

can someone help me to get an idea of what this log entry might mean as we've drawn a blank from Mitel support at the moment

Info: 2020-Dec-02 12:40:33.646 Mail Message From address for conversation xyALtu is info@bandce.co.uk using Smtp Server [igniteinfo@bandce.co.uk] (e92e1dbe-2205-4c41-8aeb-25b4327e468d) (Storage.Mailer.Mailer)
Info: 2020-Dec-02 12:40:33.647 Sending Email xyALtu using EWS... Server: outlook.office365.com, Port: 443, SSL: info@bandce.co.uk;resolutions@bandce.co.uk, SMTP Auth: True for User: SVCIGNITEMAIL@bandce.co.uk (Storage.EmailService.EmailEWSConnection)
Info: 2020-Dec-02 12:40:33.647 Attempting EWS connection for sending to IP: outlook.office365.com; Port: 443; Security: Implicit (Storage.EmailService.EmailEWSConnection)
Error: 2020-Dec-02 12:40:33.685 !! UnknownRev ()
Error: 2020-Dec-02 12:40:34.837 Exception occured while processing new outbox item 'xyALtu':
--- Start Exception Stack ---
Rebex.Net.EwsException: Error while executing request. ---> Rebex.Net.EwsException: Error while executing request. ---> Rebex.Net.HttpException: Response reading timeout.
at Rebex.Net.SocketReader.dtbv(Byte[] pv, Int32 pw, Int32 px)
at Rebex.Net.SocketReader.dtbx(Int32 pz)
at Rebex.Net.SocketReader.Read()
at System.IO.TextReader.ReadLine()
at Rebex.Net.HttpClientResponse.rcuw(SocketReader nq, iaqd nr)
at iaqd.apub()
at iaqd.apuc()
at pgwu.Invoke[T](String methodName, Object arg)
--- End of inner exception stack trace ---
at pgwu.Invoke[T](String methodName, Object arg)
at Rebex.Net.Ews.hafz(EwsFolderId n, Byte[] o, MessageDispositionType p)
at Rebex.Net.Ews.dumb.xwcb()
at Rebex.Net.Ews.hagq[d](String ar, Func1 as, duks at) --- End of inner exception stack trace --- at Rebex.Net.Ews.hagq[d](String ar, Func1 as, duks at)
at Storage.EmailService.EmailEWSConnection.Send(MailMessage mailMessage, String conversationId, Boolean disableRebexSmtpPipliningAndChunking)
at Storage.Mailer.Mailer.SendMail(SearchResultsItem searchResultsItem, String filePath)
at Storage.Mailer.Mailer.b__6(SearchResultsItem newOutboxItem)
--- End Exception Stack ---
(Storage.Mailer.Mailer)

Applies to: Rebex Secure Mail

1 Answer

0 votes
by (15.2k points)

Hi,

The log indicates that receiving response when your application sends an email is not received in time as you can read on this line

Rebex.Net.HttpException: Response reading timeout.

It seems that when an error occur in your application's send mail logic, next attempt sends the same mail again.

by (130 points)
thanks Pavel,
that's exactly what we're seeing and believed was happening
the challenge is to find the timer that is expiring to see if it can be extended
by (15.2k points)
The odd thing is that the response reading timeout occur one second after what seems to be a connect to office 365 server. Ususally, timeout is set to 60 seconds at least. If you have control over our component in your application,  see if you can set Ews.Timeout property to a bigger value. Our default is 2 minutes (120 seconds). This property is set in miliseconds, so the actual default value is 120000.
by (130 points)
thanks

we see the successful emails complete in less than a second and the failed ones just over a second

I'll see if I can find our timer that corresponds  to Ews.Timeout
...