throw new SOAPClientException("HTTP status code was 500 but SOAP response did not contain a Fault");
}
Fault fault = (Fault) faults.get(0);
log.debug("SOAP fault code {} with message {}", fault.getCode().getValue(), fault.getMessage().getValue());
SOAPFaultException faultException = new SOAPFaultException("SOAP Fault: " + fault.getCode().getValue()
+ " Fault Message: " + fault.getMessage().getValue());
faultException.setFault(fault);
throw faultException;
} catch (IOException e) {
throw new SOAPClientException("Unable to read response", e);
}
}