Top Description Inners Fields Constructors Methods
reactor.netty5.udp

public final Class UdpServerConfig

extends TransportConfig
Class Inheritance
Imports
io.netty5.channel.Channel, .ChannelOption, .EventLoopGroup, .ServerChannel, .ServerChannelFactory, io.netty5.channel.group.ChannelGroup, io.netty5.channel.socket.DatagramChannel, io.netty5.handler.logging.LogLevel, .LoggingHandler, reactor.netty5.ChannelPipelineConfigurer, .Connection, .ConnectionObserver, reactor.netty5.channel.ChannelMetricsRecorder, .ChannelOperations, .MicrometerChannelMetricsRecorder, reactor.netty5.resources.LoopResources, reactor.netty5.transport.TransportConfig, reactor.netty5.transport.logging.AdvancedBufferFormat, reactor.util.annotation.Nullable, java.net.ProtocolFamily, .SocketAddress, java.nio.charset.Charset, java.util.Map, java.util.function.Consumer, .Supplier

Encapsulate all necessary configuration for UDP server transport. The public API is read-only.
Author
Violeta Georgieva
Since
1.0.0

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class
pack-priv static class

Field Summary

Modifier and TypeField and Description
pack-priv static final ChannelOperations.OnSetup
pack-priv Consumer<? super UdpServerConfig>
pack-priv Consumer<? super Connection>
pack-priv Consumer<? super Connection>
pack-priv static final LoggingHandler

Constructor Summary

AccessConstructor and Description
pack-priv
UdpServerConfig(Map<ChannelOption<?>, ?> options, Supplier<? extends SocketAddress> bindAddress)

pack-priv

Method Summary

Modifier and TypeMethod and Description
public ChannelOperations.OnSetup
channelOperationsProvider()

Overrides reactor.netty5.transport.TransportConfig.channelOperationsProvider.

Return the associated ChannelOperations.OnSetup, config implementations might override this
protected Class<? extends Channel>
channelType()

Overrides reactor.netty5.transport.TransportConfig.channelType.

Return the channel type this configuration is associated with, it can be one of the following:
protected ConnectionObserver
protected LoggingHandler
defaultLoggingHandler()

Implements abstract reactor.netty5.transport.TransportConfig.defaultLoggingHandler.

Return the default LoggingHandler to wiretap this transport
protected LoopResources
defaultLoopResources()

Implements abstract reactor.netty5.transport.TransportConfig.defaultLoopResources.

Return the default LoopResources for this transport
protected ChannelMetricsRecorder
defaultMetricsRecorder()

Implements abstract reactor.netty5.transport.TransportConfig.defaultMetricsRecorder.

Return the configured metrics recorder.
protected ChannelPipelineConfigurer
public final Consumer<? super UdpServerConfig>

Returns:

the configured callback or null
doOnBind
()

Return the configured callback or null

public final Consumer<? super Connection>

Returns:

the configured callback or null
doOnBound
()

Return the configured callback or null

public final Consumer<? super Connection>

Returns:

the configured callback or null
doOnUnbound
()

Return the configured callback or null

protected EventLoopGroup
protected Class<? extends ServerChannel>
serverChannelType()

Overrides reactor.netty5.transport.TransportConfig.serverChannelType.

Return the channel type this configuration is associated with, it can be one of the following:
protected ServerChannelFactory<? extends ServerChannel>
serverConnectionFactory(ProtocolFamily
the configured ProtocolFamily to run with
protocolFamily
)

Overrides reactor.netty5.transport.TransportConfig.serverConnectionFactory.

Return the ServerChannelFactory which is used to create ServerChannel instances.
Inherited from reactor.netty5.transport.TransportConfig:
attributesbindAddresschannelGroupchannelHashchannelInitializerconnectionFactoryconnectionObserverdoOnChannelInitfamilyisPreferNativeloggingHandlerloggingHandlerloopResourcesmetricsRecordermetricsRecordermetricsRecorderInternaloptionsupdateMap

Field Detail

DEFAULT_OPSback to summary
pack-priv static final ChannelOperations.OnSetup DEFAULT_OPS
doOnBindback to summary
pack-priv Consumer<? super UdpServerConfig> doOnBind
doOnBoundback to summary
pack-priv Consumer<? super Connection> doOnBound
doOnUnboundback to summary
pack-priv Consumer<? super Connection> doOnUnbound
LOGGING_HANDLERback to summary
pack-priv static final LoggingHandler LOGGING_HANDLER

Constructor Detail

UdpServerConfigback to summary
pack-priv UdpServerConfig(Map<ChannelOption<?>, ?> options, Supplier<? extends SocketAddress> bindAddress)
UdpServerConfigback to summary
pack-priv UdpServerConfig(UdpServerConfig parent)

Method Detail

channelOperationsProviderback to summary
public ChannelOperations.OnSetup channelOperationsProvider()

Overrides reactor.netty5.transport.TransportConfig.channelOperationsProvider.

Doc from reactor.netty5.transport.TransportConfig.channelOperationsProvider.

Return the associated ChannelOperations.OnSetup, config implementations might override this

Returns:ChannelOperations.OnSetup

the associated ChannelOperations.OnSetup

Annotations
@Override
channelTypeback to summary
protected Class<? extends Channel> channelType()

Overrides reactor.netty5.transport.TransportConfig.channelType.

Doc from reactor.netty5.transport.TransportConfig.channelType.

Return the channel type this configuration is associated with, it can be one of the following:

Returns:Class<? extends Channel>

the channel type this configuration is associated with

Annotations
@Override
defaultConnectionObserverback to summary
protected ConnectionObserver defaultConnectionObserver()

Implements abstract reactor.netty5.transport.TransportConfig.defaultConnectionObserver.

Doc from reactor.netty5.transport.TransportConfig.defaultConnectionObserver.

Return the configured default ConnectionObserver.

Returns:ConnectionObserver

the configured default ConnectionObserver

Annotations
@Override
defaultLoggingHandlerback to summary
protected LoggingHandler defaultLoggingHandler()

Implements abstract reactor.netty5.transport.TransportConfig.defaultLoggingHandler.

Doc from reactor.netty5.transport.TransportConfig.defaultLoggingHandler.

Return the default LoggingHandler to wiretap this transport

Returns:LoggingHandler

the default LoggingHandler to wiretap this transport

Annotations
@Override
defaultLoopResourcesback to summary
protected LoopResources defaultLoopResources()

Implements abstract reactor.netty5.transport.TransportConfig.defaultLoopResources.

Doc from reactor.netty5.transport.TransportConfig.defaultLoopResources.

Return the default LoopResources for this transport

Returns:LoopResources

the default LoopResources for this transport

Annotations
@Override
defaultMetricsRecorderback to summary
protected ChannelMetricsRecorder defaultMetricsRecorder()

Implements abstract reactor.netty5.transport.TransportConfig.defaultMetricsRecorder.

Doc from reactor.netty5.transport.TransportConfig.defaultMetricsRecorder.

Return the configured metrics recorder.

Returns:ChannelMetricsRecorder

the configured metrics recorder

Annotations
@Override
defaultOnChannelInitback to summary
protected ChannelPipelineConfigurer defaultOnChannelInit()

Implements abstract reactor.netty5.transport.TransportConfig.defaultOnChannelInit.

Doc from reactor.netty5.transport.TransportConfig.defaultOnChannelInit.

Return the default callback if any or ChannelPipelineConfigurer#emptyConfigurer()

Returns:ChannelPipelineConfigurer

the default callback if any or ChannelPipelineConfigurer#emptyConfigurer()

Annotations
@Override
doOnBindback to summary
public final Consumer<? super UdpServerConfig> doOnBind()

Return the configured callback or null

Returns:Consumer<? super UdpServerConfig>

the configured callback or null

Annotations
@Nullable
doOnBoundback to summary
public final Consumer<? super Connection> doOnBound()

Return the configured callback or null

Returns:Consumer<? super Connection>

the configured callback or null

Annotations
@Nullable
doOnUnboundback to summary
public final Consumer<? super Connection> doOnUnbound()

Return the configured callback or null

Returns:Consumer<? super Connection>

the configured callback or null

Annotations
@Nullable
eventLoopGroupback to summary
protected EventLoopGroup eventLoopGroup()

Implements abstract reactor.netty5.transport.TransportConfig.eventLoopGroup.

Doc from reactor.netty5.transport.TransportConfig.eventLoopGroup.

Return the configured EventLoopGroup.

Returns:EventLoopGroup

the configured EventLoopGroup

Annotations
@Override
serverChannelTypeback to summary
protected Class<? extends ServerChannel> serverChannelType()

Overrides reactor.netty5.transport.TransportConfig.serverChannelType.

Doc from reactor.netty5.transport.TransportConfig.serverChannelType.

Return the channel type this configuration is associated with, it can be one of the following:

Returns:Class<? extends ServerChannel>

the channel type this configuration is associated with

Annotations
@Override
serverConnectionFactoryback to summary
protected ServerChannelFactory<? extends ServerChannel> serverConnectionFactory(ProtocolFamily protocolFamily)

Overrides reactor.netty5.transport.TransportConfig.serverConnectionFactory.

Doc from reactor.netty5.transport.TransportConfig.serverConnectionFactory.

Return the ServerChannelFactory which is used to create ServerChannel instances.

Parameters
protocolFamily:ProtocolFamily

the configured ProtocolFamily to run with

Returns:ServerChannelFactory<? extends ServerChannel>

the ServerChannelFactory which is used to create ServerChannel instances.

Annotations
@Override
reactor.netty5.udp back to summary

pack-priv final Class UdpServerConfig.MicrometerUdpServerMetricsRecorder

extends MicrometerChannelMetricsRecorder
Class Inheritance

Field Summary

Modifier and TypeField and Description
pack-priv static final UdpServerConfig.MicrometerUdpServerMetricsRecorder

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Inherited from reactor.netty5.channel.MicrometerChannelMetricsRecorder:
filtergetResolveAddressTimergetTlsHandshakeTimerincrementErrorsCountnameprotocolrecordConnectTimerecordDataReceivedrecordDataSentrecordResolveAddressTimerecordServerConnectionClosedrecordServerConnectionOpenedrecordTlsHandshakeTime

Field Detail

INSTANCEback to summary
pack-priv static final UdpServerConfig.MicrometerUdpServerMetricsRecorder INSTANCE

Constructor Detail

MicrometerUdpServerMetricsRecorderback to summary
pack-priv MicrometerUdpServerMetricsRecorder()
reactor.netty5.udp back to summary

pack-priv final Class UdpServerConfig.UdpServerDoOn

extends Object
implements ConnectionObserver
Class Inheritance
All Implemented Interfaces
reactor.netty5.ConnectionObserver

Field Summary

Modifier and TypeField and Description
pack-priv final ChannelGroup
pack-priv final Consumer<? super Connection>
pack-priv final Consumer<? super Connection>

Constructor Summary

AccessConstructor and Description
pack-priv
UdpServerDoOn(ChannelGroup channelGroup, Consumer<? super Connection> doOnBound, Consumer<? super Connection> doOnUnbound)

Method Summary

Modifier and TypeMethod and Description
public void
onStateChange(Connection
the connection reference
connection
,
ConnectionObserver.State
the new State
newState
)

Implements reactor.netty5.ConnectionObserver.onStateChange.

React on connection state change (e.g. http request or response)
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

channelGroupback to summary
pack-priv final ChannelGroup channelGroup
doOnBoundback to summary
pack-priv final Consumer<? super Connection> doOnBound
doOnUnboundback to summary
pack-priv final Consumer<? super Connection> doOnUnbound

Constructor Detail

UdpServerDoOnback to summary
pack-priv UdpServerDoOn(ChannelGroup channelGroup, Consumer<? super Connection> doOnBound, Consumer<? super Connection> doOnUnbound)

Method Detail

onStateChangeback to summary
public void onStateChange(Connection connection, ConnectionObserver.State newState)

Implements reactor.netty5.ConnectionObserver.onStateChange.

Doc from reactor.netty5.ConnectionObserver.onStateChange.

React on connection state change (e.g. http request or response)

Parameters
connection:Connection

the connection reference

newState:ConnectionObserver.State

the new State

Annotations
@Override