mox/imapserver
Mechiel Lukkien e943e0c65d
fix delay with propagating mailbox changes to other imap (idle) connections
when broadcasting a change, we would try to send the changes on a channel,
non-blocking. if we couldn't send (because there was no pending blocked
receive), we would wait until the potential receiver would explicitly request
the changes. however, the imap idle handler would not explicitly request the
changes, but do a receive on the changes channel. since there was no pending
blocked send on the channel, that receive would block. only when another event
would come in, would both the pending and the new changes be sent.

we now use a channel only for signaling there are pending changes. the channel
is buffered, so when broadcasting we can just set the signal by a non-blocking
send and continue with the next listener. the receiver will get the buffered
signal. it can then get the changes directly, but lock-protected.

found when looking at a missing/delayed new message notification in thunderbird
when two messages arrive immediately after each other. this doesn't fix that
problem though: it seems thunderbird just ignores imap untagged "exists"
messages (indicating a new message arrived) during the "uid fetch" command that
it issued after notifications from an "idle" command.
2023-07-23 15:28:37 +02:00
..
append_test.go implement storing non-system/well-known flags (keywords) for messages and mailboxes, with imap 2023-06-24 00:24:43 +02:00
authenticate_test.go support cram-md5 authentication for imap and smtp 2023-02-05 16:29:03 +01:00
copy_test.go improve training of junk filter 2023-02-11 23:00:12 +01:00
create_test.go mox! 2023-01-30 14:27:06 +01:00
delete_test.go only send \NonExistent for IMAP4rev2, and automatically subscribe to imported mailboxes 2023-02-17 18:35:11 +01:00
error.go for imap/smtp syntax errors, only echo the remaining buffer if the connection is authenticated 2023-03-10 11:32:34 +01:00
expunge_test.go mox! 2023-01-30 14:27:06 +01:00
fetch.go implement storing non-system/well-known flags (keywords) for messages and mailboxes, with imap 2023-06-24 00:24:43 +02:00
fetch_test.go mox! 2023-01-30 14:27:06 +01:00
fuzz_test.go unbreak the subcommands that talk to the mox instance of the ctl socket 2023-06-16 13:27:27 +02:00
idle_test.go mox! 2023-01-30 14:27:06 +01:00
list.go mox! 2023-01-30 14:27:06 +01:00
list_test.go mox! 2023-01-30 14:27:06 +01:00
lsub_test.go mox! 2023-01-30 14:27:06 +01:00
move_test.go mox! 2023-01-30 14:27:06 +01:00
pack.go add two new log levels for tracing sensitive auth protocol messages, and bulk data messages 2023-02-03 20:33:19 +01:00
parse.go fix two parsing bugs in imapserver 2023-06-28 19:41:58 +02:00
prefixconn.go mox! 2023-01-30 14:27:06 +01:00
protocol.go fix bug in imapserver with matching if a uid is in a uidset 2023-06-29 21:37:17 +02:00
protocol_test.go fix bug in imapserver with matching if a uid is in a uidset 2023-06-29 21:37:17 +02:00
rename_test.go fix bug in imapserver with rename of inbox, and add consistency checks 2023-06-30 17:19:29 +02:00
search.go implement storing non-system/well-known flags (keywords) for messages and mailboxes, with imap 2023-06-24 00:24:43 +02:00
search_test.go fix two parsing bugs in imapserver 2023-06-28 19:41:58 +02:00
selectexamine_test.go implement storing non-system/well-known flags (keywords) for messages and mailboxes, with imap 2023-06-24 00:24:43 +02:00
server.go fix delay with propagating mailbox changes to other imap (idle) connections 2023-07-23 15:28:37 +02:00
server_test.go fix two parsing bugs in imapserver 2023-06-28 19:41:58 +02:00
starttls_test.go mox! 2023-01-30 14:27:06 +01:00
status_test.go mox! 2023-01-30 14:27:06 +01:00
store_test.go implement storing non-system/well-known flags (keywords) for messages and mailboxes, with imap 2023-06-24 00:24:43 +02:00
subscribe_test.go mox! 2023-01-30 14:27:06 +01:00
unselect_test.go mox! 2023-01-30 14:27:06 +01:00
unsubscribe_test.go mox! 2023-01-30 14:27:06 +01:00
utf7.go mox! 2023-01-30 14:27:06 +01:00
utf7_test.go mox! 2023-01-30 14:27:06 +01:00