---
Sorry I made a type in prev email
session.isIdle() always returns me false
---

Hi, folks, I found a weird problem that session.isIdle() always returns me
false even though there's no session read/write activitiies at all after a
long
time. My code excerpt is as follows. Thanks for comments.

* In the handler:

public void sessionCreated(IoSession session) throws Exception {

 session.setWriteTimeout(3);
 session.setIdleTime(IdleStatus.BOTH_IDLE, 3);
 session.setIdleTime(IdleStatus.WRITER_IDLE , 3);

}

* In a global static session table:

Clean up session when it is done:

...

if (session.isIdle(IdleStatus.WRITER_IDLE)) {
 // cleanup
 ...
 session.close();
}

...


But "isIdle()" always returns false even long after client
received all data.

Is this a bug in Mina or I missed something?


Thanks a bunch

Reply via email to