Package io.micronaut.servlet.tomcat
Class TomcatServer
java.lang.Object
io.micronaut.servlet.engine.server.AbstractServletServer<org.apache.catalina.startup.Tomcat>
io.micronaut.servlet.tomcat.TomcatServer
- 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
@Singleton
public class TomcatServer
extends AbstractServletServer<org.apache.catalina.startup.Tomcat>
Implementation of
EmbeddedServer
for Tomcat.- Since:
- 1.0.0
- Author:
- graemerocher
-
Constructor Summary
ConstructorDescriptionTomcatServer
(io.micronaut.context.ApplicationContext applicationContext, io.micronaut.runtime.ApplicationConfiguration applicationConfiguration, org.apache.catalina.startup.Tomcat tomcat) Default constructor. -
Method Summary
Methods inherited from class io.micronaut.servlet.engine.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
-
TomcatServer
public TomcatServer(io.micronaut.context.ApplicationContext applicationContext, io.micronaut.runtime.ApplicationConfiguration applicationConfiguration, org.apache.catalina.startup.Tomcat tomcat) Default constructor.- Parameters:
applicationContext
- The contextapplicationConfiguration
- The configurationtomcat
- The tomcat instance
-
-
Method Details
-
startServer
Description copied from class:AbstractServletServer
Start the server.- Specified by:
startServer
in classAbstractServletServer<org.apache.catalina.startup.Tomcat>
- Throws:
Exception
- when an error occurred starting the server
-
stopServer
Description copied from class:AbstractServletServer
Stop the server.- Specified by:
stopServer
in classAbstractServletServer<org.apache.catalina.startup.Tomcat>
- Throws:
Exception
- when an error occurred stopping the server
-
getPort
public int getPort() -
getHost
-
getScheme
-
getURL
-
getURI
-
isRunning
public boolean isRunning()
-