On May 15, 2006, at 5:41 PM, Robert Engels wrote:
As stated in the email, it is 3x faster reading from a Java local cache, then having Java go to the OS (where it may or may not be cached). It avoidsthe overhead/context switch into the OS.
I read that in the original mail, but your performance test is comparing against a RandomAccessFile, not the memory-mapped ByteBuffer than the MMapDirectory uses.
Having the NioFsDirectory keep a cache of the file contents inside of the JVM seems like a waste of memory, since you are duplicating what the OS is caching. Whereas the MMapDirectory, by mmap'ing the file, could directly link through to pages in the OS disk cache.
-pete -- [EMAIL PROTECTED] - http://fotap.org/~osi
smime.p7s
Description: S/MIME cryptographic signature