Package reactor.netty.udp
Class UdpClientConfig
Encapsulate all necessary configuration for UDP client transport. The public API is read-only.
- Since:
- 1.0.0
- Author:
- Violeta Georgieva
-
Method Summary
Modifier and TypeMethodDescriptionReturn the associatedChannelOperations.OnSetup
, config implementations might override this.channelType
(boolean isDomainSocket) Return the channel type this configuration is associated with, it can be one of the following.protected ChannelFactory<? extends Channel>
connectionFactory
(EventLoopGroup elg, boolean isDomainSocket) Return theChannelFactory
which is used to createChannel
instances.protected AddressResolverGroup<?>
Provides a globalAddressResolverGroup
fromUdpResources
that is shared amongst all UDP clients.protected LoggingHandler
Return the defaultLoggingHandler
to wiretap this transport.protected LoopResources
Return the defaultLoopResources
for this transport.protected ChannelMetricsRecorder
Return the configured metrics recorder.final @Nullable InternetProtocolFamily
family()
Deprecated.as of 1.3.0.final @Nullable SocketProtocolFamily
Return the configuredSocketProtocolFamily
to run with or null.Methods inherited from class reactor.netty.transport.ClientTransportConfig
channelHash, connectionProvider, defaultConnectionObserver, defaultOnChannelInit, doOnConnect, doOnConnected, doOnDisconnected, eventLoopGroup, getNameResolverProvider, hasProxy, proxyProvider, proxyProvider, proxyProviderSupplier, proxyProviderSupplier, remoteAddress, resolver, resolverInternal
Methods inherited from class reactor.netty.transport.TransportConfig
attributes, bindAddress, bindAddress, channelGroup, channelInitializer, connectionObserver, doOnChannelInit, isPreferNative, loggingHandler, loggingHandler, loopResources, metricsRecorder, metricsRecorder, metricsRecorderInternal, options, updateMap
-
Method Details
-
channelOperationsProvider
Description copied from class:TransportConfig
Return the associatedChannelOperations.OnSetup
, config implementations might override this.- Overrides:
channelOperationsProvider
in classTransportConfig
- Returns:
- the associated
ChannelOperations.OnSetup
-
family
Deprecated.as of 1.3.0. PrefersocketFamily()
. This method will be removed in version 1.4.0.Return the configuredInternetProtocolFamily
to run with or null.- Returns:
- the configured
InternetProtocolFamily
to run with or null
-
socketFamily
Return the configuredSocketProtocolFamily
to run with or null.- Returns:
- the configured
SocketProtocolFamily
to run with or null - Since:
- 1.3.0
-
channelType
Description copied from class:TransportConfig
Return the channel type this configuration is associated with, it can be one of the following.- Overrides:
channelType
in classClientTransportConfig<UdpClientConfig>
- Parameters:
isDomainSocket
- true ifDomainSocketChannel
orServerDomainSocketChannel
is needed, false otherwise- Returns:
- the channel type this configuration is associated with
-
connectionFactory
protected ChannelFactory<? extends Channel> connectionFactory(EventLoopGroup elg, boolean isDomainSocket) Description copied from class:TransportConfig
Return theChannelFactory
which is used to createChannel
instances.- Overrides:
connectionFactory
in classTransportConfig
- Parameters:
elg
- theEventLoopGroup
isDomainSocket
- true ifDomainSocketChannel
orServerDomainSocketChannel
is needed, false otherwise- Returns:
- the
ChannelFactory
which is used to createChannel
instances.
-
defaultAddressResolverGroup
Provides a globalAddressResolverGroup
fromUdpResources
that is shared amongst all UDP clients.AddressResolverGroup
uses the globalLoopResources
fromUdpResources
.- Specified by:
defaultAddressResolverGroup
in classClientTransportConfig<UdpClientConfig>
- Returns:
- the global
AddressResolverGroup
-
defaultLoggingHandler
Description copied from class:TransportConfig
Return the defaultLoggingHandler
to wiretap this transport.- Specified by:
defaultLoggingHandler
in classTransportConfig
- Returns:
- the default
LoggingHandler
to wiretap this transport
-
defaultLoopResources
Description copied from class:TransportConfig
Return the defaultLoopResources
for this transport.- Specified by:
defaultLoopResources
in classTransportConfig
- Returns:
- the default
LoopResources
for this transport
-
defaultMetricsRecorder
Description copied from class:TransportConfig
Return the configured metrics recorder.- Specified by:
defaultMetricsRecorder
in classTransportConfig
- Returns:
- the configured metrics recorder
-