On Wed, 31 Mar 2004, Joel Lucsy wrote: >Just for the record, for Windows machines, only NTFS v5 formatted >drives/partitions support sparse files. Windows 2000 or better are the >only ones supporting NTFS v5. This means Win9x and FAT32 drives under >2000/XP won't be able to use sparse files.
There are bigger problems anyway. A snapshot of all old data would be required to be maintained for all active readers, even if a write transaction has finished. Consider the scenario: - Reader begins a transaction to maintain a consistent snapshot of the database. Begins processing data. - Writer updates data in the database, thus writing redo data to it's journal. - Writer commits the journal, having finished it's update. - Database now contains the updated data. The reader's snapshot is no longer valid, unless any changed data is saved and maintained as long as the read transaction is open. SQLite would need to maintain a snapshot for each reader, with nothing but the filesystem to use for IPC. A difficult problem. A snapshot might be feasible to maintain from within the same process, but that would limit concurrent readers and writer to the same process. Given that the current journal is simply a snapshot of changes, we could maintain the existing main database format, and change handling of the journal to make it persistent for each read transaction. This gives us the benefit of the better performance the undo based journal gives us, rather than the redo based journal would give us (redo requires at least 1 read and 2 writes per page, undo requires 1 read and 1 write per page in commit.) > >Joel Lucsy > > > >Christian Smith wrote: > >>How about taking advantage of sparse files (most OS support sparse files) >>for the journal, and saving the redo pages in the new shadow file. Thus >>the burden of efficiently handling mapping is bumped down to the OS. >> > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > Christian -- /"\ \ / ASCII RIBBON CAMPAIGN - AGAINST HTML MAIL X - AGAINST MS ATTACHMENTS / \ --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]