User 870ab5b546
04-06-2010 13:22:00
MarvinView and MarvinSketch 5.2.6 are failing to launch in one installation of our code. The Java console says,
basic: Referencing classloader: sun.plugin.ClassLoaderInfo@c9e67a, refcount=1
basic: Loading applet…
basic: Added progress listener: sun.plugin.util.GrayBoxPainter@c7e2da
basic: Initializing applet…
basic: Referencing classloader: sun.plugin.ClassLoaderInfo@c9e67a, refcount=2
basic: Releasing classloader: sun.plugin.ClassLoaderInfo@c9e67a, refcount=1
basic: Starting applet…
network: Connecting http://epoch.uky.edu:9080/nosession/marvin/jmarvin.jar with proxy=DIRECT
network: Connecting http://epoch.uky.edu:9080/nosession/marvin/jmarvin.jar with cookie “__utma=43166241.285004050.1259702955.1268705841.1273493008.7”
basic: Loading http://epoch.uky.edu:9080/nosession/marvin/jmarvin.jar from cache
basic: Reading cached JAR file from JRE 1.5 release
basic: Certificates for http://epoch.uky.edu:9080/nosession/marvin/jmarvin.jar is read from JAR cache
network: Connecting http://epoch.uky.edu:9080/nosession/marvin/JMSketch.class with proxy=DIRECT
network: Connecting http://epoch.uky.edu:9080/nosession/marvin/JMSketch.class with cookie “__utma=43166241.285004050.1259702955.1268705841.1273493008.7”
network: Connecting http://epoch.uky.edu:9080/nosession/marvin/JMSketch.class with proxy=DIRECT
network: Connecting http://epoch.uky.edu:9080/nosession/marvin/JMSketch.class with cookie “__utma=43166241.285004050.1259702955.1268705841.1273493008.7”
load: class JMSketch not found.
java.lang.ClassNotFoundException: JMSketch
at sun.applet.AppletClassLoader.findClass(AppletClassLoader.java:211)
at java.lang.ClassLoader.loadClass(ClassLoader.java:317)
at sun.applet.AppletClassLoader.loadClass(AppletClassLoader.java:145)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at sun.applet.AppletClassLoader.loadCode(AppletClassLoader.java:667)
at sun.applet.AppletPanel.createApplet(AppletPanel.java:723)
at sun.plugin.AppletViewer.createApplet(AppletViewer.java:1873)
at sun.applet.AppletPanel.runLoader(AppletPanel.java:652)
at sun.applet.AppletPanel.run(AppletPanel.java:326)
at java.lang.Thread.run(Thread.java:613)
basic: Exception: java.lang.ClassNotFoundException: JMSketch
There is no error in the Javascript console, and no error is reported by the browser itself. A page where Marvin fails to launch can be found here.
Interestingly, we have a second installation of code that appears to be identical and uses the same Marvin codebase, and it launches Marvin just fine. A page where Marvin launches can be found here.
I suspect a missing jar file in one of the installations, but the two installations appear to be identical. Any help in diagnosing the problem would be appreciated.
ChemAxon 7c2d26e5cf
07-06-2010 14:36:34
Both examples works for me.
I assume that it can be a caching problem.
As I see, first example (port 9080) uses 5.3.3, meanwhile, second example (port 8081) refers to 5.2.6 code.
The error message in the first case indicates that Java tried to load JMSketch.class. But in new Marvin (5.3.3), the name of the main class is "chemaxon.marvin.applet.JMSketch.class". I think that the old marvin.js was in the memory when you have tried it. Thus it generated the deprecated applet code for the new applet jars.
I recommend to clear browser cache (refresh marvin.js) and check that the generated applet source refers to the right class.
User 870ab5b546
13-06-2010 01:11:11
Tamas wrote: |
Both examples works for me.
I assume that it can be a caching problem.
As I see, first example (port 9080) uses 5.3.3, meanwhile, second example (port 8081) refers to 5.2.6 code.
The error message in the first case indicates that Java tried to load JMSketch.class. But in new Marvin (5.3.3), the name of the main class is "chemaxon.marvin.applet.JMSketch.class". I think that the old marvin.js was in the memory when you have tried it. Thus it generated the deprecated applet code for the new applet jars.
I recommend to clear browser cache (refresh marvin.js) and check that the generated applet source refers to the right class.
|
I have already cleared both the Java cache and the browser cache repeatedly.
You explain why Marvin 5.3.3 may not load. But it does. The problem is that Marvin 5.2.6 does not load on the :9080 installation. This table may help:
ACE |
Marvin |
Result |
:9080 |
5.3.3 |
Loads |
:9080 |
5.2.6 |
Does not load |
:8081 |
5.2.6 |
Loads |
When you tried the :9080 installation, I had switched it back to Marvin 5.3.3 so I could use that installation. I have now switched it back to Marvin 5.2.6, and Marvin 5.2.6 still does not load, even after emptying the browser and Java caches.
Here is the generated applet source for a :9080 page using Marvin 5.2.6, as revealed by the Safari Web Inspector:
<applet width="450" height="400" id="responseApplet" codebase="/nosession/marvin" archive="jmarvin.jar" code="JMSketch">
<param name="molbg" value="@javascript-URI-encoded@%23ffffff">
<param name="menuconfig" value="@javascript-URI-encoded@%2Fnosession%2FconfigNormal">
<param name="ttmpls0" value="@javascript-URI-encoded@*Generic*chemaxon%2Fmarvin%2Ftemplates%2FACEGenerics.t">
<param name="tmpls6" value="@javascript-URI-encoded@%3AConformers%3Achemaxon%2Fmarvin%2Ftemplates%2Fconformers.t">
<param name="abbrevgroups" value="@javascript-URI-encoded@%2Fnosession%2Fmarvin%2Fchemaxon%2Fmarvin%2Ftemplates%2FACE.abbrevgroups">
<param name="scale" value="@javascript-URI-encoded@32">
<param name="atomMappingVisible" value="@javascript-URI-encoded@false">
<param name="atomNumbersVisible" value="@javascript-URI-encoded@false">
<param name="implicitH" value="@javascript-URI-encoded@heteroterm">
<param name="lonePairsVisible" value="@javascript-URI-encoded@false">
<param name="chiralitySupport" value="@javascript-URI-encoded@off">
<param name="mol" value="@javascript-URI-encoded@">
<param name="extraBonds" value="@javascript-URI-encoded@wedge%2Ceither%2Carom%2Ccoordinate">
<param name="reactionSupport" value="@javascript-URI-encoded@false">
<param name="skin" value="@[email protected]">
<param name="legacy_lifecycle" value="false">
<param name="statusBar" value="@javascript-URI-encoded@true">
<param name="java_arguments" value="-Djnlp.packEnabled=true">
<center><b>YOU CANNOT SEE A JAVA APPLET HERE</b></center>
</applet>
I see that my applet code parameter is defined as "JMSketch", not "chemaxon/marvin/applet/JMSketch". I also see that marvin5.3.3/marvin.js has this code:
if (oldbehaviour){
code = "chemaxon/marvin/applet/JMSketch";
} else {
code = "chemaxon/marvin/applet/JMSketchLaunch";
}
whereas marvin5.2.6/marvin.js has this code:
if (oldbehaviour){
code = "JMSketch";
} else {
code = "JMSketchLaunch";
}
So it does seem that my browser is correctly using marvin5.2.6/marvin.js, but for some reason the :9080 installation is not able to locate JMSketch, whereas the :8081 installation is able to do. Any ideas why? Both installations are pointing to the same installation of Marvin 5.2.6.
User 870ab5b546
14-06-2010 16:53:16
Before I posted the previous message, I confirmed on my home computer that Marvin 5.2.6 would not load on the :9080 site, even after clearing the Java cache and the browser cache.
This morning, when I arrived at work, there was a new version of Safari (5.0) waiting to be installed on my computer, so I installed it. I cleared the Java cache once more, then checked :9080 again to see whether Marvin 5.2.6 loaded. It did.
I had my wife check again at home. In Safari 4.x, Marvin 5.2.6 was still not loading, even after emptying the cache. I then had her install Safari 5.0 and reempty the Java cache. Now Marvin 5.2.6 loads at the :9080 port of ACE. Go figure.
As you can see, there is apparently a weird interaction involving caches, Marvin 5.2.6, and Safari 4.0.3. The upgrade to Safari 5.0 appears to solve the problem.
Rafi says the following:
There has always been something weird about loading Marvin. For a while ChemAxon diagnosed the problem as a Java 1.6.02 problem. I think there are residuals stored in several places that can prevent proper loading of Marvin. One Java cache can be cleared via the Java Control. Another can be cleared by the Java Console. A third can be cleared by the browser. When in doubt, do all three.
-- Bob
ChemAxon 7c2d26e5cf
15-06-2010 13:41:39
Please modify one of applet examples like this to be able to debug generated applet code:
Before:
msketch_end()
After
var appletcode = msketch_end_tostring()
document.alert(appletcode)
It will print generate applet code.
When applet code is printed, you can see whether the generate applet code is fine for the refert applet package or not:
Marvin 5.2.x: for oldbeviour the main class is JMSketch.and chemaxon/marvin/applet/JMSketchLaunch.class for (new
behaviour that is the default setting).
Marvin 5.3.x: for oldbeviour the main class is chemaxon/marvin/applet/JMSketch.and chemaxon/marvin/applet/JMSketchLaunch.class for (new
behaviour that is the default setting).
User 870ab5b546
15-06-2010 18:29:01
I will remember this if the problem arises again. Right now, having upgraded to Safari 5.0 on both my computers, I can no longer reproduce the problem. The Safari 4.0.5 installer doesn't work when a computer already has Safari 5.0 installed. I did find a version of Safari 4.0.3 that I could download, but it shows only the desired behavior.