code: protected void validateResponse(HttpInvokerClientConfiguration config, PostMethod postMethod)
              throws IOException {
  
          if (postMethod.getStatusCode() >= 300) {
              throw new HttpException(
                      "Did not receive successful HTTP response: status code = " + postMethod.getStatusCode() +
                      ", status message = [" + postMethod.getStatusText() + "]");
          }
      }
docs: Validate the given response as contained in the PostMethod object,
  throwing an exception if it does not correspond to a successful HTTP response.
  <p>Default implementation rejects any HTTP status code beyond 2xx, to avoid
  parsing the response body and trying to deserialize from a corrupted stream.
  @param config the HTTP invoker configuration that specifies the target service
  @param postMethod the executed PostMethod to validate
  @throws IOException if validation failed
  @see org.apache.commons.httpclient.methods.PostMethod#getStatusCode()
  @see org.apache.commons.httpclient.HttpException