13
0
geforkt von Mirrors/Velocity

Silence TCP_FASTOPEN warnings when not using epoll and fast open enabled

Dieser Commit ist enthalten in:
Andrew Steinborn 2019-08-06 06:43:27 -04:00
Ursprung 9f3d1a2390
Commit e3c75a7fcc

Datei anzeigen

@ -104,7 +104,7 @@ public final class ConnectionManager {
.childOption(ChannelOption.IP_TOS, 0x18)
.localAddress(address);
if (server.getConfiguration().useTcpFastOpen()) {
if (transportType == TransportType.EPOLL && server.getConfiguration().useTcpFastOpen()) {
bootstrap.option(EpollChannelOption.TCP_FASTOPEN, 3);
}
@ -164,7 +164,7 @@ public final class ConnectionManager {
this.server.getConfiguration().getConnectTimeout())
.group(group == null ? this.workerGroup : group)
.resolver(this.resolverGroup);
if (server.getConfiguration().useTcpFastOpen()) {
if (transportType == TransportType.EPOLL && server.getConfiguration().useTcpFastOpen()) {
bootstrap.option(EpollChannelOption.TCP_FASTOPEN_CONNECT, true);
}
return bootstrap;