Mirror von
https://github.com/PaperMC/Velocity.git
synchronisiert 2024-12-24 15:20:35 +01:00
Reduce erroneous DNS lookups for Velocity in Kubernetes.
Dieser Commit ist enthalten in:
Ursprung
961e3ece27
Commit
8517d58673
@ -11,8 +11,8 @@ import io.netty.channel.ChannelFutureListener;
|
||||
import io.netty.channel.ChannelOption;
|
||||
import io.netty.channel.EventLoopGroup;
|
||||
import io.netty.channel.WriteBufferWaterMark;
|
||||
import io.netty.resolver.dns.DefaultDnsServerAddressStreamProvider;
|
||||
import io.netty.resolver.dns.DnsAddressResolverGroup;
|
||||
import io.netty.resolver.dns.DnsNameResolverBuilder;
|
||||
import java.net.InetSocketAddress;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
@ -48,8 +48,13 @@ public final class ConnectionManager {
|
||||
this.workerGroup = this.transportType.createEventLoopGroup(TransportType.Type.WORKER);
|
||||
this.serverChannelInitializer = new ServerChannelInitializerHolder(
|
||||
new ServerChannelInitializer(this.server));
|
||||
this.resolverGroup = new DnsAddressResolverGroup(this.transportType.datagramChannelClass,
|
||||
DefaultDnsServerAddressStreamProvider.INSTANCE);
|
||||
this.resolverGroup = new DnsAddressResolverGroup(
|
||||
new DnsNameResolverBuilder()
|
||||
.channelType(this.transportType.datagramChannelClass)
|
||||
.ttl(300, 86400)
|
||||
.negativeTtl(15)
|
||||
.ndots(1)
|
||||
);
|
||||
}
|
||||
|
||||
public void logChannelInformation() {
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren