Hi, I tried using spark in a maven project with eclipse and got the following error when running the app:
(using lubuntu 17.04 with eclipse oxygen and openjdk8)
Exception in thread "Thread-0" java.lang.NoClassDefFoundError: org/eclipse/jetty/server/Handler
at spark.embeddedserver.EmbeddedServers.initialize(EmbeddedServers.java:40)
at spark.Service.lambda$init$2(Service.java:491)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.ClassNotFoundException: org.eclipse.jetty.server.Handler
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:335)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 3 more
This does not happen if I use spark 2.5 or if I manually add the eclipse Jetty dependency.
My pom.xml:
Hi, I tried using spark in a maven project with eclipse and got the following error when running the app: (using lubuntu 17.04 with eclipse oxygen and openjdk8)
This does not happen if I use spark 2.5 or if I manually add the eclipse Jetty dependency. My pom.xml:
The main class is just the example copied frm the sparkjava website.
Tell me if I can provide more info!