Class TomcatService
java.lang.Object
com.linecorp.armeria.server.tomcat.TomcatService
- All Implemented Interfaces:
com.linecorp.armeria.common.util.Unwrappable,com.linecorp.armeria.server.HttpService,com.linecorp.armeria.server.Service<com.linecorp.armeria.common.HttpRequest,com.linecorp.armeria.common.HttpResponse>
public abstract class TomcatService
extends Object
implements com.linecorp.armeria.server.HttpService
An
HttpService that dispatches its requests to a web application running in an embedded
Tomcat.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionstatic TomcatServiceBuilderCreates a newTomcatServiceBuilderwith the web application at the specified document base, which can be a directory or a JAR/WAR file.static TomcatServiceBuilderCreates a newTomcatServiceBuilderwith the web application at the specified document base, which can be a directory or a JAR/WAR file.static TomcatServiceBuilderCreates a newTomcatServiceBuilderwith the web application at the specified document base, which can be a directory or a JAR/WAR file.static TomcatServiceBuilderCreates a newTomcatServiceBuilderwith the web application at the specified document base, which can be a directory or a JAR/WAR file.abstract @Nullable ConnectorReturns TomcatConnector.static TomcatServiceCreates a newTomcatServicewith the web application at the specified document base, which can be a directory or a JAR/WAR file.static TomcatServiceCreates a newTomcatServicewith the web application at the specified document base, which can be a directory or a JAR/WAR file.static TomcatServiceCreates a newTomcatServicewith the web application at the specified document base, which can be a directory or a JAR/WAR file.static TomcatServiceCreates a newTomcatServicewith the web application at the specified document base, which can be a directory or a JAR/WAR file.static TomcatServiceCreates a newTomcatServicefrom an existing TomcatConnectorinstance.static TomcatServiceCreates a newTomcatServicefrom an existing TomcatConnectorinstance.static TomcatServiceCreates a newTomcatServicefrom an existingTomcatinstance.final com.linecorp.armeria.common.HttpResponseserve(com.linecorp.armeria.server.ServiceRequestContext ctx, com.linecorp.armeria.common.HttpRequest req) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.linecorp.armeria.server.HttpService
decorate, decorateMethods inherited from interface com.linecorp.armeria.server.Service
as, serviceAdded, shouldCachePath, unwrap
-
Method Details
-
of
Creates a newTomcatServicewith the web application at the specified document base, which can be a directory or a JAR/WAR file. -
of
Creates a newTomcatServicewith the web application at the specified document base, which can be a directory or a JAR/WAR file. -
of
Creates a newTomcatServicewith the web application at the specified document base, which can be a directory or a JAR/WAR file. -
of
Creates a newTomcatServicewith the web application at the specified document base, which can be a directory or a JAR/WAR file. -
of
Creates a newTomcatServicefrom an existingTomcatinstance. If the specifiedTomcatinstance is not configured properly, the returnedTomcatServicemay respond with '503 Service Not Available' error.- Returns:
- a new
TomcatService, which will not manage the providedTomcatinstance.
-
of
Creates a newTomcatServicefrom an existing TomcatConnectorinstance. If the specifiedConnectorinstance is not configured properly, the returnedTomcatServicemay respond with '503 Service Not Available' error.- Returns:
- a new
TomcatService, which will not manage the providedConnectorinstance.
-
of
Creates a newTomcatServicefrom an existing TomcatConnectorinstance. If the specifiedConnectorinstance is not configured properly, the returnedTomcatServicemay respond with '503 Service Not Available' error.- Returns:
- a new
TomcatService, which will not manage the providedConnectorinstance.
-
builder
Creates a newTomcatServiceBuilderwith the web application at the specified document base, which can be a directory or a JAR/WAR file. -
builder
Creates a newTomcatServiceBuilderwith the web application at the specified document base, which can be a directory or a JAR/WAR file. -
builder
Creates a newTomcatServiceBuilderwith the web application at the specified document base, which can be a directory or a JAR/WAR file. -
builder
Creates a newTomcatServiceBuilderwith the web application at the specified document base, which can be a directory or a JAR/WAR file. -
connector
Returns TomcatConnector. -
serve
public final com.linecorp.armeria.common.HttpResponse serve(com.linecorp.armeria.server.ServiceRequestContext ctx, com.linecorp.armeria.common.HttpRequest req) throws Exception - Specified by:
servein interfacecom.linecorp.armeria.server.HttpService- Specified by:
servein interfacecom.linecorp.armeria.server.Service<com.linecorp.armeria.common.HttpRequest,com.linecorp.armeria.common.HttpResponse> - Throws:
Exception
-