hu_yang3000 mentions 100%  CPU usage.  That sounds like a bug.  perhaps a
test case of some sort would be appropriate?  I am just starting with mina
so I don't know the way things work around this project.

Claude

On Fri, Jun 10, 2016 at 6:26 AM, Emmanuel Lécharny <elecha...@gmail.com>
wrote:

> Le 10/06/16 à 03:13, 胡阳 a écrit :
> > apache-mina-2.0.13-src
> > HI:
> > At org.apache.mina.core.polling.AbstractPollingIoProcessor class line
> 1069,when selected is zero We have to destroy the selector, and register
> all the socket on a new one to fix 100%  CPU bug. I think there has many
> case what the Selector is zero. The Channel has some data that be not
> readed, or the Iterator of selector.keys() not to be cleared. May be at
> line 1094 "if (selected > 0)" changed to "if (selected >= 0)" is better ?
> > Sorry, my english is very bad.
> >
> We don't delete the selector because the select() returns 0. We do that
> when the select returns 0 before the timeout (1000ms) is reached. If you
> try to delete the selector using a condition like (selected >= 0), you
> will trash the selector way more than necessary.
>
>


-- 
I like: Like Like - The likeliest place on the web
<http://like-like.xenei.com>
LinkedIn: http://www.linkedin.com/in/claudewarren

Reply via email to