My plugin not working on certain server

Discussion in 'Spigot Plugin Development' started by blohod, Jun 29, 2015.

  1. My plugin, GrassSeed is not working on my friends server, however it works on my dev server and other servers.

    My friends server log
    Code (Text):
    [18:45:05] [Server thread/INFO]: Starting minecraft server version 1.8.7
    [18:45:05] [Server thread/INFO]: Loading properties
    [18:45:05] [Server thread/INFO]: Default game type: SURVIVAL
    [18:45:05] [Server thread/INFO]: This server is running CraftBukkit version git-Spigot-d2856ae-8f0f4ed (MC: 1.8.7) (Implementing API version 1.8.7-R0.1-SNAPSHOT)
    [18:45:06] [Server thread/INFO]: Debug logging is disabled
    [18:45:06] [Server thread/INFO]: Server Ping Player Sample Count: 12
    [18:45:06] [Server thread/INFO]: Using 4 threads for Netty based IO
    [18:45:06] [Server thread/INFO]: Generating keypair
    [18:45:06] [Server thread/INFO]: Starting Minecraft server on 104.128.52.163:26085
    [18:45:06] [Server thread/INFO]: Using epoll channel type
    [18:45:06] [Server thread/WARN]: Plugin `Ram_Monitor v1' uses the space-character (0x20) in its name `Ram Monitor' - this is discouraged
    [18:45:06] [Server thread/INFO]: Set PluginClassLoader as parallel capable
    [18:45:06] [Server thread/ERROR]: Could not load 'plugins/GrassSeed.jar' in folder 'plugins'
    org.bukkit.plugin.InvalidPluginException: java.lang.UnsupportedClassVersionError: com/blohod/GrassSeed/Main : Unsupported major.minor version 52.0
    at org.bukkit.plugin.java.JavaPluginLoader.loadPlugin(JavaPluginLoader.java:135) ~[spigot.jar:git-Spigot-d2856ae-8f0f4ed]
    at org.bukkit.plugin.SimplePluginManager.loadPlugin(SimplePluginManager.java:329) ~[spigot.jar:git-Spigot-d2856ae-8f0f4ed]
    at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:251) [spigot.jar:git-Spigot-d2856ae-8f0f4ed]
    at org.bukkit.craftbukkit.v1_8_R3.CraftServer.loadPlugins(CraftServer.java:291) [spigot.jar:git-Spigot-d2856ae-8f0f4ed]
    at net.minecraft.server.v1_8_R3.DedicatedServer.init(DedicatedServer.java:198) [spigot.jar:git-Spigot-d2856ae-8f0f4ed]
    at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:528) [spigot.jar:git-Spigot-d2856ae-8f0f4ed]
    at java.lang.Thread.run(Thread.java:722) [?:1.7.0_03]
    Caused by: java.lang.UnsupportedClassVersionError: com/blohod/GrassSeed/Main : Unsupported major.minor version 52.0
    at java.lang.ClassLoader.defineClass1(Native Method) ~[?:1.7.0_03]
    at java.lang.ClassLoader.defineClass(ClassLoader.java:791) ~[?:1.7.0_03]
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) ~[?:1.7.0_03]
    at java.net.URLClassLoader.defineClass(URLClassLoader.java:449) ~[?:1.7.0_03]
    at java.net.URLClassLoader.access$100(URLClassLoader.java:71) ~[?:1.7.0_03]
    at java.net.URLClassLoader$1.run(URLClassLoader.java:361) ~[?:1.7.0_03]
    at java.net.URLClassLoader$1.run(URLClassLoader.java:355) ~[?:1.7.0_03]
    at java.security.AccessController.doPrivileged(Native Method) ~[?:1.7.0_03]
    at java.net.URLClassLoader.findClass(URLClassLoader.java:354) ~[?:1.7.0_03]
    at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:101) ~[spigot.jar:git-Spigot-d2856ae-8f0f4ed]
    at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:86) ~[spigot.jar:git-Spigot-d2856ae-8f0f4ed]
    at java.lang.ClassLoader.loadClass(ClassLoader.java:423) ~[?:1.7.0_03]
    at java.lang.ClassLoader.loadClass(ClassLoader.java:356) ~[?:1.7.0_03]
    at java.lang.Class.forName0(Native Method) ~[?:1.7.0_03]
    at java.lang.Class.forName(Class.java:264) ~[?:1.7.0_03]
     
    my, working server log
    Code (Text):
    [09:51:34] [Server thread/INFO]: Starting minecraft server version 1.8.7
    [09:51:34] [Server thread/INFO]: Loading properties
    [09:51:34] [Server thread/INFO]: Default game type: SURVIVAL
    [09:51:34] [Server thread/INFO]: This server is running CraftBukkit version git-Spigot-44c59bf-8f0f4ed (MC: 1.8.7) (Implementing API version 1.8.7-R0.1-SNAPSHOT)
    [09:51:34] [Server thread/INFO]: Debug logging is disabled
    [09:51:34] [Server thread/INFO]: Server Ping Player Sample Count: 12
    [09:51:34] [Server thread/INFO]: Using 4 threads for Netty based IO
    [09:51:34] [Server thread/INFO]: Generating keypair
    [09:51:35] [Server thread/INFO]: Starting Minecraft server on *:25565
    [09:51:35] [Server thread/INFO]: Using default channel type
    [09:51:35] [Server thread/INFO]: Set PluginClassLoader as parallel capable
    [09:51:35] [Server thread/INFO]: [GrassSeed] Loading GrassSeed v1.0
    My dev server is same version as my api, but my friends server implements the same api version, I don't know why it is not working, please help.
     
  2. Your friend needs to update to Java 8. Others will show up here telling you to compile for Java 7. I dont recommend that since Java 7 is at EOL (end of life) already. Let it die, everyone needs to update to 8. ;)

     
    • Useful Useful x 1
  3. ok, thanks, only problem is It is hosted by a server host, so I will have to bug them about it
     
  4. How would I compile for java 7, the hosts are not going to update soon