Class NettyClientSslBuilder
java.lang.Object
io.micronaut.http.ssl.SslBuilder<io.netty.handler.ssl.SslContext>
io.micronaut.http.client.netty.ssl.NettyClientSslBuilder
- All Implemented Interfaces:
ClientSslBuilder
@Singleton
@Secondary
public class NettyClientSslBuilder
extends SslBuilder<io.netty.handler.ssl.SslContext>
implements ClientSslBuilder
The Netty implementation of
This class is not final, so you can extend and replace it to implement alternate mechanisms for loading the key and trust stores.
SslBuilder
that generates an SslContext
to create a client that
supports SSL.This class is not final, so you can extend and replace it to implement alternate mechanisms for loading the key and trust stores.
- Since:
- 1.0
- Author:
- James Kleeh
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionfinal Optional<io.netty.handler.ssl.SslContext>
build
(SslConfiguration ssl) final @NonNull io.netty.handler.ssl.SslContext
build
(SslConfiguration ssl, HttpVersionSelection versionSelection) Build the ssl context.final Optional<io.netty.handler.ssl.SslContext>
build
(SslConfiguration ssl, HttpVersion httpVersion) final io.netty.incubator.codec.quic.QuicSslContext
Build the ssl context for QUIC.protected KeyManagerFactory
protected TrustManagerFactory
Methods inherited from class io.micronaut.http.ssl.SslBuilder
getKeyStore, getTrustManagerFactory, getTrustStore, load
-
Constructor Details
-
NettyClientSslBuilder
- Parameters:
resourceResolver
- The resource resolver
-
-
Method Details
-
build
- Specified by:
build
in classSslBuilder<io.netty.handler.ssl.SslContext>
- Parameters:
ssl
- The ssl configuration- Returns:
- Builds the SSL configuration wrapped inside an optional
-
build
public final Optional<io.netty.handler.ssl.SslContext> build(SslConfiguration ssl, HttpVersion httpVersion) - Specified by:
build
in classSslBuilder<io.netty.handler.ssl.SslContext>
- Parameters:
ssl
- The ssl configurationhttpVersion
- The http version- Returns:
- Builds the SSL configuration wrapped inside an optional
-
build
@NonNull public final @NonNull io.netty.handler.ssl.SslContext build(SslConfiguration ssl, HttpVersionSelection versionSelection) Description copied from interface:ClientSslBuilder
Build the ssl context.- Specified by:
build
in interfaceClientSslBuilder
- Parameters:
ssl
- The configurationversionSelection
- The HTTP versions to support- Returns:
- The ssl context
-
buildHttp3
Description copied from interface:ClientSslBuilder
Build the ssl context for QUIC.- Specified by:
buildHttp3
in interfaceClientSslBuilder
- Parameters:
ssl
- The configuration- Returns:
- The ssl context
-
getKeyManagerFactory
- Overrides:
getKeyManagerFactory
in classSslBuilder<io.netty.handler.ssl.SslContext>
- Parameters:
ssl
- The ssl configuration- Returns:
- The
KeyManagerFactory
-
getTrustManagerFactory
- Overrides:
getTrustManagerFactory
in classSslBuilder<io.netty.handler.ssl.SslContext>
- Parameters:
ssl
- The ssl configuration- Returns:
- The
TrustManagerFactory
-