This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Web Client loads an applet (Main.class) and seems to work fine on windows/solaris https services.
Seeing the below console info when applet is not loaded from a set of AIX services running https.
Console output ============================================= network: Connecting https://server:15004/cm/Main.class with proxy=DIRECT network: Connecting https://server:15004/cm/Main/class.class with proxy=DIRECT load: class Main.class not found. java.lang.ClassNotFoundException: Main.class at sun.applet.AppletClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.applet.AppletClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.applet.AppletClassLoader.loadCode(Unknown Source) at sun.applet.AppletPanel.createApplet(Unknown Source) at sun.plugin.AppletViewer.createApplet(Unknown Source) at sun.applet.AppletPanel.runLoader(Unknown Source) at sun.applet.AppletPanel.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Caused by: java.io.IOException: open HTTP connection failed. at sun.applet.AppletClassLoader.getBytes(Unknown Source) at sun.applet.AppletClassLoader.access$100(Unknown Source) at sun.applet.AppletClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) ... 10 more =============================================
See the 'Main/class.class' which I think *must* be the crux of the problem.
I checked source code from the loading page on both working and non-working services, and they matched up:
Oh, also, this doesnt happen for all clients, someone running Vista can open it, while two of us (running XP) can't. Ironically, the Vista machine has the older version of Internet Explorer.
[ February 19, 2008: Message edited by: Tom Katz ]
The "https://server:15004/cm/Main/class.class" may just be a consequence of "https://server:15004/cm/Main.class" not being found, and not the source of the problem.
(To elaborate, there are two ways to specify the class name, either "code=Main" or "code=Main.class". Both are used by various implementations, so if the JVM sees "Main.class" it doesn't know whether the class name is "Main" or if the class name is "class" in a package called "Main". So it tries both wyas.)
Have you tried using an APPLET tag instead of an OBJECT tag?
One thing to investigate -if the problem is repeatable- would be to check the access logs of the web server to see if the request for the class file is actually getting to the web server.
Joined: Aug 19, 2002
Thank you for the ideas. I'm going to first take .class out of the OBJECT tag.
I might try the applet tag as well - as long as it can do everything the OBJECT tag can (enforce JRE level, etc.) I don't see why we haven't been using it yet.
Joined: Aug 19, 2002
One thing I was also going to mention. Along with all the weirdness around what circumstances cause this. If I call the JSP which loads the applet directly (its part of a frameset) using http, the applet loads fine.