-
Bug
-
Resolution: Fixed
-
P3
-
6u29, 8
-
b06
-
x86
-
windows_7
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8260358 | 16.0.1 | Evan Whelan | P3 | Resolved | Fixed | b03 |
JDK-8264500 | 15.0.4 | Yuri Nesterenko | P3 | Resolved | Fixed | b01 |
JDK-8260588 | 13.0.7 | Yuri Nesterenko | P3 | Resolved | Fixed | b01 |
JDK-8261060 | 13.0.6 | Yuri Nesterenko | P3 | Resolved | Fixed | b01 |
JDK-8259981 | 11.0.11-oracle | Dukebot | P3 | Resolved | Fixed | b03 |
JDK-8260412 | 11.0.11 | Jaikiran Pai | P3 | Resolved | Fixed | b03 |
JDK-8269515 | openjdk8u312 | Jaikiran Pai | P3 | Resolved | Fixed | b01 |
JDK-8259985 | 8u291 | Evan Whelan | P3 | Resolved | Fixed | b02 |
JDK-8262654 | emb-8u291 | Evan Whelan | P3 | Resolved | Fixed | team |
java version "1.6.0_29"
Java(TM) SE Runtime Environment (build 1.6.0_29-b11-402-10M3527)
Java HotSpot(TM) 64-Bit Server VM (build 20.4-b02-402, mixed mode)
ADDITIONAL OS VERSION INFORMATION :
all OSs
A DESCRIPTION OF THE PROBLEM :
I've included the relevant deadlock stack trace below, but the root cause is that both
java.net.URLStreamHandler.getHostAddress
and
sun.net.www.protocol.file.Handler.openconnection
are synchronized. Either remove synchronized from getHostAddress and use a local lock object to protect that api or look at Handler and determine if you even need that to be synchronized or not (I didn't see any obvious reason it needed to be).
"dbwriter for ws_attachments [Run1User1Cycle] writing 1 objects, started batch at Thu Feb 16 13:06:00 MST 2012" prio=5 tid=7fed77863800 nid=0x118a61000 waiting for monitor entry [118a5e000]
java.lang.Thread.State: BLOCKED (on object monitor)
at java.net.URLStreamHandler.getHostAddress(URLStreamHandler.java:412)
- waiting to lock <7e002da38> (a sun.net.www.protocol.file.Handler)
at java.net.URLStreamHandler.hostsEqual(URLStreamHandler.java:439)
at sun.net.www.protocol.file.Handler.hostsEqual(Handler.java:117)
at java.net.URLStreamHandler.sameFile(URLStreamHandler.java:396)
at java.net.URLStreamHandler.equals(URLStreamHandler.java:316)
at java.net.URL.equals(URL.java:842)
at java.security.CodeSource.equals(CodeSource.java:135)
at java.util.HashMap.get(HashMap.java:305)
at java.security.SecureClassLoader.getProtectionDomain(SecureClassLoader.java:233)
- locked <7e0040648> (a java.util.HashMap)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
- locked <7e00205b8> (a sun.misc.Launcher$AppClassLoader)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
- locked <7e00205b8> (a sun.misc.Launcher$AppClassLoader)
at java.lang.ClassLoader.loadClass(ClassLoader.java:295)
- locked <7e04223c0> (a com.itko.lisa.test.TestExecClassLoader)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.eclipse.persistence.internal.jpa.deployment.PersistenceUnitProcessor.loadClass(PersistenceUnitProcessor.java:261)
"ws_attachments [Run1User1Cycle]/0" daemon prio=5 tid=7fed7a80f000 nid=0x116172000 waiting for monitor entry [116170000]
java.lang.Thread.State: BLOCKED (on object monitor)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:293)
- waiting to lock <7e00205b8> (a sun.misc.Launcher$AppClassLoader)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at java.net.URL.getURLStreamHandler(URL.java:1144)
at java.net.URL.<init>(URL.java:393)
at java.net.URL.<init>(URL.java:283)
at java.net.URL.<init>(URL.java:306)
at sun.net.www.protocol.file.Handler.openConnection(Handler.java:74)
- locked <7e002da38> (a sun.net.www.protocol.file.Handler)
at sun.net.www.protocol.file.Handler.openConnection(Handler.java:55)
- locked <7e002da38> (a sun.net.www.protocol.file.Handler)
at java.net.URL.openConnection(URL.java:945)
at java.net.URL.openStream(URL.java:1010)
at javax.activation.URLDataSource.getInputStream(URLDataSource.java:92)
at org.apache.axis.attachments.MimeUtils.getContentLength(MimeUtils.java:118)
at org.apache.axis.attachments.MimeUtils.getContentLength(MimeUtils.java:63)
at org.apache.axis.attachments.AttachmentsImpl.getContentLength(AttachmentsImpl.java:461)
at org.apache.axis.Message.getContentLength(Message.java:513)
at com.itko.lisa.ws.axis.LisaHTTPSender$MessageRequestEntity.getContentMessageLength(LisaHTTPSender.java:989)
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
It's hard to reproduce, but the stack traces are clear as to what the issue is
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
it should not deadlock
ACTUAL -
threads deadlock
REPRODUCIBILITY :
This bug can be reproduced occasionally.
CUSTOMER SUBMITTED WORKAROUND :
There are no work-arounds
- backported by
-
JDK-8259981 Deadlock between URLStreamHandler.getHostAddress and file.Handler.openconnection
- Resolved
-
JDK-8259985 Deadlock between URLStreamHandler.getHostAddress and file.Handler.openconnection
- Resolved
-
JDK-8260358 Deadlock between URLStreamHandler.getHostAddress and file.Handler.openconnection
- Resolved
-
JDK-8260412 Deadlock between URLStreamHandler.getHostAddress and file.Handler.openconnection
- Resolved
-
JDK-8260588 Deadlock between URLStreamHandler.getHostAddress and file.Handler.openconnection
- Resolved
-
JDK-8261060 Deadlock between URLStreamHandler.getHostAddress and file.Handler.openconnection
- Resolved
-
JDK-8262654 Deadlock between URLStreamHandler.getHostAddress and file.Handler.openconnection
- Resolved
-
JDK-8264500 Deadlock between URLStreamHandler.getHostAddress and file.Handler.openconnection
- Resolved
-
JDK-8269515 Deadlock between URLStreamHandler.getHostAddress and file.Handler.openconnection
- Resolved
- duplicates
-
JDK-7177996 new URL("file://foo.com/bar").openConnection() blocks class loading for more than 20 sec on Windows
- Closed
- relates to
-
JDK-7177996 new URL("file://foo.com/bar").openConnection() blocks class loading for more than 20 sec on Windows
- Closed
-
JDK-8340993 Opening file URL with non existing host blocks concurrent file URL opening
- Open
- links to
-
Commit openjdk/jdk13u-dev/62f79b19
-
Commit openjdk/jdk15u-dev/c2f0adb5
-
Commit openjdk/jdk16u/d3ecad7b
-
Commit openjdk/jdk/db9c114d
-
Review openjdk/jdk13u-dev/94
-
Review openjdk/jdk15u-dev/4
-
Review openjdk/jdk16u/6
-
Review openjdk/jdk/2109