This code is far from being optimized...
SMTPHandler smtpHandler = new SMTPHandler();
smtpHandler.setConfiguration(conf.getConfiguration("smtphandler"));
smtpHandler.setContext(context);
smtpHandler.setComponentManager(comp);
smtpHandler.init();
smtpHandler.parseRequest(s);
threadManager.execute(smtpHandler);
is really slow so I'm not very surprised it miss some connections.
What I was planning is a block implementing a generic recycle tech so
that it can recycle not only threads but even Composer Configurable
Services etc.
something like
pool = recycler.newPool(Object recyclable, Configuration recConfig,
ComponentManager recCM, int size)
so you can write
init {
smtpPool = recycler.newPool(new SMTPHandler(),smtpConf, comp, 50);
}
parseRequest {
smtpHandler = smtpPool.getRecyclable();
smtpHandler.parseRequest(s);
threadManager.execute(smtpHandler);
}
This is going to boost performance a lot. I'm just waiting for avalon's
patterns to be solid...
--
Federico Barbieri
<[EMAIL PROTECTED]>
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Archives: <http://www.mail-archive.com/james%40list.working-dogs.com/>
Problems?: [EMAIL PROTECTED]