Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-4715

multiple parallel embeds failing (without error)

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • 9.5.1
    • 9.5.0.1
    • ZK Client Engine
    • Security Level: Jimmy

      Steps to Reproduce

      initiate multiple embeds simultaneously

      <!DOCTYPE html>
      <html lang="en">
      <head>
          <title>Embedded ZK Minimal</title>
          <script id="embeddedScript"
                  src="http://localhost:8080/zkembedded-app/zkau/web/js/zkmax/embedded/embedded.js"></script>
      </head>
      <body>
          <h1>Multiple-Embeds</h1>
          <div id="zkapp">Loading ZK ...</div>
          <div id="zkapp2">Loading ZK ...</div>
          <script>
              zEmbedded.load('zkapp', 'http://localhost:8080/zkembedded-app/multiple-bug.zul')
                  .then(function(result) { console.log('zkapp', result); })
                  .catch(function(error) { console.error(error); });
              zEmbedded.load('zkapp2', 'http://localhost:8080/zkembedded-app/multiple-bug.zul')
                  .then(function(result) { console.log('zkapp2', result); })
                  .catch(function(error) { console.error(error); });
          </script>
      </body>
      </html>
      

      Current Result

      resources are downloaded multiple times

      page simply freezes

      no error message

      Expected Result

      resources only loading once

      possible to start multiple embeds in parallel

      (at least client side) error logs in case a problem occurs

      (also consider preventing/report multiple conflicting ZK versions)

      Debug Information

      ZK's wdp resources are loaded multiple times ... potentially causing initialization problems

      It also looks like requests are sent using different session IDs

      Workaround

      delay the second embed (works - but still downloads wpd files again)

            DevChu DevChu
            cor3000 cor3000
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: