19 Mar
2014
19 Mar
'14
5:12 p.m.
My current approach is to introduce a index version file .dovecot.index.version in each mailbox and hooks mailbox_allocated event via my own plugin. If the version file does not exist or exist but with version number which need to be upgraded, index files in that mailbox are removed. I also tried to hook mailbox_opened() event and found that event was too late (index was loaded already). The side effect of hooking mailbox_allocated is that the event fires not only by 'select' command. 'list' command can also trigger a lot of mailbox_allocated events. Are there any better hook points I can use for this purpose?
Thanks,