Class OSGiVaadinServlet

  • All Implemented Interfaces:
    Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

    public class OSGiVaadinServlet
    extends com.vaadin.flow.server.VaadinServlet
    The Vaadin servlet to use in OSGi.

    Extend this servlet to use Vaadin in OSGi in case VaadinServlet doesn't work out of the box. That may happen in OSGi HTTP Whiteboard specification has some limitations regarding to ServletContextListener support. There is no need to use OSGiVaadinServlet at all if ServletContextListener.contextInitialized(javax.servlet.ServletContextEvent) is called regardless of bundles deployment order and filtering based on "osgi.http.whiteboard.context.select" property is properly working.

    Since:
    Author:
    Vaadin Ltd
    See Also:
    Serialized Form
    • Field Summary

      • Fields inherited from class com.vaadin.flow.server.VaadinServlet

        INTERNAL_VAADIN_SERVLET_VITE_DEV_MODE_FRONTEND_PATH
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void destroy()  
      void init​(javax.servlet.ServletConfig servletConfig)  
      • Methods inherited from class com.vaadin.flow.server.VaadinServlet

        createDeploymentConfiguration, createDeploymentConfiguration, createServletService, createServletService, createStaticFileHandler, createVaadinRequest, getCurrent, getFrontendMapping, getLastPathParameter, getService, getServletConfig, handleContextOrServletRootWithoutSlash, serveStaticOrWebJarRequest, service, servletInitialized
      • Methods inherited from class javax.servlet.http.HttpServlet

        doDelete, doGet, doHead, doOptions, doPost, doPut, doTrace, getLastModified, service
      • Methods inherited from class javax.servlet.GenericServlet

        getInitParameter, getInitParameterNames, getServletContext, getServletInfo, getServletName, init, log, log
    • Constructor Detail

      • OSGiVaadinServlet

        public OSGiVaadinServlet()
    • Method Detail

      • init

        public void init​(javax.servlet.ServletConfig servletConfig)
                  throws javax.servlet.ServletException
        Specified by:
        init in interface javax.servlet.Servlet
        Overrides:
        init in class com.vaadin.flow.server.VaadinServlet
        Throws:
        javax.servlet.ServletException
      • destroy

        public void destroy()
        Specified by:
        destroy in interface javax.servlet.Servlet
        Overrides:
        destroy in class com.vaadin.flow.server.VaadinServlet