<feed xmlns='http://www.w3.org/2005/Atom'>
<title>notmuch/lib/database.cc, branch 0.10_rc1</title>
<subtitle>thread-based email index, search, and tagging</subtitle>
<id>https://git.notmuchmail.org/git/notmuch/atom?h=0.10_rc1</id>
<link rel='self' href='https://git.notmuchmail.org/git/notmuch/atom?h=0.10_rc1'/>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/'/>
<updated>2011-11-14T21:10:58Z</updated>
<entry>
<title>Store "from" and "subject" headers in the database.</title>
<updated>2011-11-14T21:10:58Z</updated>
<author>
<name>Austin Clements</name>
<email>amdragon@MIT.EDU</email>
</author>
<published>2011-11-06T17:17:36Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=567bcbc294b3aed632d18eb22056840292bdeb1e'/>
<id>urn:sha1:567bcbc294b3aed632d18eb22056840292bdeb1e</id>
<content type='text'>
This is a rebase and cleanup of Istvan Marko's patch from
id:m3pqnj2j7a.fsf@zsu.kismala.com

Search retrieves these headers for every message in the search
results.  Previously, this required opening and parsing every message
file.  Storing them directly in the database significantly reduces IO
and computation, speeding up search by between 50% and 10X.

Taking full advantage of this requires a database rebuild, but it will
fall back to the old behavior for messages that do not have headers
stored in the database.
</content>
</entry>
<entry>
<title>lib/database.cc: use flush Xapian method instead of commit</title>
<updated>2011-11-02T23:38:22Z</updated>
<author>
<name>David Bremner</name>
<email>bremner@debian.org</email>
</author>
<published>2011-10-28T14:56:30Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=606e4461f803829077af4e3b2579583f7e39bc3e'/>
<id>urn:sha1:606e4461f803829077af4e3b2579583f7e39bc3e</id>
<content type='text'>
Apparently the method was renamed in Xapian 1.1.0 but the old method
name will stay around for a while. It seems better to stick with the
old name to make notmuch compile with older versions of Xapian, at
least for now.
</content>
</entry>
<entry>
<title>xutil.c: remove duplicate copies, create new library libutil.a to contain xutil.</title>
<updated>2011-10-31T02:09:49Z</updated>
<author>
<name>David Bremner</name>
<email>bremner@debian.org</email>
</author>
<published>2011-10-23T15:05:13Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=1dedfc90f6eee7cad10f1a1ceb39a7a1c4dbd1b1'/>
<id>urn:sha1:1dedfc90f6eee7cad10f1a1ceb39a7a1c4dbd1b1</id>
<content type='text'>
We keep the lib/xutil.c version. As a consequence, also factor out
_internal_error and associated macros.  It might be overkill to make a
new file error_util.c for this, but _internal_error does not really
belong in database.cc.
</content>
</entry>
<entry>
<title>lib: make find_message{,by_filename) report errors</title>
<updated>2011-10-04T04:55:29Z</updated>
<author>
<name>Ali Polatel</name>
<email>alip@exherbo.org</email>
</author>
<published>2011-10-04T04:55:29Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=02a30767116ad8abcbd0a3351f2e4d43bbbd655f'/>
<id>urn:sha1:02a30767116ad8abcbd0a3351f2e4d43bbbd655f</id>
<content type='text'>
Previously, the functions notmuch_database_find_message() and
notmuch_database_find_message_by_filename() functions did not properly
report error condition to the library user.

For more information, read the thread on the notmuch mailing list
starting with my mail "id:871uv2unfd.fsf@gmail.com"

Make these functions accept a pointer to 'notmuch_message_t' as argument
and return notmuch_status_t which may be used to check for any error
condition.

restore: Modify for the new notmuch_database_find_message()
new: Modify for the new notmuch_database_find_message_by_filename()
</content>
</entry>
<entry>
<title>lib: destroy message object after message removal</title>
<updated>2011-10-04T04:39:57Z</updated>
<author>
<name>Ali Polatel</name>
<email>alip@exherbo.org</email>
</author>
<published>2011-10-03T20:27:32Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=9b3f16ce715d2371224955bc5b6f948eaa4ee325'/>
<id>urn:sha1:9b3f16ce715d2371224955bc5b6f948eaa4ee325</id>
<content type='text'>
notmuch_database_remove_message() must call notmuch_message_destroy()
once it is done handling message removal.
</content>
</entry>
<entry>
<title>lib: Wrap notmuch_database_add_message in an atomic section.</title>
<updated>2011-09-24T23:00:28Z</updated>
<author>
<name>Austin Clements</name>
<email>amdragon@mit.edu</email>
</author>
<published>2011-06-11T04:42:58Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=51c3c0b2d27c8d0ba8e1ae242fd907c59f82d992'/>
<id>urn:sha1:51c3c0b2d27c8d0ba8e1ae242fd907c59f82d992</id>
<content type='text'>
Adding a message may involve changes to multiple database documents,
and thus needs to be done in a transaction.  This makes add_message
(and, I think, the whole library) atomicity-safe: library callers only
needs to use atomic sections if they needs atomicity across multiple
library calls.
</content>
</entry>
<entry>
<title>lib: Add an API to find a message by filename.</title>
<updated>2011-09-24T23:00:28Z</updated>
<author>
<name>Austin Clements</name>
<email>amdragon@mit.edu</email>
</author>
<published>2011-06-11T04:19:31Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=7a8046ced8c0e61ddd0ff463cfc17ed63e6edad3'/>
<id>urn:sha1:7a8046ced8c0e61ddd0ff463cfc17ed63e6edad3</id>
<content type='text'>
notmuch_database_find_message_by_filename is mostly stolen from
notmuch_database_remove_message, so this patch also vastly simplfies
the latter using the former.

This API is also useful in its own right and will be used in a later
patch for eager maildir flag synchronization.
</content>
</entry>
<entry>
<title>lib: Remove message document directly after removing the last file name.</title>
<updated>2011-09-24T01:50:39Z</updated>
<author>
<name>Austin Clements</name>
<email>amdragon@mit.edu</email>
</author>
<published>2011-06-11T04:07:54Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=bfe4555325086d5cb99e3962424128f94d1c921d'/>
<id>urn:sha1:bfe4555325086d5cb99e3962424128f94d1c921d</id>
<content type='text'>
Previously, notmuch_database_remove_message would remove the message
file name, sync the change to the message document, re-find the
message document, and then delete it if there were no more file names.
An interruption after sync'ing would result in a file-name-less,
permanently un-removable zombie message that would produce errors and
odd results in searches.  We could wrap this in an atomic section, but
it's much simpler to eliminate the round-about approach and just
delete the message document instead of sync'ing it if we removed the
last filename.
</content>
</entry>
<entry>
<title>lib: Add support for nested atomic sections.</title>
<updated>2011-09-24T01:50:38Z</updated>
<author>
<name>Austin Clements</name>
<email>amdragon@mit.edu</email>
</author>
<published>2011-06-11T03:35:06Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=e59cc0031fbf84f49e32dedb9927f427d2c49309'/>
<id>urn:sha1:e59cc0031fbf84f49e32dedb9927f427d2c49309</id>
<content type='text'>
notmuch_database_t now keeps a nesting count and we only start a
transaction or commit for the outermost atomic section.

Introduces a new error, NOTMUCH_STATUS_UNBALANCED_ATOMIC.
</content>
</entry>
<entry>
<title>lib: Add notmuch_database_{begin,end}_atomic.</title>
<updated>2011-09-24T01:50:38Z</updated>
<author>
<name>Austin Clements</name>
<email>amdragon@mit.edu</email>
</author>
<published>2011-01-29T16:25:24Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=957f1ba3fc1d737887029ff1787fc6bea94de00b'/>
<id>urn:sha1:957f1ba3fc1d737887029ff1787fc6bea94de00b</id>
<content type='text'>
These operations translate into non-flushed Xapian transactions,
allowing arbitrary groups of database operations to be performed
atomically.
</content>
</entry>
</feed>
