Load large size document is showing “aw snap” error in chrome browser.

158 views
Skip to first unread message

Jayaseelan A

unread,
Jul 4, 2016, 12:44:41 PM7/4/16
to PDFTron WebViewer
Hi,
We are facing some serious issue in chrome browser and we used latest WebViewer to load the XOD document through s3 url.

1.Document loading is taking 15 to 20 sec and after opening the document is showing “aw snap” error. 

2.if search word it’s returning multiple matches. While clicking through the results and was able to replicate issue encountered.

We are using chrome browser Version 51.0.2704.106 m 

Note :large document (approx. 24643 pages) and but it is viewing as expected on FF and IE browser.

I have attached the screen shot for the same and sample s3 url as given below. 


please help us to resolve the issue asap.

Waiting for your reply.
Error_chrome.png

Matt Parizeau

unread,
Jul 4, 2016, 7:06:36 PM7/4/16
to PDFTron WebViewer
Hi Jayaseelan,

The issue seems to be with the browser taking a very long time to layout the thumbnail view because there are so many elements inside of it. If you have the left panel closed when the document is opened then you'll see that it doesn't take nearly as long to load the first page. By default WebViewer remembers whether the left panel was closed or opened so it may be that in Chrome you had it open the previous time you viewed a document and it was closed in other browsers. I was able to reproduce similar large slow downs in other browsers.

To work around this there are a few different options. 
  1. Disable the thumbnail view completely, removing it from ReaderControl.html and removing the call to initThumbnailView in ReaderControl.js.
  2. Have the side window closed by default. You can modify the value in ControlUtils.js to set viewerPreferences: { showSideWindow: false }. Note that this will push the slowness to when the user opens the left panel. 
  3. Modify the code for the thumbnail view so that it only shows the thumbnails for the visible pages. You would have to make modifications to updateThumbnailPages so that it doesn't add all the containers initially and also append thumbs.
Matt Parizeau
Software Developer
PDFTron Systems Inc.

Jayaseelan A

unread,
Jul 8, 2016, 12:26:25 PM7/8/16
to pdfnet-w...@googlegroups.com
Matt,

We modify the value showsidewindow : false,but we still have the issue.

Steps to reproduce:
1. Load the document through s3 url ->
2. Click sidepanel -> tab full document search, if search with word ‘the’ -> it’s returning multiple matches -> after few seconds
the results it is showing “aw snap” error. 

Note : The document is opened ,but the issue is reproducing searching scenario.

please help us to resolve the issue asap.

Thanks

Tim Horzmann

unread,
Jul 14, 2016, 3:11:15 PM7/14/16
to PDFTron WebViewer
Hi Matt,

I am experiencing the same issue with a much smaller file (800 pages).  When converted the attached PDF is not searchable in Chrome or IE but works fine in Firefox and Edge.  

Tim 

Matt Parizeau

unread,
Jul 14, 2016, 8:53:09 PM7/14/16
to PDFTron WebViewer
Hi Tim,

If you comment out the function "updateThumbnailPages" in ReaderControl.js do you still see the issue? If you do would you be able to send the XOD file.

One other thing you could try is setting the layout to single page mode. By default we set it to single page mode if the document is over 1000 pages so for your document you could set it yourself like:
readerControl.docViewer.on('beforeDocumentLoaded', function() {
    readerControl
.setLayoutMode(window.CoreControls.DisplayModes.Single);
});

You could also use the documentLoaded event, but beforeDocumentLoaded is slightly better for performance reasons.

Matt Parizeau
Software Developer
PDFTron Systems Inc.

Tim Horzmann

unread,
Jul 15, 2016, 1:00:28 PM7/15/16
to PDFTron WebViewer
Hi Matt,

I tried both of your suggestions. Neither of them helped with the search problem.  Any other thoughts?

Tim

Matt Parizeau

unread,
Jul 15, 2016, 2:45:23 PM7/15/16
to PDFTron WebViewer
Hi Tim,

Could you send the XOD file and we can investigate further. Thanks!

Matt Parizeau
Software Developer
PDFTron Systems Inc.

Jayaseelan A

unread,
Jul 19, 2016, 2:20:45 PM7/19/16
to PDFTron WebViewer
Hi Matt, 
We are facing the search issue document as given below url,


Steps to reproduce:
1. Load the document ->
2. Click sidepanel -> tab full document search, if search with word 'globus' -> it’s returning multiple matches -> after few seconds the results it is showing “aw snap” error.

please help us to resolve the issue ASAP.

waiting for your reply.

Thanks

Matt Parizeau

unread,
Jul 19, 2016, 6:00:59 PM7/19/16
to PDFTron WebViewer
Hi Jayaseelan and Tim,

Thank you for the documents! We were able to reproduce the problem and fix it. You can download a build with the fix here http://www.pdftron.com/ID-zJWLuhTffd3c/WebViewer/WebViewer_2.2.0.47367.zip

Matt Parizeau
Software Developer
PDFTron Systems Inc.

Jayaseelan A

unread,
Jul 20, 2016, 12:53:11 PM7/20/16
to PDFTron WebViewer
Matt,
Thank you for your response.

Can you please confirm in the custom build , in which web viewer files did you fixed this issue? If we get those file information’s then it will be good for us to fix the issue from our end.

Thanks

Tim Horzmann

unread,
Jul 21, 2016, 12:52:12 PM7/21/16
to PDFTron WebViewer
Matt,
Tested and works.  Thanks 
Tim

Jayaseelan A

unread,
Jul 22, 2016, 1:00:17 PM7/22/16
to PDFTron WebViewer
Matt,
The above issue has been fixed, but the iframe mobile issue(https://groups.google.com/forum/#!searchin/pdfnet-webviewer/jayaseelan/pdfnet-webviewer/O4ryfTAxPh4/iyrOQd73CAAJ) is not working in the custom build. 

Please fix for the same and send it to us.

waiting for your reply 

Thanks

Matt Parizeau

unread,
Jul 25, 2016, 5:20:10 PM7/25/16
to PDFTron WebViewer
Hi Jayaseelan,

The changes mentioned in the thread you linked should be included in the latest build linked above. If you're having trouble with that you could always copy the files manually that are linked from that post.

As for what changed in this build you would only need to update CoreControls.js.

Matt Parizeau
Software Developer
PDFTron Systems Inc.

Jayaseelan A

unread,
Jul 27, 2016, 1:47:17 PM7/27/16
to PDFTron WebViewer
Matt,
As you said,we update the CoreControl.js in our code,the searching issue is working as expected,but the mobile iframe issue is not working in this build.


Note: The mobile issue is fixed in existing CoreControl.js.

Please check for the same from your end in this build.

Thanks
Reply all
Reply to author
Forward
0 new messages