|
Home > Archive > Apache Directory Project > November 2006 > Warning: serious VM leak/bug with BlockingQueue & polling timeouts
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Warning: serious VM leak/bug with BlockingQueue & polling timeouts
|
|
| Holger Hoffstaette 2006-11-21, 7:11 pm |
|
Here's a heads up for those of you who have the source handy to check.
Both JDK 1.5 and 1.6 have serious confirmed bugs that leak unreclaimable
memory and will bring *idle* servers down, e.g. during the night or over
the weekend when load is low or nonexistent. For more information see
http://bugs.sun.com/bugdatabase/vie...?bug_id=6460501 and related.
In a nutshell BlockingQueue.poll(duration, TimeUnit) will leak *when that
wait times out*; it will not leak when something is returned from the
queue, as is the case with uninterrupted non-timed polling.
The bug is confirmed and serious because it triggers extremely nasty GC
panic that has the potential to bring the whole machine down due to
excessive CPU spinning and unresponsiveness of the VM to external signals.
I think it would be good if someone with the source would do a quick "find
all references to method" to see if and how Mina is affected by this. I
would not be surprised if this is the reason behind some reported leaks -
polling with timeout is extremely useful for service scheduling in various
forms and generally preferrable to complete blocking.
hope this helps 
Holger
| |
| Trustin Lee 2006-11-22, 1:11 am |
| On 11/22/06, Holger Hoffstaette <holger-CM1BQAULw3SELgA04lAiVw@public.gmane.org> wrote:
>
>
> Here's a heads up for those of you who have the source handy to check.
>
> Both JDK 1.5 and 1.6 have serious confirmed bugs that leak unreclaimable
> memory and will bring *idle* servers down, e.g. during the night or over
> the weekend when load is low or nonexistent. For more information see
> http://bugs.sun.com/bugdatabase/vie...?bug_id=6460501 and related.
>
> In a nutshell BlockingQueue.poll(duration, TimeUnit) will leak *when that
> wait times out*; it will not leak when something is returned from the
> queue, as is the case with uninterrupted non-timed polling.
>
> The bug is confirmed and serious because it triggers extremely nasty GC
> panic that has the potential to bring the whole machine down due to
> excessive CPU spinning and unresponsiveness of the VM to external signals.
>
> I think it would be good if someone with the source would do a quick "find
> all references to method" to see if and how Mina is affected by this. I
> would not be surprised if this is the reason behind some reported leaks -
> polling with timeout is extremely useful for service scheduling in various
> forms and generally preferrable to complete blocking.
Wow, this is shocking. Even Doug Lea and his co-workers make a mistake! 
I think the reason why this bug is found so late is because most people
doesn't specify the polling timeout like we didn't for MINA.
Trustin
--
what we call human nature is actually human habit
--
http://gleamynode.net/
--
PGP key fingerprints:
* E167 E6AF E73A CBCE EE41 4A29 544D DE48 FE95 4E7E
* B693 628E 6047 4F8F CFA4 455E 1C62 A7DC 0255 ECA6
|
|
|
|
|