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

Java WebView communication between java and javascript fails in Java 8 U112


    • Type: Bug
    • Status: Closed
    • Priority: P2
    • Resolution: Not an Issue
    • Affects Version/s: 8u112, 9
    • Fix Version/s: 9
    • Component/s: javafx
    • Labels:
    • Environment:

      JavaSE8u112 Windows+x86/x64

    • Subcomponent:
    • CPU:
    • OS:


      Our javafx application extensively uses communication between java and javascript via
      netscape.javascript.JSObject.call and JSObject.setMember().

      These functions worked completely fine in Java 8 U92, but when we upgraded to Java 8 U112, we only can use these method for a limited amount of time before they start failing and they no longer get called and don't print out any error.

      For example, the attached JavaFxInteropt will run indefinitely in Java 8 U92 (I've gotten the counter up to 11,000 and I stopped counting, but it will fail pretty quickly in Java 8 U112 (when the counter is up to 160 or so, it fails and stops communicating between java and javascript.

      The page simulates the bug found in our software, we have a single web view and we have a bunch of interropt calls and users refresh the webview and we expect that calls to continue indefinitely since they are setup fresh on each State.SUCCEEDED when the Web Engine is loaded.

      This back and forth between java and javascript is very important to our product and it we cannot run our software without consistent communication between java and javascript.


        1. JavaFxInteropt.class
          3 kB
          Guixin Cheng
        2. JavaFxInteropt.java
          15 kB
          Guixin Cheng
        3. JavaFxInteropt$1.class
          0.2 kB
          Guixin Cheng
        4. JavaFxInteropt$Browser.class
          6 kB
          Guixin Cheng
        5. JavaFxInteropt$IJs.class
          0.8 kB
          Guixin Cheng
        6. JavaFxInteropt$JsNetscape.class
          3 kB
          Guixin Cheng
        7. JavaFxInteropt$SupplierReflectionWrapper.class
          0.9 kB
          Guixin Cheng

          Issue Links



              • Assignee:
                mbilla Murali Billa
                gucheng Guixin Cheng
              • Votes:
                0 Vote for this issue
                4 Start watching this issue


                • Created: