Timo Sirainen [Wed, 19 Aug 2015 10:41:54 +0000 (13:41 +0300)]
lib: kqueue notification should trigger also on file renames.
For example if dovecot.index.log is renamed to dovecot.index.log.2, we
should notice that since there's now a new dovecot.index.log containing new
changes.
Timo Sirainen [Wed, 19 Aug 2015 09:56:55 +0000 (12:56 +0300)]
lib-storage: Moved most of the \Recent flag handling code to mailbox-recent-flags.c
There are also some API changes, because functions were renamed and the
recent_* fields were moved to struct mailbox. I'm not aware of any plugins
using these though, except for index_mailbox_set_recent_seq() which for now
is kept as a backwards compatibility macro.
Stephan Bosch [Tue, 18 Aug 2015 20:02:01 +0000 (23:02 +0300)]
lib-http: client: Fixed handling of request timeout.
It was inappropriately active when the client needed to take action.
This showed particularly with large payloads sent using
http_client_request_send_payload().
Timo Sirainen [Tue, 18 Aug 2015 18:10:41 +0000 (21:10 +0300)]
lib-http: Previous test-http-client safe_memset() change broke in some systems.
Since there's no easy way to fix this in Makefile.am, just do it by actually
using safe_memset()..
Timo Sirainen [Tue, 18 Aug 2015 17:59:25 +0000 (20:59 +0300)]
lib-http: test-http-client may have failed to load SSL library plugin.
safe_memset() wasn't necessarily compiled into test-http-client. This is a
bit kludgy way of just adding it. Another possibility could have been to use
-Wl,--whole-archive with GNU ld, but it's a bit tricky here.
Stephan Bosch [Tue, 18 Aug 2015 17:39:24 +0000 (20:39 +0300)]
lib-http client: Removed useless assignment of request->authority in http_client_request_redirect().
It is assigned again in http_client_request_do_submit().
Timo Sirainen [Tue, 18 Aug 2015 17:23:45 +0000 (20:23 +0300)]
master: Changed passing of listener settings from master to process to be more flexible.
This is needed to allow adding new listener settings, such as `haproxy'.
Patch by Stephan Bosch - with some small changes.
Stephan Bosch [Mon, 15 Jun 2015 16:50:53 +0000 (18:50 +0200)]
lmtp, *-login: Use ip/port values from struct master_service_connection instead of from the socket.
This way, a proxy protocol like HAProxy can transparently override these
addresses with what is seen by the proxy.
Teemu Huovila [Mon, 17 Aug 2015 10:18:03 +0000 (13:18 +0300)]
lib-fts: Add Unicode TR29 rule WB5a setting to tokenizer.
Splits prefixing contracted words from base word.
E.g. "l'homme" -> "l" "homme". Together with a language specific stopword list
unnecessary contractions can thus be filtered away.
This is disabled by default and only works with the TR29 algorithm.
Enable by "fts_tokenizer_generic = algorithm=tr29 wb5a=yes"
Timo Sirainen [Mon, 17 Aug 2015 09:56:25 +0000 (12:56 +0300)]
indexer: Removed counting worker processes as service clients to prevent idle-kill.
lib-master handles this internally now. Also if the max client count was
reached, we assert-crashed:
Timo Sirainen [Mon, 17 Aug 2015 09:53:52 +0000 (12:53 +0300)]
lib-master: If idle-die callback returns FALSE, notify master that we don't want to die.
This avoids the master thinking that we're ignoring its idle-kill signal and
logging an error.
Timo Sirainen [Sun, 16 Aug 2015 11:07:21 +0000 (13:07 +0200)]
lib-fs: fs_write() didn't update stats.write_count correctly.
If backend implemented asynchronous write(), the write_count was updated multiple
times. If backend didn't implement write(), then it was counted twice.
Timo Sirainen [Sat, 15 Aug 2015 10:14:35 +0000 (12:14 +0200)]
dsync: Fixed syncing a recursive delete of mailbox with children.
For example if 1/2/3 exists in both sides and then 1/2/3, 1/2 and 1 are
deleted from one side, the next dsync would delete 1/2/3, but leave 1/2 and
1 undeleted.
Timo Sirainen [Wed, 12 Aug 2015 09:52:06 +0000 (12:52 +0300)]
pop3: Added pop3_delete_type setting with values "default", "expunge" or "flag".
This is related to pop3_deleted_flag setting. The main behefit here is that
you can now hide messages from POP3 by setting pop3_deleted_flag, but
without changing the actual deletion behavior by setting
pop3_delete_type=expunge.
Timo Sirainen [Fri, 7 Aug 2015 10:32:02 +0000 (13:32 +0300)]
fts-solr: "highest UID for mailbox" lookup was actually returning "highest UID for user"
If the default operator was OR instead of AND. This affected indexing mails
in newly created mailboxes.
Timo Sirainen [Thu, 6 Aug 2015 09:17:45 +0000 (12:17 +0300)]
stats: If process was used for multiple sessions, some of the fields weren't set correctly.
For example the second user's disk_output was increased at startup by the
same amount as what the previous user's last disk_output value was.
Timo Sirainen [Sun, 19 Jul 2015 07:57:26 +0000 (10:57 +0300)]
lib-storage: Fixed doing multiple changes via mailbox_attribute_set/unset()
Only the last change was committed and the earlier changes were just leaking
memory.
Timo Sirainen [Sat, 11 Jul 2015 09:16:56 +0000 (12:16 +0300)]
lib-storage: If mailboxes' vsizes are used, keep them updated also in mailbox list index.
This allows looking them up quickly without opening the actual mailbox
indexes.
Timo Sirainen [Sat, 11 Jul 2015 09:11:48 +0000 (12:11 +0300)]
lib-storage: Added MAILBOX_METADATA_PHYSICAL_SIZE
If backend always uses the same virtual and physical sizes, this is
implemented via the MAILBOX_METADATA_VIRTUAL_SIZE code. Otherwise it
searches all the messages and sums up their physical sizes.
Timo Sirainen [Fri, 3 Jul 2015 10:55:17 +0000 (13:55 +0300)]
quota: Even if quota counting fails, commit the mailbox transaction.
The only changes in the transaction are changes to dovecot.index.cache file
and we don't want to rollback those.
Timo Sirainen [Thu, 2 Jul 2015 09:06:04 +0000 (11:06 +0200)]
mdbox: Make sure rebuilding doesn't try to add a copy of the message too many times.
Currently it just silently overflowed the 16bit refcount, which caused
problems later.
Timo Sirainen [Tue, 30 Jun 2015 10:58:15 +0000 (13:58 +0300)]
doveadm: Added doveadm_username to specify the username for authentication.
The default is still "doveadm" and the server side doesn't currently support
anything except "doveadm".
Timo Sirainen [Tue, 30 Jun 2015 09:18:08 +0000 (12:18 +0300)]
istream filters: If parent's i_stream_stat() fails, copy the stream_errno.
This doesn't actually change any functionality yet, since most
i_stream_stat() callers aren't using i_stream_get_error().
Timo Sirainen [Tue, 30 Jun 2015 09:17:35 +0000 (12:17 +0300)]
lib: istream_file.stat() fails, set stream_errno and error string.
For now we'll also keep logging the error since everybody isn't using
i_stream_get_error().
Timo Sirainen [Tue, 23 Jun 2015 09:31:21 +0000 (11:31 +0200)]
lib-storage: Set MAILBOX_SELECT/NONEXISTENT for namespace prefix even if no flags are wanted.
This fixes doveadm commands attempting to access such nonexistent mailbox
prefixes.
Timo Sirainen [Wed, 17 Jun 2015 13:37:37 +0000 (16:37 +0300)]
fs-posix: Hide temporary files from fs_iter_*()
Those could exist just because another process is just using them to create
new files to the directory. Although they could also be older files caused
by earlier crashes. It would probably be a good idea to have fs_iter_*()
delete the old temporary files automatically.