diff --git a/docs/asciidoc/eventloop.adoc b/docs/asciidoc/eventloop.adoc index 2a1e1b7df6..ded73cb198 100644 --- a/docs/asciidoc/eventloop.adoc +++ b/docs/asciidoc/eventloop.adoc @@ -4,7 +4,7 @@ By default `Reactor Netty` uses an "`Event Loop Group`", where the number of the worker threads equals the number of processors available to the runtime on initialization (but with a minimum value of 4). When you need a different configuration, -you can use one of the {javadoc}/reactor/netty/resources/LoopResources.html[`LoopResource`]`#create` +you can use one of the {javadoc}/reactor/netty/resources/LoopResources.html[`LoopResources`]`#create` methods. The following listing shows the default configuration for the Event Loop Group: @@ -26,3 +26,14 @@ If you need changes to these settings, you can apply the following configuration include::{examplesdir}/eventloop/Application.java[lines=18..38] ---- ==== + +==== Disposing Event Loop Group + +- If you use the default `Event Loop Group` provided by Reactor Netty, invoke +{javadoc}/reactor/netty/http/HttpResources.html[`HttpResources`]`#disposeLoopsAndConnections`/`#disposeLoopsAndConnectionsLater` method. + +NOTE: Disposing `HttpResources` means that every server/client that is using it, will not be able to use it anymore! + +- If you use custom `LoopResources`, invoke {javadoc}/reactor/netty/resources/LoopResources.html[`LoopResources`]`#dispose`/`#disposeLater` method. + +NOTE: Disposing the custom `LoopResources` means that every server/client that is configured to use it, will not be able to use it anymore! diff --git a/docs/asciidoc/http-client-conn-provider.adoc b/docs/asciidoc/http-client-conn-provider.adoc index 1b05563451..75ec6f805c 100644 --- a/docs/asciidoc/http-client-conn-provider.adoc +++ b/docs/asciidoc/http-client-conn-provider.adoc @@ -83,6 +83,17 @@ include::{examplesdir}/pool/Application.java[lines=18..49] ---- ==== +=== Disposing Connection Pool + +- If you use the default `ConnectionProvider` provided by Reactor Netty, invoke +{javadoc}/reactor/netty/http/HttpResources.html[`HttpResources`]`#disposeLoopsAndConnections`/`#disposeLoopsAndConnectionsLater` method. + +NOTE: Disposing `HttpResources` means that every client that is using it, will not be able to use it anymore! + +- If you use custom `ConnectionProvider`, invoke {javadoc}/reactor/netty/resources/ConnectionProvider.html[`ConnectionProvider`]`#dispose`/`#disposeLater`/`#disposeWhen` method. + +NOTE: Disposing the custom `ConnectionProvider` means that every client that is configured to use it, will not be able to use it anymore! + === Metrics The pooled `ConnectionProvider` supports built-in integration with https://micrometer.io/[`Micrometer`]. It exposes all metrics with a prefix of `reactor.netty.connection.provider`. diff --git a/docs/asciidoc/tcp-client-conn-provider.adoc b/docs/asciidoc/tcp-client-conn-provider.adoc index 43ae5685cc..90ca5724f7 100644 --- a/docs/asciidoc/tcp-client-conn-provider.adoc +++ b/docs/asciidoc/tcp-client-conn-provider.adoc @@ -67,6 +67,17 @@ include::{examplesdir}/pool/Application.java[lines=18..35] ---- ==== +=== Disposing Connection Pool + +- If you use the default `ConnectionProvider` provided by Reactor Netty, invoke +{javadoc}/reactor/netty/http/HttpResources.html[`HttpResources`]`#disposeLoopsAndConnections`/`#disposeLoopsAndConnectionsLater` method. + +NOTE: Disposing `HttpResources` means that every client that is using it, will not be able to use it anymore! + +- If you use custom `ConnectionProvider`, invoke {javadoc}/reactor/netty/resources/ConnectionProvider.html[`ConnectionProvider`]`#dispose`/`#disposeLater`/`#disposeWhen` method. + +NOTE: Disposing the custom `ConnectionProvider` means that every client that is configured to use it, will not be able to use it anymore! + === Metrics The pooled `ConnectionProvider` supports built-in integration with https://micrometer.io/[`Micrometer`]. It exposes all metrics with a prefix of `reactor.netty.connection.provider`.