Package io.micronaut.servlet.undertow
Class UndertowServer
java.lang.Object
io.micronaut.servlet.http.server.AbstractServletServer<io.undertow.Undertow>
io.micronaut.servlet.undertow.UndertowServer
- All Implemented Interfaces:
io.micronaut.context.ApplicationContextLifeCycle<io.micronaut.runtime.server.EmbeddedServer>
,io.micronaut.context.ApplicationContextProvider
,io.micronaut.context.LifeCycle
,io.micronaut.runtime.EmbeddedApplication<io.micronaut.runtime.server.EmbeddedServer>
,io.micronaut.runtime.server.EmbeddedServer
,Closeable
,AutoCloseable
Implementation of
AbstractServletServer
for Undertow.- Since:
- 1.0.0
- Author:
- graemerocher
-
Constructor Summary
ConstructorsConstructorDescriptionUndertowServer
(io.micronaut.context.ApplicationContext applicationContext, io.micronaut.runtime.ApplicationConfiguration applicationConfiguration, @Nullable io.micronaut.context.event.ApplicationEventPublisher<io.micronaut.runtime.server.event.ServerShutdownEvent> serverShutdownEventPublisher, io.undertow.Undertow undertow) Default constructor.UndertowServer
(io.micronaut.context.ApplicationContext applicationContext, io.micronaut.runtime.ApplicationConfiguration applicationConfiguration, io.undertow.Undertow undertow) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Methods inherited from class io.micronaut.servlet.http.server.AbstractServletServer
getApplicationConfiguration, getApplicationContext, getServer, start, stop
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.micronaut.runtime.EmbeddedApplication
getEnvironment, isForceExit
Methods inherited from interface io.micronaut.runtime.server.EmbeddedServer
getContextURI, isKeepAlive, isServer
Methods inherited from interface io.micronaut.context.LifeCycle
close, refresh
-
Constructor Details
-
UndertowServer
@Inject public UndertowServer(io.micronaut.context.ApplicationContext applicationContext, io.micronaut.runtime.ApplicationConfiguration applicationConfiguration, @Nullable @Nullable io.micronaut.context.event.ApplicationEventPublisher<io.micronaut.runtime.server.event.ServerShutdownEvent> serverShutdownEventPublisher, io.undertow.Undertow undertow) Default constructor.- Parameters:
applicationContext
- The app contextapplicationConfiguration
- The app configserverShutdownEventPublisher
-ApplicationEventPublisher
for theServerShutdownEvent
event.undertow
- The undertow instance
-
UndertowServer
@Deprecated(forRemoval=true, since="5.2.0") public UndertowServer(io.micronaut.context.ApplicationContext applicationContext, io.micronaut.runtime.ApplicationConfiguration applicationConfiguration, io.undertow.Undertow undertow) Deprecated, for removal: This API element is subject to removal in a future version.Default constructor.- Parameters:
applicationContext
- The app contextapplicationConfiguration
- The app configundertow
- The undertow instance
-
-
Method Details
-
startServer
Description copied from class:AbstractServletServer
Start the server.- Specified by:
startServer
in classAbstractServletServer<io.undertow.Undertow>
- Throws:
Exception
- when an error occurred starting the server
-
stopServer
Description copied from class:AbstractServletServer
Stop the server.- Specified by:
stopServer
in classAbstractServletServer<io.undertow.Undertow>
- Throws:
Exception
- when an error occurred stopping the server
-
getPort
public int getPort() -
getHost
-
getScheme
-
getURL
-
getURI
-
isRunning
public boolean isRunning()
-
UndertowServer(ApplicationContext, ApplicationConfiguration, ApplicationEventPublisher, Undertow)
instead