Uploaded image for project: 'Teiid'
  1. Teiid
  2. TEIID-881

SOAP Connector should expose property to control HTTP Header Transfer-Encoding: chunked

XMLWordPrintable

    • Icon: Feature Request Feature Request
    • Resolution: Obsolete
    • Icon: Major Major
    • 7.0
    • 6.0.0
    • XML Connector
    • None

      A user has reported that results from a SOAP service using the SOAP-Relational connector are sometimes invalid. This is due to the results from an earlier invocation being returned. After further investigation this turned out to be a bug with the web server that was hosting the web service and its inability to properly handle chunked requests.

      By default, Axis 1.3/2 (not sure what we are using lately) uses chunked Transfer-Encoding. By disabling chunked transfer encoding it allows the faulty web server to properly serve the request and return the expected results.

      Ideally, chunked requests should be used as per the default Axis configuration but we should expose a means of overriding this behaviour in the event a user runs across a buggy web server.

      For example, in SOAPExecutor chunked requests can be enabled/disabled via a setting in the Call properties.

      Boolean isChunked = ((HTTPConnectorState) this.getState()).isHttpHeaderTransferEncodingChunked();
      if (isChunked != null) {
      Hashtable httpProps = (Hashtable) call.getProperty(HTTPConstants.REQUEST_HEADERS);
      if (httpProps == null)

      { httpProps = new Hashtable(); }

      httpProps.put(HTTPConstants.HEADER_TRANSFER_ENCODING_CHUNKED, isChunked);
      call.setProperty(HTTPConstants.REQUEST_HEADERS, httpProps);
      }

      Please note, this code was written against Axis 1.3 which is used in XML-Relational SOAP Connector for MMx 5.5.3.

        1. transfer-encoding-test.tar.gz
          2 kB
          Larry O'Leary

              Unassigned Unassigned
              rhn-support-loleary Larry O'Leary
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: