Re: [Abook-devel] RFC: don't rewrite needlessly the database to disk

2014-05-08 Thread luc . linux
On Thu, May 08, 2014 at 02:17:07PM -0300, Raphaël Droz wrote: > Next I'd see a more robust way to handle concurrent write accesses to > datafile. I can think about file-lock and inotify and I'd rather want > to avoid any need of datafile "merge". I would think of an algorithm like : watch the addre

[Abook-devel] RFC: don't rewrite needlessly the database to disk

2014-05-08 Thread Raphaël Droz
Hi, attached is a tricky patch: It skip database rewrites to disk when no changes actually happened. The current issue is that there is no locking/notify mechanism for the database file and, especially if using autosave=true, multiple abook instances imply that "latest closed wins". Reproducer

Re: [Abook-devel] extend_index: why ratio preservation

2014-05-08 Thread luc . linux
On Wed, May 07, 2014 at 10:52:11PM -0300, Raphaël wrote: > On Fri, May 02, 2014 at 11:37:57PM +0200, luc.li...@mailoo.org wrote: > > patch that scale the size of the fields of the index to fill the whole > > terminal width, while keeping their respective size. > > All the additional complexity lie