diff design.txt @ 26:71a9ba42cee8

Memory-mapped files for bigger files. Defect reading number of bytes greater than size of the buffer fixed
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Sun, 09 Jan 2011 15:59:54 +0100
parents da8ccbfae64d
children 565ce0835674
line wrap: on
line diff
--- a/design.txt	Thu Jan 06 04:45:40 2011 +0100
+++ b/design.txt	Sun Jan 09 15:59:54 2011 +0100
@@ -30,15 +30,12 @@
 +calculate sha1 digest for file to see I can deal with nodeid
 *.hgignored processing
 +Nodeid to keep 20 bytes always, Revlog.Inspector to get nodeid array of meaningful data exact size (nor heading 00 bytes, nor 12 extra bytes from the spec)
++DataAccess - implement memory mapped files, 
 
-DataAccess - collect debug info (buffer misses, file size/total read operations) to find out better strategy to buffer size detection.
-DataAccess - implement memory mapped files, compare performance.
+DataAccess - collect debug info (buffer misses, file size/total read operations) to find out better strategy to buffer size detection. Compare performance.
 delta merge
 Changeset to get index (local revision number)
 RevisionWalker (on manifest) and WorkingCopyWalker (io.File) talking to ? and/or dirstate 
-
-
-
  
 Status operation from GUI - guess, usually on a file/subfolder, hence API should allow for starting path (unlike cmdline, seems useless to implement include/exclide patterns - GUI users hardly enter them, ever)
 
@@ -58,4 +55,7 @@
 * NIO and mapped files - should be fast. Although seems to give less control on mem usage. 
 * Regular InputStreams and chunked stream on top - allocate List<byte[]>, each (but last) chunk of fixed size (depending on initial file size) 
 
-<<<<<
\ No newline at end of file
+<<<<<
+
+Tests:
+DataAccess - readBytes(length > memBufferSize, length*2 > memBufferSize) - to check impl is capable to read huge chunks of data, regardless of own buffer size
\ No newline at end of file