Package io.micronaut.http.client.netty
Class ConnectionManager
java.lang.Object
io.micronaut.http.client.netty.ConnectionManager
Connection manager for
Note: This class is public for use in micronaut-oracle-cloud.
DefaultHttpClient
. This class manages the lifecycle of netty
channels (wrapped in ConnectionManager.PoolHandle
s), including pooling and timeouts.Note: This class is public for use in micronaut-oracle-cloud.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Handle for a pooled connection. -
Method Summary
Modifier and TypeMethodDescriptionfinal io.netty.buffer.ByteBufAllocator
alloc()
Allocator for this connection manager.connect
(DefaultHttpClient.RequestKey requestKey, @Nullable BlockHint blockHint) Get a connection for non-websocket http client methods.final boolean
final void
shutdown()
final void
start()
-
Method Details
-
alloc
public final io.netty.buffer.ByteBufAllocator alloc()Allocator for this connection manager. Used by micronaut-oracle-cloud.- Returns:
- The configured allocator
-
start
public final void start()- See Also:
-
shutdown
public final void shutdown()- See Also:
-
isRunning
public final boolean isRunning()- Returns:
- Whether this connection manager is still running and can serve requests
- See Also:
-
connect
public final ExecutionFlow<ConnectionManager.PoolHandle> connect(DefaultHttpClient.RequestKey requestKey, @Nullable @Nullable BlockHint blockHint) Get a connection for non-websocket http client methods.- Parameters:
requestKey
- The remote to connect toblockHint
- Optional information about what threads are blocked for this connection request- Returns:
- A mono that will complete once the channel is ready for transmission
-