[jcifs] speed writing to a file?
mballen at erols.com
Sat Nov 17 07:55:41 EST 2001
On Fri, 16 Nov 2001 15:17:58 -0500
Frank Xia <FXia at esri.com> wrote:
> Thanks for your response. I cut and paste my testing results here for your
> jCIFS time (ms) File system time (ms) (\\desktop2\public)
> 501 60
> 511 50
> 481 90
> 500 60
> 500 90
> 461 80
> 491 50
> 491 100
> 491 60
> 451 60
I think this might be including some startup costs. Even though your
not counting VM startup it's likely you're counting negotiation/session
setup/tree connect etc. In practice you're connection would be cached and
all files written after the first should be considerably faster. To test
just the file transfer itself, put in an exists() before you calculate the
initial start time. In the steady state jCIFS times should be comparable.
> To local disk
> jICFS time (ms)
This is a 6 second name service timeout. The time is really 459ms. Use
wins, change the resolve order or use the proper netbios name.
> Please note that I was running the testing in a laptop that writes to a
> desktop in the same network segment. Both machines are running Windows 2000.
> Of course, I didn't change any default settings since I just started to play
> with it and not aware of how to do it yet. My part of the application will
> mostly generate small JEPG/PNG etc image files (we do have other part of the
> application will read much bigger files from disk). I am using
> System.currentTimeMIllis() method to get the time before and after the
> method call to generateJPEGSmb().
I was only suggesting you use bigger files to get more accurate values
for write throughput. If your application is multi-threaded I would not
be surprised if jCIFS was considerably faster than Windows regardless
of what the size of your files are.
PS: I just released jcifs-0.6b which might improve your results a little
(but at this point only jcifs-0.5.1 should be used in production).
More information about the jcifs