Class HttpWebsocketEndpointManager

    • Constructor Detail

      • HttpWebsocketEndpointManager

        public HttpWebsocketEndpointManager()
    • Method Detail

      • startEndpoint

        public boolean startEndpoint​(int port,
                                     String name,
                                     org.apache.synapse.inbound.InboundProcessorParams inboundParameters)
        Description copied from interface: InboundEndpointManager
        Start Inbound endpoint on a particular port
        Parameters:
        port - port
        name - endpoint name
        inboundParameters - Inbound endpoint parameters
      • startSSLEndpoint

        public boolean startSSLEndpoint​(int port,
                                        String name,
                                        org.apache.synapse.inbound.InboundProcessorParams inboundParameters)
      • startListener

        public boolean startListener​(int port,
                                     String name,
                                     org.apache.synapse.inbound.InboundProcessorParams inboundParameters)
        Description copied from interface: InboundEndpointManager
        Start Listener on a particular port
        Parameters:
        port - port
        name - endpoint name
        inboundParameters - Inbound endpoint parameters
      • startSSLListener

        public boolean startSSLListener​(int port,
                                        String name,
                                        org.apache.synapse.inbound.InboundProcessorParams inboundParameters)
      • closeEndpoint

        public void closeEndpoint​(int port)
        Description copied from interface: InboundEndpointManager
        Stop Inbound Endpoint
        Parameters:
        port - port of the endpoint
      • isPortOccupied

        public static boolean isPortOccupied​(int port)
        Checks if the given port is available to use.
        Parameters:
        port - port
        Returns:
        true if the port is already used by another service
      • getHttpWebSocketInboundEndpointConfiguration

        public static org.apache.synapse.transport.netty.api.config.HttpWebSocketInboundEndpointConfiguration getHttpWebSocketInboundEndpointConfiguration​(int port,
                                                                                                                                                           String name,
                                                                                                                                                           org.apache.synapse.inbound.InboundProcessorParams params,
                                                                                                                                                           boolean isSSL)
        Builds the HttpWebSocketInboundEndpointConfiguration, which wraps all the necessary information to be used in the HttpWebSocketInboundEndpointHandler to start the transport listener.
        Parameters:
        port - port
        name - name of the inbound endpoint
        params - parameters defined in the inbound endpoint definition
        isSSL - whether this is secured
        Returns:
        HttpWebSocketInboundEndpointConfiguration
      • buildSSLConfiguration

        public static org.apache.synapse.transport.netty.api.config.SSLConfiguration buildSSLConfiguration​(org.apache.synapse.inbound.InboundProcessorParams params)
        Builds the SSLConfiguration to wrap all the security related parameters defined in the inbound endpoint.
        Parameters:
        params - parameters defined in the inbound endpoint definition
        Returns:
        SSLConfiguration