Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Performance: imapnio spend most of its time filling stacktraces #119

Open
chibenwa opened this issue Apr 13, 2022 · 0 comments
Open

Performance: imapnio spend most of its time filling stacktraces #119

chibenwa opened this issue Apr 13, 2022 · 0 comments

Comments

@chibenwa
Copy link
Contributor

Description

An analysis of imapnio with a profiler showed most of its time is spent filling stack traces due to integer parsing.

Screenshot from 2022-04-13 09-18-51

The underlying IMAPResponse from javax.mail does an attempt to parse untagged responses under the format * NUMBER KEYWORD exemple * 36 EXISTS.

However some commands like LIST

Expected Behavior

Avoid filling this stacktrace.

Actual Behavior

Fills the stacktrace and spends a lot of time doing so (40% of CPU time dedicated to imapnio)

Possible Fix

It looks like overriding this behaviour in IMAPResponse not to be feasible (init method doing such a check is private)

Context

I am using imapnio to write an IMAP benchmarking tool: https://github.com/linagora/gatling-imap/ . As such, in order not to impact performance measurement low latencies are paramount on the injection side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant