I tried some EJB3 applications using NetBeans 6 and GlassFish V2. jdk 1.6 was initially being installed to support NetBeans. On one of the machines when I tried to run the programs those were throwing a MalformedURLException. But when I tried the same project on different machines no Exception was thrown, which implied that the problem was not with the source code. I tried providing the absolute path but still the problem was there.
But when I installed jdk 1.5 and then installed NetBeans 6, and tried to run the same project the Exception was not thrown and the program was running fine.
Do you have any idea of why this happened?
"Simplicity is the ultimate sophistication..." ~Leonardo da Vinci~
This is what I got when trying to build the project.
java.net.MalformedURLException: no protocol: /ListNews at java.net.URL.<init>(URL.java:567) at java.net.URL.<init>(URL.java:464) at java.net.URL.<init>(URL.java:413) at org.netbeans.modules.ant.browsetask.NbBrowse.execute(NbBrowse.java:75) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288) at sun.reflect.GeneratedMethodAccessor208.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:105) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:357) at org.apache.tools.ant.Target.performTasks(Target.java:385) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1329) at org.apache.tools.ant.Project.executeTarget(Project.java:1298) at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41) at org.apache.tools.ant.Project.executeTargets(Project.java:1181) at org.apache.tools.ant.module.bridge.impl.BridgeImpl.run(BridgeImpl.java:277) at org.apache.tools.ant.module.run.TargetExecutor.run(TargetExecutor.java:460) at org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:151) BUILD FAILED (total time: 0 seconds)
I don't think it has anything to do with the source code because I managed to run it without any failure in several other machines.