[Dovecot] Auto create folder(s)
Charles Marcus
CMarcus at Media-Brokers.com
Wed Sep 26 23:49:58 EEST 2007
On 9/26/2007, Fábio M. Catunda (catunda at contactnet.com.br) wrote:
> >
> > Could it could be written to simply create the folder if the target
> folder doesn't exist (ie, if the initial save fails due to
> non-existent folder)? Then there would be no performance hit...
> >
> There will be a performance hit couse you have to check if the folder
> exists or not.
This is not good... but not what I wrote either.
I'm not a programmer, so this may not be possible, but...
What I wrote was, do NOT test BEFORE delivery is attempted - only create
the folder IF delivery attempt FAILS *DUE* to non-existent folder.
Ie:
Deliver to user+foo
Error: Folder 'foo' doesn't exist for user
Ok, Do: Create folder 'foo' for user
ReDo: Deliver to user+foo
Maybe this is not reliable - and if not, definitely shouldn't be done.
But if there is a way to catch the error 'destination folder doesn't
exist', then it would NOT be a performance hit, because no test is
performed, only an error handled differently.
Again, this may not be doable, if not, sorry for the noise...
--
Best regards,
Charles
More information about the dovecot
mailing list