Class WebServerComponent

  • All Implemented Interfaces:
    org.apache.activemq.artemis.components.ExternalComponent, org.apache.activemq.artemis.core.server.ActiveMQComponent, org.apache.activemq.artemis.core.server.ServiceComponent, org.apache.activemq.artemis.marker.WebServerComponentMarker

    public class WebServerComponent
    extends java.lang.Object
    implements org.apache.activemq.artemis.components.ExternalComponent, org.apache.activemq.artemis.marker.WebServerComponentMarker
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String DIR_ALLOWED  
    • Method Summary

      All Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      void cleanupWebTemporaryFiles​(java.util.List<org.eclipse.jetty.webapp.WebAppContext> webContexts)  
      void configure​(org.apache.activemq.artemis.dto.ComponentDTO config, java.lang.String artemisInstance, java.lang.String artemisHome)  
      protected org.eclipse.jetty.webapp.WebAppContext createWebAppContext​(java.lang.String url, java.lang.String warFile, java.nio.file.Path warDirectory, java.lang.String virtualHost)  
      int getPort()
      Deprecated.
      int getPort​(int connectorIndex)  
      java.util.List<org.eclipse.jetty.webapp.WebAppContext> getWebContexts()  
      boolean isStarted()  
      void start()  
      void stop()  
      void stop​(boolean isShutdown)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface org.apache.activemq.artemis.core.server.ActiveMQComponent

        asyncStop
    • Constructor Detail

      • WebServerComponent

        public WebServerComponent()
    • Method Detail

      • configure

        public void configure​(org.apache.activemq.artemis.dto.ComponentDTO config,
                              java.lang.String artemisInstance,
                              java.lang.String artemisHome)
                       throws java.lang.Exception
        Specified by:
        configure in interface org.apache.activemq.artemis.components.ExternalComponent
        Throws:
        java.lang.Exception
      • start

        public void start()
                   throws java.lang.Exception
        Specified by:
        start in interface org.apache.activemq.artemis.core.server.ActiveMQComponent
        Throws:
        java.lang.Exception
      • cleanupWebTemporaryFiles

        public void cleanupWebTemporaryFiles​(java.util.List<org.eclipse.jetty.webapp.WebAppContext> webContexts)
                                      throws java.lang.Exception
        Throws:
        java.lang.Exception
      • isStarted

        public boolean isStarted()
        Specified by:
        isStarted in interface org.apache.activemq.artemis.core.server.ActiveMQComponent
      • getPort

        @Deprecated
        public int getPort()
        Deprecated.
        Returns:
        started server's port number; useful if it was specified as 0 (to use a random port)
      • getPort

        public int getPort​(int connectorIndex)
      • createWebAppContext

        protected org.eclipse.jetty.webapp.WebAppContext createWebAppContext​(java.lang.String url,
                                                                             java.lang.String warFile,
                                                                             java.nio.file.Path warDirectory,
                                                                             java.lang.String virtualHost)
      • stop

        public void stop()
                  throws java.lang.Exception
        Specified by:
        stop in interface org.apache.activemq.artemis.core.server.ActiveMQComponent
        Throws:
        java.lang.Exception
      • stop

        public void stop​(boolean isShutdown)
                  throws java.lang.Exception
        Specified by:
        stop in interface org.apache.activemq.artemis.core.server.ServiceComponent
        Throws:
        java.lang.Exception
      • getWebContexts

        public java.util.List<org.eclipse.jetty.webapp.WebAppContext> getWebContexts()