Re: Mina stop work cause by exception in OrderedThreadPoolExecutor.Worker.run()

2017-01-21 Thread Xu Congyuan
Thank you for coming back to me.

Please do that on your own time.

I just want to clear it out, but not an urgent cast. Take it easy please!

2017-01-19 17:10 GMT+08:00 Emmanuel Lécharny :

> Sorry, still stuck with day job :/  Will try to squeeze one hour out of
> my busy schedule to review your explaination.
>
>
> I also have to do a small experiment to reproduce the issue.
>
>
> Thanks for your patience !
>
>
> Le 17/01/2017 à 05:32, Xu Congyuan a écrit :
> > Dear all, Hope you are doing well.
> >
> > Please kindly advise if the problem I found is on processing. Any
> > informations , please feel free to let me know.
> >
> >
> >
> > 2017-01-13 9:12 GMT+08:00 Xu Congyuan :
> >
> >> Thanks for reply. Sorry for not clear it.
> >> Basically, we will get the number of idleWorkers 0 or more than 0,
> >> if idleWorkers = 0, that's meaning no work is idle, we should add
> workers
> >> if it's necessary;
> >> if idleWorkers > 0 , that's meaning there are idle works, no necessary
> to
> >> add workers.
> >> Do I get the point?
> >> Let's back to the original,  while the MINA starting. At this time, the
> >> num of idleWorker == 0, therefor we call addWorkerIfNecessary() method
> when
> >> task is coming, because of idleWorker == 0,  we do addWorker and
> increase
> >> the num of idle at line 259 (version 2.0.16). so idleWorker == 1 at this
> >> time, the first worker be fired and start running, we enter the infinite
> >> loop, and decrease the num of idleWorker to 0 at line 686(version
> 2.0.16),
> >> basically that's we expected, but there is exception throw by
> runTasks(),
> >> the finally code is executed at line 707,  and increase the idleWorker
> to 1
> >> again, the infinite 'for' loop drop out because we don't catch the
> >> exception, the outer try...finally code executed at line 712 removed the
> >> worker.
> >> Let's sort out ideas, by now,  the idleWorker == 1 and there is no
> worker
> >> is running, is right? so the mina fall into fake dead.
> >>
> >> Please let me know I did the right investigation.
> >>
> >>
> >> 2017-01-13 0:11 GMT+08:00 Emmanuel Lécharny :
> >>
> >>> Hi !
> >>>
> >>>
> >>> sorry for the delayed response, was busy...
> >>>
> >>>
> >>> I'm not sure I understand : if you get an exception in the runTasks()
> >>> call, the 'finally' code is executed, and the number of idle worker is
> >>> incremented, no matter what...
> >>>
> >>>
> >>> Can you check that ?
> >>>
> >>> --
> >>>
> >>> Emmanuel Lecharny
> >>>
> >>> Symas.com
> >>> directory.apache.org
> >>>
> >>>
>
> --
> Emmanuel Lecharny
>
> Symas.com
> directory.apache.org
>
>


Re: Mina stop work cause by exception in OrderedThreadPoolExecutor.Worker.run()

2017-01-19 Thread Emmanuel Lécharny
Sorry, still stuck with day job :/  Will try to squeeze one hour out of
my busy schedule to review your explaination.


I also have to do a small experiment to reproduce the issue.


Thanks for your patience !


Le 17/01/2017 à 05:32, Xu Congyuan a écrit :
> Dear all, Hope you are doing well.
>
> Please kindly advise if the problem I found is on processing. Any
> informations , please feel free to let me know.
>
>
>
> 2017-01-13 9:12 GMT+08:00 Xu Congyuan :
>
>> Thanks for reply. Sorry for not clear it.
>> Basically, we will get the number of idleWorkers 0 or more than 0,
>> if idleWorkers = 0, that's meaning no work is idle, we should add workers
>> if it's necessary;
>> if idleWorkers > 0 , that's meaning there are idle works, no necessary to
>> add workers.
>> Do I get the point?
>> Let's back to the original,  while the MINA starting. At this time, the
>> num of idleWorker == 0, therefor we call addWorkerIfNecessary() method when
>> task is coming, because of idleWorker == 0,  we do addWorker and increase
>> the num of idle at line 259 (version 2.0.16). so idleWorker == 1 at this
>> time, the first worker be fired and start running, we enter the infinite
>> loop, and decrease the num of idleWorker to 0 at line 686(version 2.0.16),
>> basically that's we expected, but there is exception throw by runTasks(),
>> the finally code is executed at line 707,  and increase the idleWorker to 1
>> again, the infinite 'for' loop drop out because we don't catch the
>> exception, the outer try...finally code executed at line 712 removed the
>> worker.
>> Let's sort out ideas, by now,  the idleWorker == 1 and there is no worker
>> is running, is right? so the mina fall into fake dead.
>>
>> Please let me know I did the right investigation.
>>
>>
>> 2017-01-13 0:11 GMT+08:00 Emmanuel Lécharny :
>>
>>> Hi !
>>>
>>>
>>> sorry for the delayed response, was busy...
>>>
>>>
>>> I'm not sure I understand : if you get an exception in the runTasks()
>>> call, the 'finally' code is executed, and the number of idle worker is
>>> incremented, no matter what...
>>>
>>>
>>> Can you check that ?
>>>
>>> --
>>>
>>> Emmanuel Lecharny
>>>
>>> Symas.com
>>> directory.apache.org
>>>
>>>

-- 
Emmanuel Lecharny

Symas.com
directory.apache.org



Re: Mina stop work cause by exception in OrderedThreadPoolExecutor.Worker.run()

2017-01-16 Thread Emmanuel Lécharny


Le 17/01/2017 à 05:32, Xu Congyuan a écrit :
> Dear all, Hope you are doing well.
>
> Please kindly advise if the problem I found is on processing. Any
> informations , please feel free to let me know.

Sorry, was busy.. I will reply today.

-- 
Emmanuel Lecharny

Symas.com
directory.apache.org



Re: Mina stop work cause by exception in OrderedThreadPoolExecutor.Worker.run()

2017-01-16 Thread Xu Congyuan
Dear all, Hope you are doing well.

Please kindly advise if the problem I found is on processing. Any
informations , please feel free to let me know.



2017-01-13 9:12 GMT+08:00 Xu Congyuan :

> Thanks for reply. Sorry for not clear it.
> Basically, we will get the number of idleWorkers 0 or more than 0,
> if idleWorkers = 0, that's meaning no work is idle, we should add workers
> if it's necessary;
> if idleWorkers > 0 , that's meaning there are idle works, no necessary to
> add workers.
> Do I get the point?
> Let's back to the original,  while the MINA starting. At this time, the
> num of idleWorker == 0, therefor we call addWorkerIfNecessary() method when
> task is coming, because of idleWorker == 0,  we do addWorker and increase
> the num of idle at line 259 (version 2.0.16). so idleWorker == 1 at this
> time, the first worker be fired and start running, we enter the infinite
> loop, and decrease the num of idleWorker to 0 at line 686(version 2.0.16),
> basically that's we expected, but there is exception throw by runTasks(),
> the finally code is executed at line 707,  and increase the idleWorker to 1
> again, the infinite 'for' loop drop out because we don't catch the
> exception, the outer try...finally code executed at line 712 removed the
> worker.
> Let's sort out ideas, by now,  the idleWorker == 1 and there is no worker
> is running, is right? so the mina fall into fake dead.
>
> Please let me know I did the right investigation.
>
>
> 2017-01-13 0:11 GMT+08:00 Emmanuel Lécharny :
>
>> Hi !
>>
>>
>> sorry for the delayed response, was busy...
>>
>>
>> I'm not sure I understand : if you get an exception in the runTasks()
>> call, the 'finally' code is executed, and the number of idle worker is
>> incremented, no matter what...
>>
>>
>> Can you check that ?
>>
>> --
>>
>> Emmanuel Lecharny
>>
>> Symas.com
>> directory.apache.org
>>
>>
>


Re: Mina stop work cause by exception in OrderedThreadPoolExecutor.Worker.run()

2017-01-12 Thread Xu Congyuan
Thanks for reply. Sorry for not clear it.
Basically, we will get the number of idleWorkers 0 or more than 0,
if idleWorkers = 0, that's meaning no work is idle, we should add workers
if it's necessary;
if idleWorkers > 0 , that's meaning there are idle works, no necessary to
add workers.
Do I get the point?
Let's back to the original,  while the MINA starting. At this time, the num
of idleWorker == 0, therefor we call addWorkerIfNecessary() method when
task is coming, because of idleWorker == 0,  we do addWorker and increase
the num of idle at line 259 (version 2.0.16). so idleWorker == 1 at this
time, the first worker be fired and start running, we enter the infinite
loop, and decrease the num of idleWorker to 0 at line 686(version 2.0.16),
basically that's we expected, but there is exception throw by runTasks(),
the finally code is executed at line 707,  and increase the idleWorker to 1
again, the infinite 'for' loop drop out because we don't catch the
exception, the outer try...finally code executed at line 712 removed the
worker.
Let's sort out ideas, by now,  the idleWorker == 1 and there is no worker
is running, is right? so the mina fall into fake dead.

Please let me know I did the right investigation.


2017-01-13 0:11 GMT+08:00 Emmanuel Lécharny :

> Hi !
>
>
> sorry for the delayed response, was busy...
>
>
> I'm not sure I understand : if you get an exception in the runTasks()
> call, the 'finally' code is executed, and the number of idle worker is
> incremented, no matter what...
>
>
> Can you check that ?
>
> --
>
> Emmanuel Lecharny
>
> Symas.com
> directory.apache.org
>
>


Re: Mina stop work cause by exception in OrderedThreadPoolExecutor.Worker.run()

2017-01-12 Thread Emmanuel Lécharny
Hi !


sorry for the delayed response, was busy...


I'm not sure I understand : if you get an exception in the runTasks()
call, the 'finally' code is executed, and the number of idle worker is
incremented, no matter what...


Can you check that ?

-- 

Emmanuel Lecharny

Symas.com
directory.apache.org