Class CertificateProvidedSslBuilder
java.lang.Object
io.micronaut.http.ssl.SslBuilder<io.netty.handler.ssl.SslContext>
io.micronaut.http.server.netty.ssl.AbstractServerSslBuilder
io.micronaut.http.server.netty.ssl.CertificateProvidedSslBuilder
- All Implemented Interfaces:
ApplicationEventListener<RefreshEvent>,Ordered,ServerSslBuilder,RefreshEventListener,EventListener
@Requires(condition=io.micronaut.http.server.netty.ssl.SslEnabledCondition.class) @Requires(condition=io.micronaut.http.server.netty.ssl.CertificateProvidedSslBuilder.SelfSignedNotConfigured.class)
@Singleton
@Internal
public class CertificateProvidedSslBuilder
extends AbstractServerSslBuilder
implements ServerSslBuilder, RefreshEventListener, Ordered
The Netty implementation of
SslBuilder that generates an SslContext to create a server handle with
SSL support via user configuration.-
Field Summary
Fields inherited from interface io.micronaut.core.order.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCEFields inherited from interface io.micronaut.runtime.context.scope.refresh.RefreshEventListener
DEFAULT_POSITION -
Constructor Summary
ConstructorsConstructorDescriptionCertificateProvidedSslBuilder(HttpServerConfiguration httpServerConfiguration, ServerSslConfiguration ssl, ResourceResolver resourceResolver) -
Method Summary
Modifier and TypeMethodDescriptionReturns the set of observed configuration prefixes that the event listener should listen for.intgetOrder()voidonApplicationEvent(RefreshEvent event) Handle an application event.Methods inherited from class io.micronaut.http.server.netty.ssl.AbstractServerSslBuilder
build, build, build, buildQuic, getKeyManagerFactory, processBuilderMethods inherited from class io.micronaut.http.ssl.SslBuilder
getTrustManagerFactory, getTrustManagerFactory, loadMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.micronaut.runtime.context.scope.refresh.RefreshEventListener
supportsMethods inherited from interface io.micronaut.http.server.netty.ssl.ServerSslBuilder
build, buildQuic
-
Constructor Details
-
CertificateProvidedSslBuilder
public CertificateProvidedSslBuilder(HttpServerConfiguration httpServerConfiguration, ServerSslConfiguration ssl, ResourceResolver resourceResolver) - Parameters:
httpServerConfiguration- The HTTP server configurationssl- The ssl configurationresourceResolver- The resource resolver
-
-
Method Details
-
getSslConfiguration
- Specified by:
getSslConfigurationin interfaceServerSslBuilder- Returns:
- The SSL configuration
-
getTrustStore
- Overrides:
getTrustStorein classSslBuilder<io.netty.handler.ssl.SslContext>- Parameters:
ssl- The ssl configuration- Returns:
- An optional
KeyStore - Throws:
Exception- if there is an error
-
getKeyStore
- Overrides:
getKeyStorein classSslBuilder<io.netty.handler.ssl.SslContext>- Parameters:
ssl- The ssl configuration- Returns:
- An optional
KeyStore - Throws:
Exception- if there is an error
-
getObservedConfigurationPrefixes
Description copied from interface:RefreshEventListenerReturns the set of observed configuration prefixes that the event listener should listen for.- Specified by:
getObservedConfigurationPrefixesin interfaceRefreshEventListener- Returns:
- A set of prefixes
-
onApplicationEvent
Description copied from interface:ApplicationEventListenerHandle an application event.- Specified by:
onApplicationEventin interfaceApplicationEventListener<RefreshEvent>- Parameters:
event- the event to respond to
-
getOrder
public int getOrder()- Specified by:
getOrderin interfaceOrdered- Specified by:
getOrderin interfaceRefreshEventListener- Returns:
- The order of the object. Defaults to zero (no order).
-