Java Web Start Error FileNotFoundException - java

So Im trying to use webstart on this application of mine and I keep getting this error:
java.io.FileNotFoundException:
http://www.fenixflame.net/DropLogger/Drop Logger.jar at
sun.reflect.GeneratedConstructorAccessor2.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown
Source) at java.lang.reflect.Constructor.newInstance(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection$6.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method) at
sun.net.www.protocol.http.HttpURLConnection.getChainedException(Unknown
Source) at
sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source) at com.sun.deploy.net.BasicHttpRequest.doRequest(Unknown
Source) at com.sun.deploy.net.BasicHttpRequest.doRequest(Unknown
Source) at com.sun.deploy.net.BasicHttpRequest.doGetRequest(Unknown
Source) at com.sun.deploy.net.DownloadEngine.actionDownload(Unknown
Source) at com.sun.deploy.net.DownloadEngine.getCacheEntry(Unknown
Source) at com.sun.deploy.net.DownloadEngine.getCacheEntry(Unknown
Source) at
com.sun.deploy.net.DownloadEngine.getResourceCacheEntry(Unknown
Source) at
com.sun.deploy.net.DownloadEngine.getResourceCacheEntry(Unknown
Source) at com.sun.deploy.net.DownloadEngine.getResource(Unknown
Source) at com.sun.javaws.LaunchDownload$DownloadTask.call(Unknown
Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown
Source) at java.util.concurrent.FutureTask.run(Unknown Source) at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source) Caused by:
java.io.FileNotFoundException:
http://www.fenixflame.net/DropLogger/Drop Logger.jar at
sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source) at java.net.HttpURLConnection.getResponseCode(Unknown Source)
... 15 more
This is my First time using webstart. I tested it out with simple applications and it worked just fine. I think it might have something to do with the fact that the application tries to read a local file when its launched.
Cannot post more than 2 links but you can check it out here:
fenixflame.net/DropLogger/launch.html

Yes problem was the space on the .jar file. I changed it and it worked just fine.
Its not possible to change the .jar file name inside netBeans, you can only change the project name but that doesnt change the file name. The only way to do change the .jar name is going to the project .xml file or creating a new project with the name you want for your jar file and copying all ur packages there.

Related

Netacad unable to load resource error jnlp

I'm a student and have a problem with opening the check jnlp file from the netacad website. It gives me the following error
com.sun.deploy.net.faileddownloadexception: unable to load resource: http://localhost/check/pt-assessment-client.jnlp
at com.sun.deploy.net.downloadengine.actiondownload(unknown source)
at com.sun.deploy.net.downloadengine.downloadresource(unknown source)
at com.sun.deploy.cache.resourceproviderimpl.getresource(unknown source)
at com.sun.deploy.cache.resourceproviderimpl.getresource(unknown source)
at com.sun.javaws.launcher.updatefinallaunchdesc(unknown source)
at com.sun.javaws.launcher.preparetolaunch(unknown source)
at com.sun.javaws.launcher.preparetolaunch(unknown source)
at com.sun.javaws.launcher.launch(unknown source)
at com.sun.javaws.main.launchapp(unknown source)
at com.sun.javaws.main.continueinsecurethread(unknown source)
at com.sun.javaws.main.access$000(unknown source)
at com.sun.javaws.main$1.run(unknown source)
at java.lang.thread.run(unknown source)
Or it just doesn't start up at all.
I've tried updating my java and trying previous versions. I also tried to remove Ad Blocker and stopped my antivirus but to no avail.
Is there anyway to fix this issue?

FXML - Jar to .exe fail

I found several similar problems, but nowhere I found true and working solution for this problem, so I ask the world if somebody solved it this JavaFX problem?
I tried to make .exe from my JavaFX project (.jar file) with several converter softwares, but I get this error message from all (below) What could cause this, if the .jar file is working if I open it?
(My file hierarchy is something like this:)
-/lib/derby.jar (set as Native)
-/lib/derbyclient.jar (set as Native)
-/lib/derbynet.jar (set as Native)
-/lib/itextpdf-5.5.5.jar (set as Native)
-/lib/jfxtras-labs-samples-8.0-r4-SNAPSHOT-shadow.jar (set as Native)
-Utiokos.jar(with the main class) (set as Main)
The error message I get from the start of the .exe after converting:
java.lang.RuntimeException: Exception in Application start method
at com.sun.javafx.application.LauncherImpl.launchApplication1(Unknown Source)
at com.sun.javafx.application.LauncherImpl.lambda$launchApplication$147(Unknown Source)
at com.sun.javafx.application.LauncherImpl$$Lambda$1/15539988.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: javafx.fxml.LoadException:
file:/C:/Users/MrFireman/AppData/Local/Temp/e4jB580.tmp_dir1427146294/Utiokos.jar!/Utiokos/Foablak.fxml
at javafx.fxml.FXMLLoader.constructLoadException(Unknown Source)
at javafx.fxml.FXMLLoader.loadImpl(Unknown Source)
at javafx.fxml.FXMLLoader.loadImpl(Unknown Source)
at javafx.fxml.FXMLLoader.loadImpl(Unknown Source)
at javafx.fxml.FXMLLoader.loadImpl(Unknown Source)
at javafx.fxml.FXMLLoader.loadImpl(Unknown Source)
at javafx.fxml.FXMLLoader.loadImpl(Unknown Source)
at javafx.fxml.FXMLLoader.loadImpl(Unknown Source)
at javafx.fxml.FXMLLoader.load(Unknown Source)
at Utiokos.Utiokos.start(Utiokos.java:27)
at com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$153(Unknown Source)
at com.sun.javafx.application.LauncherImpl$$Lambda$50/20813951.run(Unknown Source)
at com.sun.javafx.application.PlatformImpl.lambda$runAndWait$166(Unknown Source)
at com.sun.javafx.application.PlatformImpl$$Lambda$46/2077920.run(Unknown Source)
at com.sun.javafx.application.PlatformImpl.lambda$null$164(Unknown Source)
at com.sun.javafx.application.PlatformImpl$$Lambda$48/29246076.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.javafx.application.PlatformImpl.lambda$runLater$165(Unknown Source)
at com.sun.javafx.application.PlatformImpl$$Lambda$47/17481965.run(Unknown Source)
at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(Unknown Source)
at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at com.sun.glass.ui.win.WinApplication.lambda$null$141(Unknown Source)
at com.sun.glass.ui.win.WinApplication$$Lambda$38/28810240.run(Unknown Source)
... 1 more
Caused by: java.lang.NullPointerException
at Utiokos.AdatbazisKapcsolat.aktivNev(AdatbazisKapcsolat.java:228)
at Utiokos.FoablakController.initialize(FoablakController.java:2547)
... 23 more
The solution was to not just add the /lib/xy.jar as a Native, but also as a classpath!
That way everything is working properly in the .exe! ;)

Novice: JNLP app won't run (Unable to Load Resources)

Forgive me, but I'm very new to this. I have a JNLP file on my work computer, and have access to work at home. I set up my VPN, and copy/pasted the JNLP file to my home computer. However, when I launch it (I upgraded to Java 7 using Windows 7 Home Premium), I get the Unable to Launch Application issue.
It shows Unable to Load Resources and then
com.sun.deploy.net.FailedDownloadException: Unable to load resource: http: //pbs-sj1/pbs/jnlp/tnp/msgr/alt.jnlp
at com.sun.deploy.net.DownloadEngine.actionDownload(Unknown Source)
at com.sun.deploy.net.DownloadEngine.downloadResource(Unknown Source)
at com.sun.deploy.cache.ResourceProviderImpl.getResource(Unknown Source)
at com.sun.deploy.cache.ResourceProviderImpl.getResource(Unknown Source)
at com.sun.javaws.Launcher.updateFinalLaunchDesc(Unknown Source)
at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
at com.sun.javaws.Launcher.launch(Unknown Source)
at com.sun.javaws.Main.launchApp(Unknown Source)
at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
at com.sun.javaws.Main.access$000(Unknown Source)
at com.sun.javaws.Main$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
This is under the wrapped section
java.net.UnknownHostException: pbs-sj1
at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at sun.net.NetworkClient.doConnect(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.openServer(Unknown Source)
at sun.net.www.http.HttpClient.<init>(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.http.HttpClient.New(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
at com.sun.deploy.net.HttpUtils.followRedirects(Unknown Source)
at com.sun.deploy.net.BasicHttpRequest.doRequest(Unknown Source)
at com.sun.deploy.net.BasicHttpRequest.doRequest(Unknown Source)
at com.sun.deploy.net.BasicHttpRequest.doGetRequest(Unknown Source)
at com.sun.deploy.net.DownloadEngine.actionDownload(Unknown Source)
at com.sun.deploy.net.DownloadEngine.downloadResource(Unknown Source)
at com.sun.deploy.cache.ResourceProviderImpl.getResource(Unknown Source)
at com.sun.deploy.cache.ResourceProviderImpl.getResource(Unknown Source)
at com.sun.javaws.Launcher.updateFinalLaunchDesc(Unknown Source)
at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
at com.sun.javaws.Launcher.launch(Unknown Source)
at com.sun.javaws.Main.launchApp(Unknown Source)
at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
at com.sun.javaws.Main.access$000(Unknown Source)
at com.sun.javaws.Main$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
I've researched online quite a bit but to be honest, most of it seems to be on a developer level. I'm just trying to get the JNLP file to launch.
Any ideas?
The error message is telling you that it can't figure out what host you are trying to reach:
java.net.UnknownHostException: pbs-sj1
Probably the easiest thing to do is to edit your hosts file on the box you have this .jnlp file and add:
127.0.0.1 pbs-sj1
Then make sure your actual .jnlp file location lines up with the rest of the path you specified (/pbs/jnlp/tnp/msgr/alt.jnlp). Here's a howto on editing your hosts file on Win7.
-OR-
Rather than mess with the Hosts file, just make use of a file URL to specify where to find the .JNLP file on Windows--e.g.,
file:///C:/Documents%20and%20Settings/your_login/alt.jnlp
(I'm assuming you know to paste/type either of these addresses into your Java-enabled browser's address bar)

using java applet in google app engine project

I have a question about using java applet on google app engine. I created 2 classes called InteractiveGraphView1 and SimpleApplet. Using an object of InteractiveGraphView1 inside SimpleApplet. Anyway, I'm using some external jars for these 2 classes. I created a jar for my project called "GraphApplet". Then I put this jar into WEB-INF/lib and also I add it into gae project as external jar. To be sure I also added external jars that I used in GraphApplet class into my gae project. I deployed the gae project and when I tried to run applet it gives me this error:
load: class SimpleApplet.class not found.
java.lang.ClassNotFoundException: SimpleApplet.class
at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Exception: java.lang.ClassNotFoundException: SimpleApplet.class
java.lang.RuntimeException: java.lang.NoClassDefFoundError: edu/uci/ics/jung/algorithms/layout/Layout
at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.NoClassDefFoundError: edu/uci/ics/jung/algorithms/layout/Layout
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)
at java.lang.Class.getConstructor0(Unknown Source)
at java.lang.Class.newInstance0(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at sun.plugin2.applet.Plugin2Manager$12.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.awt.EventQueue.access$400(Unknown Source)
at java.awt.EventQueue$2.run(Unknown Source)
at java.awt.EventQueue$2.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Caused by: java.lang.ClassNotFoundException: edu.uci.ics.jung.algorithms.layout.Layout
at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
... 20 more
Exception: java.lang.RuntimeException: java.lang.NoClassDefFoundError: edu/uci/ics/jung/algorithms/layout/Layout
What should I do?
P.S. I forgot to tell that I'm using JUNG library in my GraphApplet project. I also added this into google app engine project
Adding into HMTL
<html>
Hello App Engine
This is my page<br>
Below you see an applet<br>
<br>
<Applet Code="SimpleApplet.java" archive="graphic.jar" width=200 Height=200>
</Applet>
Applet is just a jar file that is downloaded by browser and executed on client side as applet.
It has nothing to do with server code. From the point of server it's just a static file. So you should not pout it inside WEB-INF/lib, where server libs reside. Just put it next to your html files.
For an applet referring to other jars see: How do I build an applet which needs an external jar, using ant?
Just put your applet.jar to root of WAR directory

Where is an applet trying to load a class from?

I'm trying to debug an applet that occasionally fails with the stack trace below (on the Java Console).
It looks like it's trying to load binaries and it's getting an HTTP REDIRECT which isn't legal (perhaps because of the applet sandbox?).
Is there any way to turn on verbose class loading output (or other debugging that might be useful) on the Java Console? If this were a standard Java application (as opposed to an applet), I would put "-verbose:class" on the command line and see what I get - but I don't know how to do that with an applet.
I don't have access to the source for the applet - so I can't add any kind of instrumentation to the code itself.
java.lang.SecurityException: illegal URL redirect
at com.sun.deploy.net.HttpUtils.followRedirects(Unknown Source)
at com.sun.deploy.net.BasicHttpRequest.doRequest(Unknown Source)
at com.sun.deploy.net.BasicHttpRequest.doGetRequestEX(Unknown Source)
at com.sun.deploy.net.DownloadEngine.isUpdateAvailable(Unknown Source)
at com.sun.deploy.cache.DeployCacheHandler.get(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown
Source)
at sun.net.www.protocol.http.HttpURLConnection.connect(Unknown Source)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source)
at sun.plugin.PluginURLJarFileCallBack.downloadJAR(Unknown Source)
at sun.plugin.PluginURLJarFileCallBack.access$000(Unknown Source)
at sun.plugin.PluginURLJarFileCallBack$2.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.plugin.PluginURLJarFileCallBack.retrieve(Unknown Source)
at sun.net.www.protocol.jar.URLJarFile.retrieve(Unknown Source)
at sun.net.www.protocol.jar.URLJarFile.getJarFile(Unknown Source)
at sun.net.www.protocol.jar.JarFileFactory.get(Unknown Source)
at sun.net.www.protocol.jar.JarURLConnection.connect(Unknown Source)
at sun.plugin.net.protocol.jar.CachedJarURLConnection.connect(Unknown
Source)
at sun.plugin.net.protocol.jar.CachedJarURLConnection.getJarFileInternal(Unknown
Source)
at sun.plugin.net.protocol.jar.CachedJarURLConnection.getJarFile(Unknown
Source)
at com.sun.deploy.security.DeployURLClassPath$JarLoader.getJarFile(Unknown
Source)
at com.sun.deploy.security.DeployURLClassPath$JarLoader.access$800(Unknown
Source)
at com.sun.deploy.security.DeployURLClassPath$JarLoader$1.run(Unknown
Source)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.deploy.security.DeployURLClassPath$JarLoader.ensureOpen(Unknown
Source)
at com.sun.deploy.security.DeployURLClassPath$JarLoader.(Unknown
Source)
at com.sun.deploy.security.DeployURLClassPath$3.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.deploy.security.DeployURLClassPath.getLoader(Unknown Source)
at com.sun.deploy.security.DeployURLClassPath.getLoader(Unknown Source)
at com.sun.deploy.security.DeployURLClassPath.getResource(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader$2.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.plugin2.applet.Plugin2ClassLoader.findClassHelper(Unknown Source)
at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown
Source)
at java.lang.Thread.run(Unknown Source) Exception: java.lang.SecurityException: illegal URL redirect
You can add the -verbose:class to the command line of java by going to Control Panel, Java, Java, View, then editing the 'runtime parameters'.
To make your applet get sources NOT FROM its native host you have to sign it;
Here are some helpful tutorials
Report that helps

Categories

Resources