Knut Anders Hatlen wrote:
No, there's no way to do that currently. There is an old JIRA issue for
using memory mapped files (DERBY-262), but there hasn't been much
activity yet.

For databases, the problem with double caching has traditionally been
solved by disabling the cache for the file system on which the database
is stored (that is, enabling direct I/O on that file system). That is
however a solution that fits better for a dedicated database server than
for a (zero-admin) database embedded in a desktop application.

I think there is more to it than just disabling the page cache and using
memory mapped files. Some of the challenges I see are:
An easier target would be to use memory mapping for read only databases. There are a number of awkward issues with Java's memory mapping when the map is writable
E.g.:
http://bugs.sun.com/view_bug.do?bug_id=4724038

Mark Thornton

Reply via email to