0

I have a short question. I want to create a XMPP server with Apache Vysper. But when I try to create a server:

XMPPServer server = new XMPPServer("myserver.com");

I get a ClassNotFoundException on this line, although the class is imported correctly.

Can Somebody help me out?

Thanks :)

Here the Exception:

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/vysper/xmpp/server/XMPPServer
    at de.seba.vyspertest.App.main(App.java:13)
Caused by: java.lang.ClassNotFoundException: org.apache.vysper.xmpp.server.XMPPServer
    at java.net.URLClassLoader.findClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    ... 1 more
  • It could be helpful to see the relevant part of your error trace. – ACEG Aug 03 '16 at 14:00
  • I only have this one line in my main method... – Sebastian85 Aug 03 '16 at 14:14
  • I meant your output, where the ClassNotFoundException appears. It would be helpful to see the first 10-15 lines of this. – ACEG Aug 03 '16 at 14:16
  • Is your classpath set up correctly? (do you have the Vysper jar on the classpath?) – ACEG Aug 03 '16 at 14:40
  • I added the vysper-core dependency in my pom.xml file. And I can find XMPPServer.class in the Vysper-core-0.7.jar within the Maven Dependencies directory. It is defintively there... – Sebastian85 Aug 04 '16 at 07:18
  • Hmmm... seems to be a very weird bug in version 0.7 ... if I use version 0.6 it works... very strange :D – Sebastian85 Aug 04 '16 at 07:52
  • :-) Just brainstorming here, but do you have the correct version in the pom.xml dependency? You could also double check this here: http://mvnrepository.com/search?q=apache+vysper – ACEG Aug 04 '16 at 08:47
  • yes, I got it from there ;) – Sebastian85 Aug 04 '16 at 09:30

0 Answers0