From: anleb <an...@sm...> - 2012-03-21 11:40:17
|
Hello, Probably, it was broken in revision #611 class net.webassembletool.output.Output revision 610 code public final void addHeader(String name, String value) { headers.put(name, value); } revision 611 code public final void addHeader(String name, String value) { List<String> values = null; for (Entry<String, List<String>> entry : headers.entrySet()) { if (name.equalsIgnoreCase(entry.getKey())) { values = entry.getValue(); break; } } if (values == null) { values = new ArrayList<String>(); headers.put(name, values); } values.add(value); } So in the same method we do iteration over headers and change them, in multi thread environment this can cause problem. The easiest way to fix it, to add 'synchronized' to follow methods in class net.webassembletool.output.Output: public synchronized final String getHeader(String key) public synchronized final void setHeader(String key, String value) public synchronized final void setHeader(String key, String value) On 03/21/2012 12:44 PM, Nicolas Richeton wrote: > Hi all > > We have an issue with with ESIGate 2.19 under load, resulting to 100% cpu usage and lock. > > Please have a look to : > http://sourceforge.net/apps/mantisbt/webassembletool/view.php?id=84 > > We have the setup show the issue, but not easy to test. Problem arises after several hours. > > This seems to be linked to the new cache system because older versions of ESIGate did not show any locking under heavy load. > > Andreii : any idea/comments on this issue ? > > Nicolas -- Best Regards, Andrei Lebedinskiy, Java Web Developer Smile Ukraine - Open source Solutions in Ukraine www.smile-ukraine.com Skype:lebedinskii E-mail:an...@sm... |