Skip to content

Commit a31f49f

Browse files
Revert "Merge branch 'dev/3.0.0' into ping-passthrough-dev"
This reverts commit 4a32358, reversing changes made to 2c41819.
1 parent 4a32358 commit a31f49f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+200
-685
lines changed

.github/workflows/gradle.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ jobs:
1414
persist-credentials: false
1515
- name: Set up Gradle
1616
uses: gradle/actions/setup-gradle@v4
17-
- name: Set up JDK 21
17+
- name: Set up JDK 17
1818
uses: actions/setup-java@v4
1919
with:
20-
java-version: 21
21-
distribution: 'zulu'
20+
java-version: 17
21+
distribution: 'temurin'
2222
- name: Build with Gradle
2323
run: ./gradlew build

api/src/main/java/com/velocitypowered/api/command/CommandManager.java

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,8 @@
77

88
package com.velocitypowered.api.command;
99

10-
import com.mojang.brigadier.suggestion.Suggestions;
1110
import com.velocitypowered.api.event.command.CommandExecuteEvent;
1211
import java.util.Collection;
13-
import java.util.List;
1412
import java.util.concurrent.CompletableFuture;
1513
import java.util.function.Predicate;
1614
import org.checkerframework.checker.nullness.qual.Nullable;
@@ -118,27 +116,6 @@ default void register(String alias, Command command, String... otherAliases) {
118116
*/
119117
CompletableFuture<Boolean> executeImmediatelyAsync(CommandSource source, String cmdLine);
120118

121-
/**
122-
* Asynchronously collects suggestions to fill in the given command {@code cmdLine}.
123-
* Returns only the raw completion suggestions without tooltips.
124-
*
125-
* @param source the source to execute the command for
126-
* @param cmdLine the partially completed command
127-
* @return a {@link CompletableFuture} eventually completed with a {@link List}, possibly empty
128-
*/
129-
CompletableFuture<List<String>> offerSuggestions(CommandSource source, String cmdLine);
130-
131-
/**
132-
* Asynchronously collects suggestions to fill in the given command {@code cmdLine}.
133-
* Returns the brigadier {@link Suggestions} with tooltips for each result.
134-
*
135-
* @param source the source to execute the command for
136-
* @param cmdLine the partially completed command
137-
* @return a {@link CompletableFuture} eventually completed with {@link Suggestions}, possibly
138-
* empty
139-
*/
140-
CompletableFuture<Suggestions> offerBrigadierSuggestions(CommandSource source, String cmdLine);
141-
142119
/**
143120
* Returns an immutable collection of the case-insensitive aliases registered
144121
* on this manager.

api/src/main/java/com/velocitypowered/api/network/ProtocolVersion.java

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -90,9 +90,7 @@ public boolean isSupported() {
9090
MINECRAFT_1_21(767, "1.21", "1.21.1"),
9191
MINECRAFT_1_21_2(768, "1.21.2", "1.21.3"),
9292
MINECRAFT_1_21_4(769, "1.21.4"),
93-
MINECRAFT_1_21_5(770, "1.21.5"),
94-
MINECRAFT_1_21_6(771, "1.21.6"),
95-
MINECRAFT_1_21_7(772, "1.21.7", "1.21.8");
93+
MINECRAFT_1_21_5(770, /*1073742067,*/ "1.21.5");
9694

9795
private static final int SNAPSHOT_BIT = 30;
9896

build-logic/src/main/kotlin/velocity-init-manifest.gradle.kts

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,8 @@ import org.gradle.jvm.tasks.Jar
22
import org.gradle.kotlin.dsl.withType
33
import java.io.ByteArrayOutputStream
44

5-
// This interface is needed as a workaround to get an instance of ExecOperations
6-
interface Injected {
7-
@get:Inject
8-
val execOps: ExecOperations
9-
}
10-
115
val currentShortRevision = ByteArrayOutputStream().use {
12-
val execOps = objects.newInstance<Injected>().execOps
13-
execOps.exec {
6+
exec {
147
executable = "git"
158
args = listOf("rev-parse", "HEAD")
169
standardOutput = it

build-logic/src/main/kotlin/velocity-publish.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ extensions.configure<PublishingExtension> {
88
maven {
99
credentials(PasswordCredentials::class.java)
1010

11-
name = if (version.toString().endsWith("SNAPSHOT")) "paperSnapshots" else "paper" // "paper" is seemingly not defined
11+
name = "paper"
1212
val base = "https://repo.papermc.io/repository/maven"
1313
val releasesRepoUrl = "$base-releases/"
1414
val snapshotsRepoUrl = "$base-snapshots/"

build.gradle.kts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,11 @@ subprojects {
2020
testImplementation(rootProject.libs.junit)
2121
}
2222

23-
testing.suites.named<JvmTestSuite>("test") {
24-
useJUnitJupiter()
25-
targets.all {
26-
testTask.configure {
27-
reports.junitXml.required = true
23+
tasks {
24+
test {
25+
useJUnitPlatform()
26+
reports {
27+
junitXml.required.set(true)
2828
}
2929
}
3030
}

gradle/libs.versions.toml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,19 @@
22
configurate3 = "3.7.3"
33
configurate4 = "4.1.2"
44
flare = "2.0.1"
5-
log4j = "2.24.3"
6-
netty = "4.2.4.Final"
5+
log4j = "2.24.1"
6+
netty = "4.2.0.Final"
77

88
[plugins]
9-
fill = "io.papermc.fill.gradle:1.0.3"
109
indra-publishing = "net.kyori.indra.publishing:2.0.6"
11-
shadow = "com.gradleup.shadow:8.3.6"
10+
shadow = "io.github.goooler.shadow:8.1.5"
1211
spotless = "com.diffplug.spotless:6.25.0"
1312

1413
[libraries]
15-
adventure-bom = "net.kyori:adventure-bom:4.24.0"
16-
adventure-text-serializer-json-legacy-impl = "net.kyori:adventure-text-serializer-json-legacy-impl:4.24.0"
14+
adventure-bom = "net.kyori:adventure-bom:4.19.0"
15+
adventure-text-serializer-json-legacy-impl = "net.kyori:adventure-text-serializer-json-legacy-impl:4.19.0"
1716
adventure-facet = "net.kyori:adventure-platform-facet:4.3.4"
18-
asm = "org.ow2.asm:asm:9.8"
17+
asm = "org.ow2.asm:asm:9.7.1"
1918
auto-service = "com.google.auto.service:auto-service:1.0.1"
2019
auto-service-annotations = "com.google.auto.service:auto-service-annotations:1.0.1"
2120
brigadier = "com.velocitypowered:velocity-brigadier:1.0.0-SNAPSHOT"
@@ -34,7 +33,7 @@ disruptor = "com.lmax:disruptor:4.0.0"
3433
fastutil = "it.unimi.dsi:fastutil:8.5.15"
3534
flare-core = { module = "space.vectrix.flare:flare", version.ref = "flare" }
3635
flare-fastutil = { module = "space.vectrix.flare:flare-fastutil", version.ref = "flare" }
37-
jline = "org.jline:jline-terminal-jansi:3.30.2"
36+
jline = "org.jline:jline-terminal-jansi:3.27.1"
3837
jopt = "net.sf.jopt-simple:jopt-simple:5.0.4"
3938
junit = "org.junit.jupiter:junit-jupiter:5.10.2"
4039
jspecify = "org.jspecify:jspecify:0.3.0"
@@ -57,7 +56,7 @@ netty-transport-native-epoll = { module = "io.netty:netty-transport-native-epoll
5756
netty-transport-native-kqueue = { module = "io.netty:netty-transport-native-kqueue", version.ref = "netty" }
5857
netty-transport-native-iouring = { module = "io.netty:netty-transport-native-io_uring", version.ref = "netty" }
5958
nightconfig = "com.electronwill.night-config:toml:3.6.7"
60-
slf4j = "org.slf4j:slf4j-api:2.0.17"
59+
slf4j = "org.slf4j:slf4j-api:2.0.12"
6160
snakeyaml = "org.yaml:snakeyaml:1.33"
6261
spotbugs-annotations = "com.github.spotbugs:spotbugs-annotations:4.7.3"
6362
terminalconsoleappender = "net.minecrell:terminalconsoleappender:1.3.0"

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.2-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

proxy/build.gradle.kts

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
import com.github.jengelman.gradle.plugins.shadow.transformers.Log4j2PluginsCacheFileTransformer
2-
import io.papermc.fill.model.BuildChannel
32

43
plugins {
54
application
65
id("velocity-init-manifest")
76
alias(libs.plugins.shadow)
8-
alias(libs.plugins.fill)
97
}
108

119
application {
@@ -102,32 +100,13 @@ tasks {
102100
runShadow {
103101
workingDir = file("run").also(File::mkdirs)
104102
standardInput = System.`in`
105-
jvmArgs("-Dvelocity.packet-decode-logging=true")
106103
}
107104
named<JavaExec>("run") {
108105
workingDir = file("run").also(File::mkdirs)
109106
standardInput = System.`in` // Doesn't work?
110107
}
111108
}
112109

113-
val projectVersion = version as String
114-
fill {
115-
project("velocity")
116-
117-
build {
118-
channel = BuildChannel.STABLE
119-
versionFamily("3.0.0")
120-
version(projectVersion)
121-
122-
downloads {
123-
register("server:default") {
124-
file = tasks.shadowJar.flatMap { it.archiveFile }
125-
nameResolver.set { project, _, version, build -> "$project-$version-$build.jar" }
126-
}
127-
}
128-
}
129-
}
130-
131110
dependencies {
132111
implementation(project(":velocity-api"))
133112
implementation(project(":velocity-native"))

proxy/src/main/java/com/velocitypowered/proxy/Velocity.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,11 +47,6 @@ public class Velocity {
4747
System.setProperty("io.netty.native.workdir", System.getProperty("velocity.natives-tmpdir"));
4848
}
4949

50-
// Restore allocator used before Netty 4.2 due to oom issues with the adaptive allocator
51-
if (System.getProperty("io.netty.allocator.type") == null) {
52-
System.setProperty("io.netty.allocator.type", "pooled");
53-
}
54-
5550
// Disable the resource leak detector by default as it reduces performance. Allow the user to
5651
// override this if desired.
5752
if (!VelocityProperties.hasProperty("io.netty.leakDetection.level")) {

0 commit comments

Comments
 (0)