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

Contention under heavy load in SSL handshake

    Details

      Description

      FULL PRODUCT VERSION :
       JDK: 1.8.0_152 (mixed mode)

      ADDITIONAL OS VERSION INFORMATION :
      Windows Server 2012 R2 - (6.3, amd64)

      A DESCRIPTION OF THE PROBLEM :
      Under heavy load we are having hard contention when performing the SSL handshake:

         java.lang.Thread.State: BLOCKED (on object monitor)
      at java.security.Provider.getService(Unknown Source)
      - waiting to lock <0x00000000e04239b8> (a sun.security.ec.SunEC)
      at sun.security.jca.ProviderList$ServiceList.tryGet(Unknown Source)
      at sun.security.jca.ProviderList$ServiceList.access$200(Unknown Source)
      at sun.security.jca.ProviderList$ServiceList$1.hasNext(Unknown Source)
      at javax.crypto.KeyGenerator.nextSpi(KeyGenerator.java:338)
      - locked <0x00000000dfe4d448> (a java.lang.Object)
      at javax.crypto.KeyGenerator.<init>(KeyGenerator.java:168)
      at javax.crypto.KeyGenerator.getInstance(KeyGenerator.java:223)
      at sun.security.ssl.JsseJce.getKeyGenerator(Unknown Source)
      at sun.security.ssl.Handshaker.calculateConnectionKeys(Unknown Source)
      at sun.security.ssl.ServerHandshaker.clientHello(Unknown Source)
      at sun.security.ssl.ServerHandshaker.processMessage(Unknown Source)
      at sun.security.ssl.Handshaker.processLoop(Unknown Source)
      at sun.security.ssl.Handshaker$1.run(Unknown Source)
      at sun.security.ssl.Handshaker$1.run(Unknown Source)
      at java.security.AccessController.doPrivileged(Native Method)
      at sun.security.ssl.Handshaker$DelegatedTask.run(Unknown Source)
      - locked <0x00000000dfe3b988> (a sun.security.ssl.SSLEngineImpl)
      at org.glassfish.grizzly.ssl.SSLUtils.executeDelegatedTask(SSLUtils.java:274)
      at org.glassfish.grizzly.ssl.SSLBaseFilter.doHandshakeStep(SSLBaseFilter.java:709)
      at org.glassfish.grizzly.ssl.SSLFilter.doHandshakeStep(SSLFilter.java:332)
      at org.glassfish.grizzly.ssl.SSLBaseFilter.doHandshakeStep(SSLBaseFilter.java:623)
      at org.glassfish.grizzly.ssl.SSLBaseFilter.handleRead(SSLBaseFilter.java:335)


      "[MuleSharedDomainOnPremise].HTTP_Secure_Listener_Configuration.worker.45" #178 daemon prio=5 os_prio=0 tid=0x00000000174f6000 nid=0x18dc waiting for monitor entry [0x000000002507e000]
         java.lang.Thread.State: BLOCKED (on object monitor)
      at java.security.Provider.getService(Unknown Source)
      - waiting to lock <0x00000000e04239b8> (a sun.security.ec.SunEC)
      at sun.security.jca.ProviderList$ServiceList.tryGet(Unknown Source)
      at sun.security.jca.ProviderList$ServiceList.access$200(Unknown Source)
      at sun.security.jca.ProviderList$ServiceList$1.hasNext(Unknown Source)
      at javax.crypto.Cipher.getInstance(Cipher.java:513)
      at sun.security.ssl.JsseJce.getCipher(Unknown Source)
      at sun.security.ssl.CipherBox.<init>(Unknown Source)
      at sun.security.ssl.CipherBox.newCipherBox(Unknown Source)
      at sun.security.ssl.CipherSuite$BulkCipher.newCipher(Unknown Source)
      at sun.security.ssl.Handshaker.newReadCipher(Unknown Source)
      at sun.security.ssl.SSLEngineImpl.changeReadCiphers(Unknown Source)
      at sun.security.ssl.SSLEngineImpl.readRecord(Unknown Source)
      - locked <0x00000000e6bee268> (a sun.security.ssl.SSLEngineImpl)
      at sun.security.ssl.SSLEngineImpl.readNetRecord(Unknown Source)
      at sun.security.ssl.SSLEngineImpl.unwrap(Unknown Source)
      - locked <0x00000000e6bee320> (a java.lang.Object)
      at javax.net.ssl.SSLEngine.unwrap(Unknown Source)
      at org.glassfish.grizzly.ssl.SSLUtils.sslEngineUnwrap(SSLUtils.java:465)
      at org.glassfish.grizzly.ssl.SSLConnectionContext.unwrap(SSLConnectionContext.java:193)

      This seems related to the issues mentioned here:

      https://bugs.java.com/view_bug.do?bug_id=7092821

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      Some kind of caching for the provider list.

      REPRODUCIBILITY :
      This bug can be reproduced often.

        Attachments

          Activity

            People

            • Assignee:
              psonal Pallavi Sonal
              Reporter:
              webbuggrp Webbug Group
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: