United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6896157 unsynchronized hashmap in com.sun.corba.se.impl.transport.SelectorImpl.createReaderThread
JDK-6896157 : unsynchronized hashmap in com.sun.corba.se.impl.transport.SelectorImpl.createReaderThread

Details
Type:
Bug
Submit Date:
2009-10-28
Status:
Closed
Updated Date:
2011-02-16
Project Name:
JDK
Resolved Date:
2010-01-12
Component:
other-libs
OS:
solaris_10
Sub-Component:
corba:orb
CPU:
sparc
Priority:
P2
Resolution:
Fixed
Affected Versions:
5.0-pool
Fixed Versions:
6u17-rev (b10)

Related Reports
Backport:
Backport:
Backport:
Backport:
Backport:
Backport:
Backport:
Backport:

Sub Tasks

Description
hreads consuming high cpu tracked down to unsynchronized hashmap
usage in com.sun.corba.se.impl.transport.SelectorImpl.createReaderThread.

ustomer make this change to their jdk 5.0 based jar file.
It is reported that with customized changes as shown below (lines with
keyword CSB), the issue is resolved.

/*
* @(#)SelectorImpl.java 1.22 09/04/01
*
* Copyright 2006 Sun Microsystems, Inc. All rights reserved.
* SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
*/

...
import java.util.Map; // Added this line CSB
...
private Map readerThreads; // Used to be HashMap CSB
...
readerThreads = (Map) java.util.Collections.synchronizedMap(new HashMap()); // Use synchronizedMap CSB

                                    

Comments
EVALUATION

Hi Haroon,

Irrespective of the stacktrace, which would only show java call stack, the control should be at the application level or the application server like weblogic/ Glassfish etc. The customer may be using one of this.  There should be some place where the call gets into the java layer and that is where the synchronization is advised.

However, since there is no testcase, we have nothing much to analyze. So I have just created an FVB with the changes requested by the customer.
/net/jdk/export/jpse01/sunita/FVB/160/6896157/idr-231192575/...
There are bundles for all supported platforms. You can choose any one of them.
I will need a confirmation from the customer. Without which I cannot proceed with integration. I understand that this would take some time as the frequency of the occurrence of the issue is not predictable. Hence I am moving the CR to afa (awaiting field action).

Thanks
Sunita
                                     
2009-11-23
EVALUATION

http://hg.openjdk.java.net/jdk7/tl/corba/rev/cd7abebaa49b
                                     
2010-11-08
EVALUATION

http://hg.openjdk.java.net/jdk7/build/corba/rev/2d3622317730
                                     
2010-12-25



Hardware and Software, Engineered to Work Together