HomeJavaModsJExDependency | Keep Plugins small | 1.8-26.1.2
JExDependency | Keep Plugins small | 1.8-26.1.2
ModsJava

JExDependency | Keep Plugins small | 1.8-26.1.2

JExDependency Ship lightweight Paper & Spigot plugins. Let your server download the libraries. Runtime dependency resolution, downloading, relocation, and…

⬇ Download on Spigot
JExDependency
Ship lightweight Paper & Spigot plugins. Let your server download the libraries.

Runtime dependency resolution, downloading, relocation, and classpath injection — purpose-built for modern Minecraft servers.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━​

Why JExDependency?

Minecraft plugin jars keep getting larger. Hibernate, Jackson, Caffeine, JDBC drivers — shading them all bloats your jar to 20 MB+ and guarantees classpath collisions the moment another plugin ships a different version.

JExDependency flips that model. Declare dependencies in a tiny YAML file, ship a 50 KB plugin, and let the library download, verify, (optionally) relocate, and inject the JARs at runtime — on every flavour of Paper and Spigot, transparently.

Think of it as Paper's built-in libraries block, but portable, relocation-aware, and working on Spigot too.

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━​

✨ Features


‍ For Plugin Developers

Add the dependency in Gradle:

Code (Kotlin):
repositories {
    maven ( "https://repo.jexcellence.de/releases" )
}

dependencies {
    implementation ( "de.jexcellence.dependency:jexdependency:2.0.0" )
}
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━​

Replace your ShadowJar relocate blocks

If your build.gradle.kts currently looks like this:

Code (Kotlin):
tasks. named <com. github. jengelman. gradle. plugins. shadow. tasks. ShadowJar > ( "shadowJar" ) {
    archiveBaseName. set ( "RDQ" )
    archiveVersion. set (rdqVersion )
    archiveClassifier. set ( "Free" )

    relocate ( "com.github.benmanes", "de.jexcellence.remapped.com.github.benmanes" )
    relocate ( "me.devnatan.inventoryframework", "de.jexcellence.remapped.me.devnatan.inventoryframework" )
    relocate ( "com.tcoded", "de.jexcellence.remapped.com.tcoded" )
    relocate ( "com.cryptomorin.xseries", "de.jexcellence.remapped.com.cryptomorin.xseries" )

    configurations = listOf (project. configurations. getByName ( "runtimeClasspath" ) )
    mergeServiceFiles ( )
}
…you can throw it all away. No shading. No relocate block. No 20 MB fat jar.

With JExDependency, the entire setup becomes:

1) build.gradle.kts — no shadow plugin required:

Code (Kotlin):
dependencies {
    implementation ( "de.jexcellence.dependency:jexdependency:2.0.0" )

    // These stay as compileOnly — they're downloaded at runtime, not shaded.
    compileOnly ( "com.github.ben-manes.caffeine:caffeine:3.2.2" )
    compileOnly ( "me.devnatan:inventory-framework-paper:3.3.0" )
    compileOnly ( "com.tcoded:FoliaLib:0.5.1" )
    compileOnly ( "com.github.cryptomorin:XSeries:11.3.0" )
}
2) src/main/resources/dependency/dependencies.yml:

Code (YAML):
dependencies :
 - "com.github.ben-manes.caffeine:caffeine:3.2.2"
  - "me.devnatan:inventory-framework-paper:3.3.0"
  - "com.tcoded:FoliaLib:0.5.1"
  - "com.github.cryptomorin:XSeries:11.3.0"
3) Bootstrap with relocation forced on:

Code (Java):
public final class RDQ extends JavaPlugin {
    @Override
    public void onLoad ( ) {
        // Equivalent to your old shadow relocate(...) block, at runtime.
        JEDependency. initializeWithRemapping ( this, RDQ. class ) ;
    }
}
4) (Optional) Control the relocation prefix via a JVM flag — no rebuild needed:

Code (Text):
-Djedependency.relocations.prefix=de.jexcellence.remapped
Result: a 50 KB plugin jar instead of 20 MB, a clean Git diff instead of a shaded-classes explosion, and per-server-operator control over relocations.

Declare your runtime libraries in src/main/resources/dependency/dependencies.yml:

Code (YAML):
dependencies :
 - "com.github.ben-manes.caffeine:caffeine:3.2.2"
  - "com.fasterxml.jackson.core:jackson-databind:2.18.2"
  - "com.mysql:mysql-connector-j:9.2.0"
Bootstrap inside your plugin:

Code (Java):
public final class ExamplePlugin extends JavaPlugin {
    @Override
    public void onLoad ( ) {
        JEDependency. initialize ( this, ExamplePlugin. class ) ;
    }
}
That's it. Libraries land under plugins/ExamplePlugin/libraries/ and are injected into your plugin's classloader before onEnable() fires.

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━​

⚙️ Configuration (server operators)

All options are JVM system properties — no config file to edit.


━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━​

Security


━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━​

Support


If JExDependency saves you a shaded jar today, consider leaving a ⭐ on GitHub and a review here on SpigotMC — it genuinely helps!
Quick facts

Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.

JExDependency | Keep Plugins small | 1.8-26.1.2 is a free Minecraft Java mod. Compatible with Minecraft 1.8, 1.9, 1.10, 1.11 and newer. Downloaded 23 times (via Spigot). Download it and open it directly in the game.

Explore more