Mirror von
https://github.com/PaperMC/Velocity.git
synchronisiert 2024-11-17 05:20:14 +01:00
Fix warning when using a Unix domain socket to connect to a server
Dieser Commit ist enthalten in:
Ursprung
47a1332514
Commit
11928f3737
@ -182,14 +182,16 @@ public final class ConnectionManager {
|
||||
public Bootstrap createWorker(@Nullable EventLoopGroup group, SocketAddress target) {
|
||||
Bootstrap bootstrap = new Bootstrap()
|
||||
.channelFactory(this.transportType.getClientChannelFactory(target))
|
||||
.option(ChannelOption.TCP_NODELAY, true)
|
||||
.option(ChannelOption.CONNECT_TIMEOUT_MILLIS,
|
||||
this.server.configuration().getConnectTimeout())
|
||||
.group(group == null ? this.workerGroup : group)
|
||||
.resolver(this.resolver.asGroup());
|
||||
if (target instanceof InetSocketAddress) {
|
||||
bootstrap.option(ChannelOption.TCP_NODELAY, true);
|
||||
if (transportType == TransportType.EPOLL && server.configuration().useTcpFastOpen()) {
|
||||
bootstrap.option(EpollChannelOption.TCP_FASTOPEN_CONNECT, true);
|
||||
}
|
||||
}
|
||||
return bootstrap;
|
||||
}
|
||||
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren