james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joachim Draeger ...@joachim-draeger.de>
Subject Re: (JDBC)MailRepository and locking
Date Tue, 06 Jun 2006 18:43:40 GMT
Hi Stefano,

Stefano Bagnara schrieb:

> I think that we should discuss only of SpoolRepositories because 
> MailRepository should be deprecated in favor of a new MessageRepository 
> with different concepts.

I'm not familiar with James spooling. For the MessageRepository: Maybe it should 
get a long without locks and threads should wait for internal operations, on the 
same message, to complete.
- remove() waits until all concurrent retrieve/store operations have finished 
but new attempts will fail.
- store() waits until running retrieve operations have finished and new retrieve 
attempts wait for that store();
Just like a queue. Maybe it gets sorted and maybe multiple removes get sorted 
out. Okay, maybe it's too complicated. :-) But for the "client" it would be much 
easier, it can trust that his operation will succeed.


Joachim

---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message