| Modifier and Type | Field and Description |
|---|---|
| pack-priv static final NameResolverProvider | |
| pack-priv final LoopResources | |
| pack-priv final ConnectionProvider | |
| pack-priv final AtomicReference | |
| pack-priv static final Logger | |
| pack-priv static final BiFunction | |
| pack-priv static final AtomicReference |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| protected void | |
| protected Mono | Returns: the Mono that represents the end of disposalthe quiet period as described above quietPeriod, Duration the maximum amount of time to wait until the disposal of the underlying
LoopResources regardless if a task was submitted during the quiet period timeout)Dispose underlying resources in a listenable fashion. |
| pack-priv void | |
| pack-priv Mono | |
| public Mono | acquire(TransportConfig
the transport configuration config, ConnectionObserver observer, Supplier<? extends SocketAddress> the remoteAddress, AddressResolverGroup<?> SocketAddress to connect tothe resolver which will resolve the address of the unresolved named address resolverGroup)Implements reactor. Connection on subscribe.
|
| pack-priv static <T extends TcpResources> T | create(T previous, LoopResources loops, ConnectionProvider provider, String name, BiFunction<LoopResources, ConnectionProvider, T> onNew)
|
| public boolean | daemon()
Overrides default reactor. EventLoopGroup should not be shutdown.
|
| public void | dispose()
Overrides default reactor. NOOP implementation by default in order to prevent unintended disposal of
the global TCP resources which has a longer lifecycle than regular LoopResources
and ConnectionProvider.
|
| public Mono | disposeLater()
Overrides default reactor. NOOP implementation by default in order to prevent unintended disposal of
the global TCP resources which has a longer lifecycle than regular LoopResources
and ConnectionProvider.
|
| public Mono | disposeLater(Duration
the quiet period as described above quietPeriod, Duration the maximum amount of time to wait until the disposal of the underlying
LoopResources regardless if a task was submitted during the quiet period timeout)Overrides default reactor. NOOP implementation by default in order to prevent unintended disposal of
the global TCP resources which has a longer lifecycle than regular LoopResources
and ConnectionProvider.
|
| public static void | disposeLoopsAndConnections()
Shutdown the global |
| public static Mono | disposeLoopsAndConnectionsLater()
Prepare to shutdown the global |
| public static Mono | disposeLoopsAndConnectionsLater(Duration
the quiet period as described above quietPeriod, Duration the maximum amount of time to wait until the disposal of the underlying
LoopResources regardless if a task was submitted during the quiet period timeout)Prepare to shutdown the global |
| public void | disposeWhen(SocketAddress
the remote address remoteAddress)Overrides default reactor. |
| public static TcpResources | Returns: the global TCP resources for event loops and poolingReturn the global TCP resources for event loops and pooling. |
| protected static < the reified type of T extends TcpResources> TTcpResources | Returns: an existing or newTcpResourcesthe resources atomic reference ref, LoopResources the eventual new loops, ConnectionProvider LoopResourcesthe eventual new provider, BiFunction<LoopResources, ConnectionProvider, T> ConnectionProvidera onNew, String TcpResources factorya name for resources name)Safely check if existing resource exist and proceed to update/cleanup if new resources references are passed. |
| protected AddressResolverGroup | Returns: an existing or newAddressResolverGroupSafely checks whether a name resolver exists and proceed with a creation if it does not exist. |
| public boolean | isDisposed()
Overrides default reactor. |
| public int | maxConnections()
Overrides default reactor. |
| public Map | maxConnectionsPerHost()
Overrides default reactor. |
| public ConnectionProvider. | mutate()
Overrides default reactor. ConnectionProvider.
|
| public String | name()
Overrides default reactor. ConnectionProvider name used for metrics.
|
| public <CHANNEL extends Channel> CHANNEL | onChannel(Class<CHANNEL>
the channel type channelType, EventLoopGroup the source group)EventLoopGroup to assign a loop fromOverrides default reactor. Channel selection.
|
| public <CHANNEL extends Channel> Class | onChannelClass(Class<CHANNEL>
the channel type channelType, EventLoopGroup the source group)EventLoopGroup to assign a loop fromOverrides default reactor. Channel class selection.
|
| public EventLoopGroup | onClient(boolean
should use native group if current environment supports it useNative)Overrides default reactor. EventLoopGroup creation.
|
| public EventLoopGroup | onServer(boolean
should use native group if current environment supports it useNative)Implements reactor. EventLoopGroup creation,
this is the EventLoopGroup for the child channel.
|
| public EventLoopGroup | onServerSelect(boolean
should use native group if current environment supports it useNative)Overrides default reactor. EventLoopGroup creation,
this is the EventLoopGroup for the acceptor channel.
|
| public static TcpResources | |
| public static TcpResources | Returns: the global TCP resourcesa new provider)ConnectionProvider to replace the currentUpdate pooling resources and return the global TCP resources. |
| public static TcpResources | Returns: the global TCP resourcesa new loops)LoopResources to replace the currentUpdate event loops resources and return the global TCP resources. |
| DEFAULT_NAME_RESOLVER_PROVIDER | back to summary |
|---|---|
| pack-priv static final NameResolverProvider DEFAULT_NAME_RESOLVER_PROVIDER | |
| defaultLoops | back to summary |
|---|---|
| pack-priv final LoopResources defaultLoops | |
| defaultProvider | back to summary |
|---|---|
| pack-priv final ConnectionProvider defaultProvider | |
| defaultResolver | back to summary |
|---|---|
| pack-priv final AtomicReference<AddressResolverGroup<?>> defaultResolver | |
| log | back to summary |
|---|---|
| pack-priv static final Logger log | |
| ON_TCP_NEW | back to summary |
|---|---|
| pack-priv static final BiFunction<LoopResources, ConnectionProvider, TcpResources> ON_TCP_NEW | |
| tcpResources | back to summary |
|---|---|
| pack-priv static final AtomicReference<TcpResources> tcpResources | |
| TcpResources | back to summary |
|---|---|
| protected TcpResources(LoopResources defaultLoops, ConnectionProvider defaultProvider) | |
| _dispose | back to summary |
|---|---|
| protected void _dispose() Dispose underlying resources. | |
| _disposeLater | back to summary |
|---|---|
| protected Mono Dispose underlying resources in a listenable fashion.
It is guaranteed that the disposal of the underlying LoopResources will not happen before
| |
| _disposeResolver | back to summary |
|---|---|
| pack-priv void _disposeResolver() | |
| _disposeResolverLater | back to summary |
|---|---|
| pack-priv Mono | |
| acquire | back to summary |
|---|---|
| public Mono Implements reactor. Doc from reactor. Return an existing or new
| |
| create | back to summary |
|---|---|
| pack-priv static <T extends TcpResources> T create(T previous, LoopResources loops, ConnectionProvider provider, String name, BiFunction<LoopResources, ConnectionProvider, T> onNew) | |
| daemon | back to summary |
|---|---|
| public boolean daemon() Overrides default reactor. Doc from reactor. return true if
| |
| dispose | back to summary |
|---|---|
| public void dispose() Overrides default reactor. This has a
| |
| disposeLater | back to summary |
|---|---|
| public Mono Overrides default reactor. This has a
| |
| disposeLater | back to summary |
|---|---|
| public Mono Overrides default reactor. This has a
| |
| disposeLoopsAndConnections | back to summary |
|---|---|
| public static void disposeLoopsAndConnections() Shutdown the global | |
| disposeLoopsAndConnectionsLater | back to summary |
|---|---|
| public static Mono Prepare to shutdown the global
| |
| disposeLoopsAndConnectionsLater | back to summary |
|---|---|
| public static Mono Prepare to shutdown the global
| |
| disposeWhen | back to summary |
|---|---|
| public void disposeWhen(SocketAddress remoteAddress) Overrides default reactor. Dispose all connection pools for the specified remote address.
As opposed to
| |
| get | back to summary |
|---|---|
| public static TcpResources get() Return the global TCP resources for event loops and pooling.
| |
| getOrCreate | back to summary |
|---|---|
| protected static <T extends TcpResources> T getOrCreate(AtomicReference<T> ref, LoopResources loops, ConnectionProvider provider, BiFunction<LoopResources, ConnectionProvider, T> onNew, String name) Safely check if existing resource exist and proceed to update/cleanup if new resources references are passed.
| |
| getOrCreateDefaultResolver | back to summary |
|---|---|
| protected AddressResolverGroup Safely checks whether a name resolver exists and proceed with a creation if it does not exist.
The name resolver uses as an event loop group the
| |
| isDisposed | back to summary |
|---|---|
| public boolean isDisposed() Overrides default reactor. Doc from reactor. Optionally return true when the resource or task is disposed. Implementations are not required to track disposition and as such may never return true even when disposed. However, they MUST only return true when there's a guarantee the resource or task is disposed.
| |
| maxConnections | back to summary |
|---|---|
| public int maxConnections() Overrides default reactor. Doc from reactor. Returns the maximum number of connections before starting pending.
| |
| maxConnectionsPerHost | back to summary |
|---|---|
| public Map Overrides default reactor. Doc from reactor. Returns the maximum number of connections per host before starting pending.
| |
| mutate | back to summary |
|---|---|
| public ConnectionProvider. Overrides default reactor. Doc from reactor. Returns a builder to mutate properties of this
| |
| name | back to summary |
|---|---|
| public String name() Overrides default reactor. Doc from reactor. Returns
| |
| onChannel | back to summary |
|---|---|
| public <CHANNEL extends Channel> CHANNEL onChannel(Class<CHANNEL> channelType, EventLoopGroup group) Overrides default reactor. Doc from reactor. Callback for a
| |
| onChannelClass | back to summary |
|---|---|
| public <CHANNEL extends Channel> Class Overrides default reactor. Doc from reactor. Callback for a
| |
| onClient | back to summary |
|---|---|
| public EventLoopGroup onClient(boolean useNative) Overrides default reactor. Doc from reactor. Callback for client
| |
| onServer | back to summary |
|---|---|
| public EventLoopGroup onServer(boolean useNative) Implements reactor. Doc from reactor. Callback for server
| |
| onServerSelect | back to summary |
|---|---|
| public EventLoopGroup onServerSelect(boolean useNative) Overrides default reactor. Doc from reactor. Callback for server select
| |
| reset | back to summary |
|---|---|
| public static TcpResources reset() Reset TCP resources to default and return its instance.
| |
| set | back to summary |
|---|---|
| public static TcpResources set(ConnectionProvider provider) Update pooling resources and return the global TCP resources. Note The previous
| |
| set | back to summary |
|---|---|
| public static TcpResources set(LoopResources loops) Update event loops resources and return the global TCP resources. Note The previous
| |