You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
HI
I am using below command to start gitblit.
java -jar gitblit-1.8.0.jar --baseFolder data.
But this is failing with below error.
java.lang.ClassCastException: java.base/jdk.internal.loader.ClassLoaders$AppClassLoader cannot be cast to java.base/java.net.URLClassLoader
at org.moxie.MxLauncher.addJarFile(MxLauncher.java:170)
at org.moxie.MxLauncher.main(MxLauncher.java:117)
java.lang.ClassCastException: java.base/jdk.internal.loader.ClassLoaders$AppClassLoader cannot be cast to java.base/java.net.URLClassLoader
at org.moxie.MxLauncher.addJarFile(MxLauncher.java:170)
at org.moxie.MxLauncher.main(MxLauncher.java:117)
java.lang.ClassCastException: java.base/jdk.internal.loader.ClassLoaders$AppClassLoader cannot be cast to java.base/java.net.URLClassLoader
at org.moxie.MxLauncher.addJarFile(MxLauncher.java:170)
at org.moxie.MxLauncher.main(MxLauncher.java:117)
Exception in thread "main" java.lang.NoClassDefFoundError: org/kohsuke/args4j/CmdLineException
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Unknown Source)
at org.moxie.MxLauncher.main(MxLauncher.java:127)
Caused by: java.lang.ClassNotFoundException: org.kohsuke.args4j.CmdLineException
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(Unknown Source)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(Unknown Source)
at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
... 3 more
I have java 10 installed on my windows desktop. I have set the path and classpath variable in environment variables.
The text was updated successfully, but these errors were encountered:
I'm not sure where you got the gitblit-1.8.0.jar file, but that jar is just part of a whole distribution package, like GitblitGO, to be used together. Information about the Gitblit GO package is here at the gitblit.com site.
Even when you get GitblitGO and set it up correctly as per instruction, gitblit only supports Java 7 and 8 runtimes. For Java 9+, you'll get exceptions similar to the above.
A workaround to make it run with Java 9+ is to modify the gitblit.cmd file and change it from:
@java -jar gitblit.jar --baseFolder data %*
to
@java -cp gitblit.jar;"%CD%\ext\*" com.gitblit.GitBlitServer --baseFolder data %*
and then start up the Gitblit server by executing the modified gitblit.cmd file.
HI
I am using below command to start gitblit.
java -jar gitblit-1.8.0.jar --baseFolder data.
But this is failing with below error.
java.lang.ClassCastException: java.base/jdk.internal.loader.ClassLoaders$AppClassLoader cannot be cast to java.base/java.net.URLClassLoader
at org.moxie.MxLauncher.addJarFile(MxLauncher.java:170)
at org.moxie.MxLauncher.main(MxLauncher.java:117)
java.lang.ClassCastException: java.base/jdk.internal.loader.ClassLoaders$AppClassLoader cannot be cast to java.base/java.net.URLClassLoader
at org.moxie.MxLauncher.addJarFile(MxLauncher.java:170)
at org.moxie.MxLauncher.main(MxLauncher.java:117)
java.lang.ClassCastException: java.base/jdk.internal.loader.ClassLoaders$AppClassLoader cannot be cast to java.base/java.net.URLClassLoader
at org.moxie.MxLauncher.addJarFile(MxLauncher.java:170)
at org.moxie.MxLauncher.main(MxLauncher.java:117)
Exception in thread "main" java.lang.NoClassDefFoundError: org/kohsuke/args4j/CmdLineException
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Unknown Source)
at org.moxie.MxLauncher.main(MxLauncher.java:127)
Caused by: java.lang.ClassNotFoundException: org.kohsuke.args4j.CmdLineException
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(Unknown Source)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(Unknown Source)
at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
... 3 more
I have java 10 installed on my windows desktop. I have set the path and classpath variable in environment variables.
The text was updated successfully, but these errors were encountered: