You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I ran into an issue with JSch 0.2.19, running on OpenJDK 17.0.12 on RHEL 8, where file transfers were taking much longer than expected, with compression set to 6.
For example, I was seeing a 29mb file take 45 seconds to transfer. (This was both with the new JSch 0.2.19 default algorithms, and with the configuration updated to use older algorithms that were defaults in JSch 0.1.55.)
With no compression, a 41mb file took 931 ms to transfer.
Switching to com.jcraft.jsch.juz.Compression, a 43mb file took 683 ms to transfer.
Out of curiousity, I dropped in the jzlib 1.1.3 classes and tried some transfers, and the times were as fast as expected - a 35mb file took 724 ms.
I don't have long-running benchmarks to share, but I did see consistent performance to the examples above over multiple file transfers.
I was wondering if this is expected behavior with the com.jcraft.jsch.jzlib implementation, or if its a possible issue that could be addressed?
The text was updated successfully, but these errors were encountered:
I'm not surprised in the least that the JZlib implementation is slower: it is implemented via pure Java, while the java.util.zip implementation is a JNI based wrapper around native Zlib library.
If compression support is important to you and you don't mind that the java.util.zip implementation is not technically compliant to the SSH RFC standards, then you probably will want to use it in preference to the JZlib implementation.
Agreed, I'm not surprised that the JZlib implementation is slower - but I was surprised that the JZlib bundled with JSch is so much slower than the old JZlib 1.1.3.
I ran into an issue with JSch 0.2.19, running on OpenJDK 17.0.12 on RHEL 8, where file transfers were taking much longer than expected, with compression set to 6.
For example, I was seeing a 29mb file take 45 seconds to transfer. (This was both with the new JSch 0.2.19 default algorithms, and with the configuration updated to use older algorithms that were defaults in JSch 0.1.55.)
With no compression, a 41mb file took 931 ms to transfer.
Switching to com.jcraft.jsch.juz.Compression, a 43mb file took 683 ms to transfer.
Out of curiousity, I dropped in the jzlib 1.1.3 classes and tried some transfers, and the times were as fast as expected - a 35mb file took 724 ms.
I don't have long-running benchmarks to share, but I did see consistent performance to the examples above over multiple file transfers.
I was wondering if this is expected behavior with the com.jcraft.jsch.jzlib implementation, or if its a possible issue that could be addressed?
The text was updated successfully, but these errors were encountered: