Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8065709

Deadlock in awt/logging apparently introduced by 8019623

XMLWordPrintable

    • b52
    • x86
    • linux

        Here at Google we are seeing a new deadlock in awt/logging, introduced apparently in the changes in jdk7u between jdk7u71 and jdk7u72.

        Our top suspect is:

        # User mcherkas
        # Date 1396282280 -14400
        # Mon Mar 31 20:11:20 2014 +0400
        # Node ID 40baa37fb20ca0411bb87f6e391a53253d4bb5e6
        # Parent 2fa3608c1da848f5394a6dda775826fb988ea75e
        8019623: Lack of synchronization in AppContext.getAppContext()
        Reviewed-by: anthony, art

        (although we don't have a reproducible test case yet)

        Here's a snippet from a deadlock stacktrace:

        "Replication Worker-3" Id=309 BLOCKED on sun.awt.AppContext$GetAppContextLock@22170aa9 owned by "GSE worker #18" Id=200

        sun.awt.AppContext$3.run(AppContext.java:315)
         sun.awt.AppContext$3.run(AppContext.java:301)
         java.security.AccessController.doPrivileged(Native Method)
         sun.awt.AppContext.getAppContext(AppContext.java:300)
         sun.awt.AppContext$6.getAppletContext(AppContext.java:904)
         java.util.logging.LogManager.getUserContext(LogManager.java:389) <= Acquires lock
         java.util.logging.LogManager.getLogger(LogManager.java:1067)
         java.util.logging.LogManager.demandLogger(LogManager.java:430)
         java.util.logging.Logger.demandLogger(Logger.java:346)
         java.util.logging.Logger.getLogger(Logger.java:393)

        "GSE worker #18 BLOCKED on sun.awt.AppContext$6@5911d676 owned by "Replication Worker-3" Id=309
        java.util.logging.LogManager.getUserContext(LogManager.java:389)
         java.util.logging.LogManager.addLogger(LogManager.java:1004)
         java.util.logging.LogManager.demandSystemLogger(LogManager.java:471)
         java.util.logging.Logger.getPlatformLogger(Logger.java:473)
         java.util.logging.LoggingProxyImpl.getLogger(LoggingProxyImpl.java:41)
         sun.util.logging.LoggingSupport.getLogger(LoggingSupport.java:100)
         sun.util.logging.PlatformLogger$JavaLoggerProxy.<init>(PlatformLogger.java:639)
         sun.util.logging.PlatformLogger$JavaLoggerProxy.<init>(PlatformLogger.java:634)
         sun.util.logging.PlatformLogger.<init>(PlatformLogger.java:243)
         sun.util.logging.PlatformLogger.getLogger(PlatformLogger.java:202)
         java.awt.EventQueue.<clinit>(EventQueue.java:184)
         java.lang.Class.forName0(Native Method)
         java.lang.Class.forName(Class.java:187)
         sun.awt.SunToolkit.initEQ(SunToolkit.java:116)
         sun.awt.SunToolkit.createNewAppContext(SunToolkit.java:295)
         sun.awt.AppContext$2.run(AppContext.java:274)
         sun.awt.AppContext$2.run(AppContext.java:263)
         java.security.AccessController.doPrivileged(Native Method)
         sun.awt.AppContext.initMainAppContext(AppContext.java:263)
         sun.awt.AppContext.access$400(AppContext.java:133)
         sun.awt.AppContext$3.run(AppContext.java:318) <= Acquires lock
         sun.awt.AppContext$3.run(AppContext.java:301)
         java.security.AccessController.doPrivileged(Native Method)
         sun.awt.AppContext.getAppContext(AppContext.java:300)
         javax.imageio.spi.IIORegistry.getDefaultInstance(IIORegistry.java:154)
         javax.imageio.ImageIO.<clinit>(ImageIO.java:65)

              mcherkas Mikhail Cherkasov (Inactive)
              martin Martin Buchholz
              Votes:
              0 Vote for this issue
              Watchers:
              12 Start watching this issue

                Created:
                Updated:
                Resolved: