bertjohnson/OpaqueMail

Very slow performance

batooo opened this issue · 4 comments

Why sending directly to SMTP (mailgun) is like 2 secound but proxing via OpaqueMail to Mailgun is like 15 seconds.

My config:
http://prntscr.com/ek1njm

Here is one log where timespan is 30 secounds to forward.
[3/14/2017 11:13:50 PM] 310f182d-7537-48df-ae78-d4f757b4ca92 2 VERBOSE Forwarding message from {xxxx} with subject {WP Mail SMTP: Test mail to xxxxx@yahoo.com} and size of {423}. [3/14/2017 11:14:20 PM] 310f182d-7537-48df-ae78-d4f757b4ca92 2 RAW C: Date: Tue, 14 Mar 2017 23:13:50 +0000

Also when i restart the service i`m always getting error:

CRITICAL Exception when starting proxy: A blocking operation was interrupted by a call to WSACancelBlockingCall

Then i need to do like STOP -> WAIT -> START the service.

Any suggestion?

Looking at source code, looks like you try to generate certificate even SMIMESign is False

ElapsedMilliseconds: 29502

http://prntscr.com/ek2ccg

Hi batooo, thanks for the report and for digging into the performance. You're right that the proxy was unnecessarily generating certificates even when S/MIME signing was disabled. That's now fixed in version 2.5.1, which should speed things up.

Regarding other factors of slow performance, I'm sure the proxy could be optimized significantly. Pull requests are welcome. Thanks.

Closing this since there are no specific bottlenecks identified. Feel free to reopen or submit pull requests. Thanks.