Package cloud.piranha.dist.microprofile
Class MicroProfilePiranha
java.lang.Object
cloud.piranha.dist.microprofile.MicroProfilePiranha
The Piranha Micro runtime.
- Author:
- Manfred Riem ([email protected])
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
run()
Run method.void
service
(WebApplicationRequest request, WebApplicationResponse response) Service the request and response.void
setContextPath
(String contextPath) Set the context path.void
setExitOnStop
(boolean exitOnStop) Set the exit on stop flag.void
setExtensionClass
(Class<? extends WebApplicationExtension> extensionClass) Set the default extension class.void
setHttpPort
(int httpPort) Set the HTTP server port.void
setHttpServerClass
(String httpServerClass) Set the HTTP server class.void
setHttpsPort
(int httpsPort) Set the HTTPS server port.void
setHttpsServerClass
(String httpsServerClass) Set the HTTPS server class.void
setJpmsEnabled
(boolean jpmsEnabled) Enable/disable JPMS.void
Set the PID.void
setSslKeystoreFile
(String sslKeystoreFile) Set the SSL keystore file.void
setWarFile
(String warFile) Set the WAR file.void
setWebAppDir
(String webAppDir) Set the web application directory.void
start()
Start the server.void
stop()
Stop the server.
-
Constructor Details
-
MicroProfilePiranha
public MicroProfilePiranha()
-
-
Method Details
-
run
public void run()Run method. -
service
public void service(WebApplicationRequest request, WebApplicationResponse response) throws IOException, jakarta.servlet.ServletException Description copied from interface:Piranha
Service the request and response.- Specified by:
service
in interfacePiranha
- Parameters:
request
- the request.response
- the response.- Throws:
IOException
- when an I/O error occurs.jakarta.servlet.ServletException
- when a Servlet error occurs.
-
setContextPath
Set the context path.- Parameters:
contextPath
- the context path.
-
setExtensionClass
Set the default extension class.- Parameters:
extensionClass
- the default extension class.
-
setExitOnStop
public void setExitOnStop(boolean exitOnStop) Set the exit on stop flag.- Parameters:
exitOnStop
- the exit on stop flag.
-
setHttpPort
public void setHttpPort(int httpPort) Set the HTTP server port.- Parameters:
httpPort
- the HTTP server port.
-
setHttpServerClass
Set the HTTP server class.- Parameters:
httpServerClass
- the HTTP server class.
-
setHttpsPort
public void setHttpsPort(int httpsPort) Set the HTTPS server port.- Parameters:
httpsPort
- the HTTPS server port.
-
setHttpsServerClass
Set the HTTPS server class.- Parameters:
httpsServerClass
- the HTTPS server class.
-
setJpmsEnabled
public void setJpmsEnabled(boolean jpmsEnabled) Enable/disable JPMS.- Parameters:
jpmsEnabled
- the JPMS enabled flag.
-
setPid
Set the PID.- Parameters:
pid
- the PID.
-
setSslKeystoreFile
Set the SSL keystore file.Convenience wrapper around the
javax.net.ssl.keyStore
system property. Note using this method sets the property for the entire JVM.- Parameters:
sslKeystoreFile
- the SSL keystore file.
-
setWarFile
Set the WAR file.- Parameters:
warFile
- the WAR file.
-
setWebAppDir
Set the web application directory.- Parameters:
webAppDir
- the web application directory.
-
start
public void start()Start the server. -
stop
public void stop()Stop the server.
-