public class PluginDispatchServlet extends Object implements javax.servlet.Servlet
Constructor and Description |
---|
PluginDispatchServlet() |
Modifier and Type | Method and Description |
---|---|
protected void |
configurePluginWebsockets(Map.Entry<String,org.springframework.beans.factory.ListableBeanFactory> pluginBeanFactoryEntry)
Configures a platform plugin websocket endpoints.
|
void |
destroy() |
String |
getDispatchKey(javax.servlet.http.HttpServletRequest request)
Returns the dispatch key for this request.
|
protected Map<String,org.springframework.beans.factory.ListableBeanFactory> |
getPluginBeanFactories() |
protected String |
getServerUrl(String contextPath)
Gets the server URL up until the application context path.
|
protected javax.websocket.server.ServerEndpointConfig.Configurator |
getServerWebsocketEndpointConfigurator(String servletContextPath,
Predicate<String> isOriginAllowedPredicate)
Get the Server Endpoint Config configurator used for registering websocket endpoints.
|
javax.servlet.ServletConfig |
getServletConfig() |
String |
getServletInfo() |
protected javax.servlet.Servlet |
getTargetServlet(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
protected Map<String,org.pentaho.platform.api.websocket.IWebsocketEndpointConfig> |
getWebsocketEndpointConfigBeans(org.springframework.beans.factory.ListableBeanFactory pluginBeanFactory)
Gets the beans that implement the
IWebsocketEndpointConfig interface from the factory received as
parameter. |
void |
init(javax.servlet.ServletConfig config) |
void |
service(javax.servlet.ServletRequest req,
javax.servlet.ServletResponse res) |
public void destroy()
destroy
in interface javax.servlet.Servlet
public void service(javax.servlet.ServletRequest req, javax.servlet.ServletResponse res) throws javax.servlet.ServletException, IOException
service
in interface javax.servlet.Servlet
javax.servlet.ServletException
IOException
protected javax.servlet.Servlet getTargetServlet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException
javax.servlet.ServletException
public String getDispatchKey(javax.servlet.http.HttpServletRequest request)
public void init(javax.servlet.ServletConfig config) throws javax.servlet.ServletException
init
in interface javax.servlet.Servlet
javax.servlet.ServletException
public javax.servlet.ServletConfig getServletConfig()
getServletConfig
in interface javax.servlet.Servlet
public String getServletInfo()
getServletInfo
in interface javax.servlet.Servlet
protected Map<String,org.springframework.beans.factory.ListableBeanFactory> getPluginBeanFactories()
protected void configurePluginWebsockets(Map.Entry<String,org.springframework.beans.factory.ListableBeanFactory> pluginBeanFactoryEntry)
pluginBeanFactoryEntry
- the plugin bean factory entryprotected javax.websocket.server.ServerEndpointConfig.Configurator getServerWebsocketEndpointConfigurator(String servletContextPath, Predicate<String> isOriginAllowedPredicate)
servletContextPath
- The servlet context path.isOriginAllowedPredicate
- A predicate that validates if a origin is allowed on new connections. Can be null,
and in that scenario it will be ignored.protected Map<String,org.pentaho.platform.api.websocket.IWebsocketEndpointConfig> getWebsocketEndpointConfigBeans(org.springframework.beans.factory.ListableBeanFactory pluginBeanFactory)
IWebsocketEndpointConfig
interface from the factory received as
parameter.pluginBeanFactory
- The factory where the beans will be looked on.Copyright © 2021 Hitachi Vantara. All rights reserved.