Skip to content

Commit

Permalink
Fix issues with Redis
Browse files Browse the repository at this point in the history
  • Loading branch information
quantiom committed Sep 30, 2022
1 parent 59fd58a commit 26770ec
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 9 deletions.
4 changes: 0 additions & 4 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -341,10 +341,6 @@
<pattern>net.kyori.adventure</pattern>
<shadedPattern>me.quantiom.advancedvanish.shaded.adventure</shadedPattern>
</relocation>
<relocation>
<pattern>redis.clients</pattern>
<pattern>me.quantiom.advancedvanish.shaded.redis</pattern>
</relocation>
<relocation>
<pattern>net.byteflux.libby</pattern>
<shadedPattern>me.quantiom.advancedvanish.shaded.libby</shadedPattern>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,16 @@ public DependencyManager(AdvancedVanishPlugin plugin) {
}

private Library getLibrary(String groupId, String artifactId, String version, String pattern, String relocatePattern) {
return Library.builder()
Library.Builder builder = Library.builder()
.groupId(groupId)
.artifactId(artifactId)
.version(version)
.relocate(pattern, relocatePattern)
.build();
.version(version);

if (!relocatePattern.isEmpty()) {
builder.relocate(pattern, relocatePattern);
}

return builder.build();
}

public void loadDependencies() {
Expand All @@ -41,7 +45,9 @@ public void loadDependencies() {
this.getLibrary("org{}jetbrains{}exposed", "exposed-dao", "0.39.2", "org{}jetbrains{}exposed", "me{}quantiom{}advancedvanish{}shaded{}exposed"),
this.getLibrary("org{}jetbrains{}exposed", "exposed-jdbc", "0.39.2", "org{}jetbrains{}exposed", "me{}quantiom{}advancedvanish{}shaded{}exposed"),
// redis
this.getLibrary("redis{}clients", "jedis", "4.2.0", "redis{}clients", "me{}quantiom{}advancedvanish{}shaded{}redis"),
this.getLibrary("redis{}clients", "jedis", "4.2.0", "", ""),
this.getLibrary("org{}apache{}commons", "commons-pool2", "2.11.1", "", ""),
this.getLibrary("org{}json", "json", "20211205", "", ""),
// adventure
this.getLibrary("net{}kyori", "adventure-api", "4.11.0", "net{}kyori{}adventure", "me{}quantiom{}advancedvanish{}shaded{}adventure"),
this.getLibrary("net{}kyori", "adventure-platform-api", "4.1.2", "net{}kyori{}adventure", "me{}quantiom{}advancedvanish{}shaded{}adventure"),
Expand Down

0 comments on commit 26770ec

Please sign in to comment.