Interface WebResourceManager
public interface WebResourceManager
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addServlet
(String servletName, Class<? extends jakarta.servlet.http.HttpServlet> servletClass) Adds anHttpServlet
to the Gateway, which will be mounted at /system/${servletName}.int
int
jakarta.servlet.ServletContext
Returns the ServletContext that is associated with this context.Optional<jakarta.servlet.http.HttpServletRequest>
boolean
void
removeServlet
(String servletName) Removes the servlet with the given name previously added viaaddServlet(String, Class)
.
-
Method Details
-
getHttpPort
int getHttpPort() -
getHttpsPort
int getHttpsPort() -
getWebServerDetails
-
isForceSecureRedirect
boolean isForceSecureRedirect() -
getServletContext
jakarta.servlet.ServletContext getServletContext()Returns the ServletContext that is associated with this context. -
addServlet
Adds anHttpServlet
to the Gateway, which will be mounted at /system/${servletName}. This is not commonly necessary, please useGatewayModuleHook.mountRouteHandlers(RouteGroup)
for more modern route handling. -
removeServlet
Removes the servlet with the given name previously added viaaddServlet(String, Class)
. Note: it is not necessary for modules to remove servlets on shutdown. -
getServletRequest
Optional<jakarta.servlet.http.HttpServletRequest> getServletRequest()- Returns:
- an
Optional
containing theHttpServletRequest
associated with the current thread, or an empty Optional if no such HttpServletRequest is associated with the current thread
-
getWebSessionManager
WebUiSessionManager getWebSessionManager()- Returns:
- the
SessionManager
used for managing the Gateway's web application sessions. - Since:
- 8.3.0
-
getSystemJsModuleRegistry
SystemJsModuleRegistry getSystemJsModuleRegistry()- Returns:
- The registry where modules can add their compiled front-end code for use in the web ui application.
- Since:
- 8.3.0
-