Class PassThroughNHttpGetProcessor

  • All Implemented Interfaces:
    org.apache.synapse.transport.passthru.HttpGetRequestProcessor

    public class PassThroughNHttpGetProcessor
    extends AbstractHttpGetRequestProcessor
    implements org.apache.synapse.transport.passthru.HttpGetRequestProcessor
    Get Processor implementation for PassThrough Transport.
    • Constructor Detail

      • PassThroughNHttpGetProcessor

        public PassThroughNHttpGetProcessor()
    • Method Detail

      • init

        public void init​(org.apache.axis2.context.ConfigurationContext configurationContext,
                         org.apache.synapse.transport.passthru.SourceHandler sourceHandler)
                  throws org.apache.axis2.AxisFault
        Specified by:
        init in interface org.apache.synapse.transport.passthru.HttpGetRequestProcessor
        Throws:
        org.apache.axis2.AxisFault
      • process

        public void process​(org.apache.http.HttpRequest request,
                            org.apache.http.HttpResponse response,
                            org.apache.axis2.context.MessageContext messageContext,
                            org.apache.http.nio.NHttpServerConnection conn,
                            OutputStream outputStream,
                            boolean b)
        Specified by:
        process in interface org.apache.synapse.transport.passthru.HttpGetRequestProcessor
      • generateServicesList

        protected void generateServicesList​(org.apache.http.HttpResponse response,
                                            org.apache.http.nio.NHttpServerConnection conn,
                                            OutputStream os,
                                            String servicePath)
        Generates the services list.
        Parameters:
        response - HttpResponse
        conn - NHttpServerConnection
        os - OutputStream
        servicePath - service path of the service
      • isServiceListBlocked

        protected boolean isServiceListBlocked​(String incomingURI)
        Is the incoming URI is requesting service list and http.block_service_list=true in nhttp.properties
        Parameters:
        incomingURI - incoming URI
        Returns:
        whether to proceed with incomingURI
      • handleBrowserException

        protected void handleBrowserException​(org.apache.http.HttpResponse response,
                                              org.apache.http.nio.NHttpServerConnection conn,
                                              OutputStream os,
                                              String msg,
                                              Exception e)
        Handles browser exception.
        Parameters:
        response - HttpResponse
        conn - NHttpServerConnection
        os - OutputStream
        msg - message
        e - Exception