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

WebView: playing embedded youtube video creates hundreds of threads

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Not an Issue
    • Affects Version/s: 8
    • Fix Version/s: None
    • Component/s: javafx
    • Labels:
    • Environment:

      Win64

    • Subcomponent:
      web

      Description

      We have embedded a youtube video in a WebView. The video works fine. However, while playing the video there are a lot of threads created. The threads are created and finished very quickly. It seems as if there was one thread per frame... It does not matter which video is used. For the demo below I picked a random video.

      import javafx.application.Application;
      import javafx.scene.Scene;
      import javafx.scene.web.WebView;
      import javafx.stage.Stage;

      public class WebViewVideoTest extends Application
      {
        public static void main(String[] args)
        {
          Application.launch(args);
        }
        
        @Override
        public void start(Stage primaryStage) throws Exception
        {
          WebView wv = new WebView();
          wv.getEngine().loadContent("<html><head/><body><iframe width=\"560\" height=\"315\" src=\"http://www.youtube.com/embed/tfd5p1JqUsw\" frameborder=\"0\" allowfullscreen></iframe></body></html>");
          
          primaryStage.setScene(new Scene(wv));
          primaryStage.show();
        }
      }

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              stayer Kirill Kirichenko (Inactive)
              Reporter:
              wlehmann Werner Lehmann
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported: