james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stefano Bagnara" <apa...@bago.org>
Subject Re: need suggestions for JAMES fast fail optimization
Date Wed, 03 Aug 2005 14:44:06 GMT
> I am thinking of having one set of SMTPSession and all the 
> CommandHandler objects created and configured at the start up 
> in SMTPServer. These will cloned and handed over whenever 
> SMTP session objects are needed for the actual protocol session.
> Would like to know if there is a better technique to
> a) keep the commandhandler specific configuration parsing 
> code encapsulated.
> b) not to parse the XML configuration every time 
> CommandHandler object is created.

IMHO you should have a single set of command handlers (thread safe) for a
single smtpserver.
Cloning the whole command-handler stuff at every connection would be a
resource consuming task.

The Configuration should be passed to the command handlers when initialized
and not at every session.

This would be very similar to the current mailet processing: we have a set
of thread-safe mailets that are invoked for each MailImpl by different
threads. You will have a set of thread-safe commandhandler that are invoked
for each SMTPSession by different threads.

Does this make sense?


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

View raw message