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 regression in 4.1.10.0-RELEASE #243

Closed
ianmcorvidae opened this issue Apr 12, 2017 · 10 comments
Closed

Performance regression in 4.1.10.0-RELEASE #243

ianmcorvidae opened this issue Apr 12, 2017 · 10 comments
Assignees

Comments

@ianmcorvidae
Copy link
Contributor

Hi; we (CyVerse) recently attempted to upgrade from 4.0.2.6-RELEASE to 4.1.10.0-RELEASE, and saw pretty dramatic performance degradation. After a lot of digging and some git bisecting, a52751e is the first commit with the issue. Specifically, commenting out the flush in https://github.com/DICE-UNC/jargon/blob/4.1.10.0-RELEASE/jargon-core/src/main/java/org/irods/jargon/core/connection/AbstractConnection.java#L431 (which, by the time of the release, is what's used by sendHeader -- see https://github.com/DICE-UNC/jargon/blob/4.1.10.0-RELEASE/jargon-core/src/main/java/org/irods/jargon/core/connection/IRODSMidLevelProtocol.java#L326) fixes the issue -- it seems that iRODS dislikes it when you flush the 4-byte header size without the rest of the header following it, and for some reason this makes it so that when reading in the header size of the response, it takes much longer than usual to read the header of the response from iRODS (typically, but not always, 40ms instead of 2-7ms -- compounded across a number of messages send to iRODS in the context of a single request to our services, this caused a rapid increase in response times).

I'm not sure if simply removing the flush in sendInNetworkOrder is correct though, as that's used other places - in any case it appears that there should not be a flush between the 4-byte header size and the actual XML header of the message. Perhaps it should be possible to pass a parameter to sendInNetworkOrder which tells it not to do the flush() at the end?

Let me know if I can provide more information.

@michael-conway
Copy link
Collaborator

michael-conway commented Apr 12, 2017 via email

ianmcorvidae added a commit to cyverse-de/clj-jargon that referenced this issue Apr 12, 2017
@ianmcorvidae
Copy link
Contributor Author

That sounds reasonable to me. I'm hoping/assuming you have SSL-enabled servers to test against, since of course I only have ours! But I'm happy to test any proposed changes within our code/against our iRODS instances, of course.

@michael-conway
Copy link
Collaborator

michael-conway commented Apr 13, 2017 via email

@michael-conway
Copy link
Collaborator

Integrating into current jargon and testing....

@dkocher
Copy link
Contributor

dkocher commented Apr 19, 2017

Is this related to #234?

@ghost
Copy link

ghost commented Apr 19, 2017

@dkocher I think it is.

@michael-conway
Copy link
Collaborator

I think it is as well, but want to test further before I link the two. It has to do with behavior of iRODS (various releases) on the agent side and whether the flush() is necessary before sending headers. It is mixed in with the changes to support SSL.

I will likely do a point release with the SSL, the flush, and a few other fixes and make a pass at outstanding issues to see what I can fit in this week.

@ghost
Copy link

ghost commented May 2, 2017

Any updates on this issue?

@michael-conway
Copy link
Collaborator

michael-conway commented May 2, 2017 via email

@ghost
Copy link

ghost commented May 2, 2017

Great! I'll wait for a stable release candidate then.

ianmcorvidae added a commit to ianmcorvidae/clj-jargon that referenced this issue Oct 24, 2018
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

3 participants