Re: [Dovecot] dsync-2.2.2 incorrectly synchronizes subscription status of deleted mailbox

2013-05-22 Thread Karol Jurak
On Wednesday 22 of May 2013 15:16:57 Timo Sirainen 
wrote:
> Another fix: 
http://hg.dovecot.org/dovecot-2.2/rev/33efc5396e44

Now it works as expected. Thanks.

However I discovered a similar issue when renaming a 
mailbox (using 33efc5396e44). After the first run of 
'doveadm sync' the old mailbox name remains 
subscribed on the second server and the new name is 
not subscribed there. Repeating the sync corrects this.


Re: [Dovecot] dsync-2.2.2 incorrectly synchronizes subscription status of deleted mailbox

2013-05-22 Thread Timo Sirainen
On Tue, 2013-05-21 at 15:58 +0200, Karol Jurak wrote:

> > Thanks, fixed: http://hg.dovecot.org/dovecot-2.2/rev/9878986a028d
> I performed the test and subscription state of a deleted mailbox is still
> incorrectly synchronized: the mailbox is being subscribed on the first
> server (the one it was originally deleted on) instead of being unsubscribed
> on the other. One thing changed however: a subsequent attempt to
> unsubscribe this mailbox on the first server is now correctly synchronized.
> Previously every attempt to unsubscribe a nonexistent mailbox was being
> reverted by dsync.

Another fix: http://hg.dovecot.org/dovecot-2.2/rev/33efc5396e44




Re: [Dovecot] dsync-2.2.2 incorrectly synchronizes subscription status of deleted mailbox

2013-05-21 Thread Karol Jurak
**

On Monday 20 of May 2013 17:33:44 Timo Sirainen wrote:

> On Mon, 2013-05-20 at 15:29 +0200, Karol Jurak wrote:

> > It seems that dsync-2.2.2 doesn't correctly synchronize subscription

> > status of a deleted mailbox.

>

> Thanks, fixed: http://hg.dovecot.org/dovecot-2.2/rev/9878986a028d



I performed the test and subscription state of a deleted mailbox is still
incorrectly synchronized: the mailbox is being subscribed on the first
server (the one it was originally deleted on) instead of being unsubscribed
on the other. One thing changed however: a subsequent attempt to
unsubscribe this mailbox on the first server is now correctly synchronized.
Previously every attempt to unsubscribe a nonexistent mailbox was being
reverted by dsync.



-- 

Karol Jurak


Re: [Dovecot] dsync-2.2.2 incorrectly synchronizes subscription status of deleted mailbox

2013-05-20 Thread Timo Sirainen
On Mon, 2013-05-20 at 15:29 +0200, Karol Jurak wrote:

> It seems that dsync-2.2.2 doesn't correctly synchronize subscription status
> of a deleted mailbox.

Thanks, fixed: http://hg.dovecot.org/dovecot-2.2/rev/9878986a028d

(The fixed dsync protocol is still compatible with the old dsync, but
the deleted mailbox subscription states aren't synced the same until
both run new ones.)




[Dovecot] dsync-2.2.2 incorrectly synchronizes subscription status of deleted mailbox

2013-05-20 Thread Karol Jurak

Hi,

It seems that dsync-2.2.2 doesn't correctly synchronize subscription status
of a deleted mailbox. The situation is as follows.

There are two servers: A and B, and a test user test_mdbox. Mailboxes 
(mdbox) of
this user on both servers are synchronized. Specifically on both of them 
there is

a Trash/x mailbox. Replication plugin is disabled.

I delete Thrash/x mailbox on A with Thunderbird. The relevant IMAP 
commands issued

are:

7187.06817610.4.0.1310.1.107.144IMAPRequest: 9 
delete "Trash/x"
7287.07223810.1.107.14410.4.0.13IMAPResponse: 9 OK 
Delete completed.
7387.07373610.4.0.1310.1.107.144IMAPRequest: 10 
unsubscribe "Trash/x"
7487.08526310.1.107.14410.4.0.13IMAPResponse: 10 OK 
Unsubscribe completed.


Inspecting output of 'doveadm mailbox list' and contents of 
subscriptions file
shows that everything is as expected, ie. mailbox was deleted and 
unsubscribed. Moreover

in dovecot.mailbox.log on A the following records appear:

#480: delete-mailbox 3f3eb117a51c9a51d828f671379f (2013-05-20 14:54:40)
#504: delete-dir f91e44cab57821aa456b525c7a2f1d7e (2013-05-20 14:54:40)
#528: unsubscribe f91e44cab57821aa456b525c7a2f1d7e (2013-05-20 14:54:40)

Subsequently I run 'doveadm sync -u test_mdbox -d'. It causes an entry 
for Thrash/x
to reappear in subscriptions file on both servers and the following 
records are

appended to dovecot.mailbox.log on B:

#2112: delete-mailbox 3f3eb117a51c9a51d828f671379f (2013-05-20 14:55:49)
#2136: delete-dir f91e44cab57821aa456b525c7a2f1d7e (2013-05-20 14:55:49)

On A this record is added:

#552: subscribe f91e44cab57821aa456b525c7a2f1d7e (2013-05-20 14:55:49)

So, in described situation, dsync subscribes a mailbox on a server it 
was deleted on

instead of unsubscribing it on the other one.

--
Karol Jurak