Details
-
Bug
-
Status: Resolved
-
Blocker
-
Resolution: Fixed
-
None
-
None
-
None
Description
hi all,
recently I started some RM tests with the commons mail transport.
Mail transport listener runs in a timer task.
TimerTask timerTask = new TimerTask() {
@Override
public void run() {
workerPool.execute(new Runnable() {
public void run() {
if (state == BaseConstants.PAUSED) {
if (log.isDebugEnabled())
} else
{ poll(entry); } synchronized (entry) {
if (!entry.canceled)
}
}
});
}
};
entry.timerTask = timerTask;
timer.schedule(timerTask, pollInterval)
As I saw timer task only re activates only after earlier invocation finish. i.e after completing the message.
In RM inorder delivery case lets say we receive message number 2 before 1. then the initial thread does not return and
it can not receive the message number 1.
I tested this this the following sample.
TimerTask timerTask = new TimerTask(){
public void run() {
System.out.println("In the timer task");
try
catch (InterruptedException e)
{ e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates. } System.out.println("Going out of timer task");
}
};
Timer timer = new Timer("Testtimer");
timer.schedule(timerTask,0, 1000);
And I saw timer task does not run until it finishes the first task.
Can we start a new thread to each new message? That is how earlier SMTP transport had done that.
Attachments
Issue Links
- duplicates
-
SYNAPSE-434 Concurrency level provided by the mail and VFS transports listeners is insufficient
- Open