Hi to All,
we have an webapplication with embedded Java Applets.
One of the Java Applet is the icePDF-Viewer applet.
We have some different web pages, but the pages are always splitted in the middle (left side/right side of the web page), e.g.:
1.) On the left side we have the icePDF-Viewer embedded (the icePDF-Viewer shows a pdf document) and on the right side we have some data (metadata) for the pdf document.
2.) On the left and on the right side we have the icePDF-Viewer embedded.
It means in this case we show two pdf document in one html page (on the left side and on the right side).
At 1.) and 2.) we shows some tasks/processes.
And we can go from one task/process to the next one.
It means we have a sequence of 1.) + 1.) + 1.) or we have a sequence of 2.) + 2.) + 2.) ...
At the first and second sequence of 2.) all works OK. But on the third or fourth sequence an error occured and a blank page (the icePDF-viewer will show a blank/white page) will be shown.
In the log we can see:
***** stop() - Dokument geschlossen.
***** destroy() - PDFViewer beendet.
basic: Applet-Teardown beendet
basic: Fortschritts-Listener entfernt: sun.plugin.util.ProgressMonitorAdapter@1cddcfe
basic: PluginMain.unregisterApplet: 4 from mananger sun.plugin2.applet.Applet2Manager@1d0d5ae
Exception in thread "ICEpdf-thread-pool" java.lang.IllegalMonitorStateException
at java.util.concurrent.locks.ReentrantLock$Sync.tryRelease(Unknown Source)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.release(Unknown Source)
at java.util.concurrent.locks.ReentrantLock.unlock(Unknown Source)
at java.util.concurrent.LinkedBlockingQueue.take(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.getTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
***** PDFViewer init() ...
It means the error occurs after the applet calls destroy() and before the next viewer calls init().
And we get the error only, when we start two icePDF-Viewer (start two applets) at the same time (see 2.) show pdf document on the left side and on the right side of the web page) and when we scroll (show the next sequence of 2.)) from one sequence to the next.
We don't get the error on 1.). It means when have only one icePDF-Viewer then we get no error.
It tried the solution on http://www.icesoft.org/JForum/posts/list/22044.page, but with no success:
Library.initializeThreadPool(); is called at init() methode and
Library.shutdownThreadPool(); is called at destroy() methode.
It try it with the versions: 5.0.2, 5.1.1, 6.1.3 and 6.2.1
All the same
What can we do to avoid the problem?
Thanks a lot!