Package org.opensaml.soap.client.http

# Class HttpSOAPClient

java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
org.opensaml.soap.client.http.HttpSOAPClient

All Implemented Interfaces:
  `Component`, `DestructableComponent`, `InitializableComponent`, `SOAPClient`

@ThreadSafe @Deprecated public class HttpSOAPClient extends AbstractInitializableComponent implements SOAPClient
Deprecated.
use instead a concrete implementation of `AbstractPipelineHttpSOAPClient`, such as `PipelineFactoryHttpSOAPClient`
SOAP client that uses HTTP as the underlying transport and POST as the binding.

## Nested Class Summary

## Nested classes/interfaces inherited from interface org.opensaml.soap.client.SOAPClient

`SOAPClient.SOAPRequestParameters`

## Field Summary

Fields
Modifier and Type
Field
Description
`private org.apache.hc.client5.http.classic.HttpClient`
`httpClient`
Deprecated.
HTTP client used to send requests and receive responses.
`private final org.slf4j.Logger`
`log`
Deprecated.
Class logger.
`private ParserPool`
`parserPool`
Deprecated.
Pool of XML parsers used to parser incoming responses.
`private Function<MessageContext,SOAP11Context>`
`soap11ContextLookupStrategy`
Deprecated.
Strategy used to look up the `SOAP11Context` associated with the outbound message context.
`private Function<MessageContext,SOAPClientContext>`
`soapClientContextLookupStrategy`
Deprecated.
Strategy used to look up the `SOAPClientContext` associated with the outbound message context.

## Constructor Summary

Constructors
Constructor
Description
`HttpSOAPClient()`
Deprecated.
Constructor.

## Method Summary

Modifier and Type
Method
Description
`protected org.apache.hc.client5.http.classic.methods.HttpPost`
`createPostMethod(String endpoint, HttpSOAPRequestParameters requestParams, Envelope message)`
Deprecated.
Create the post method used to send the SOAP request.
`protected org.apache.hc.core5.http.HttpEntity`
`createRequestEntity(Envelope message, Charset charset)`
Deprecated.
Create the request entity that makes up the POST message body.
`protected void`
`doInitialize()`
Deprecated.
`Function<MessageContext,SOAP11Context>`
`getSOAP11ContextLookupStrategy()`
Deprecated.
Get the strategy used to look up the `SOAP11Context` associated with the outbound message context.
`Function<MessageContext,SOAPClientContext>`
`getSOAPClientContextLookupStrategy()`
Deprecated.
Get the strategy used to look up the `SOAPClientContext` associated with the outbound message context.
`protected void`
`processFaultResponse(org.apache.hc.core5.http.ClassicHttpResponse httpResponse, InOutOperationContext context)`
Deprecated.
Process a SOAP fault, as determined by an HTTP 500 status code, response.
`protected void`
`processSuccessfulResponse(org.apache.hc.core5.http.ClassicHttpResponse httpResponse, InOutOperationContext context)`
Deprecated.
Process a successful, as determined by an HTTP 200 status code, response.
`void`
`send(String endpoint, InOutOperationContext context)`
Deprecated.
Sends a message and waits for a response.
`void`
`setHttpClient(org.apache.hc.client5.http.classic.HttpClient client)`
Deprecated.
Set the client used to make outbound HTTP requests.
`void`
`setParserPool(ParserPool parser)`
Deprecated.
Set the pool of XML parsers used to parse incoming responses.
`void`
`setSOAP11ContextLookupStrategy(Function<MessageContext,SOAP11Context> strategy)`
Deprecated.
Set the strategy used to look up the `SOAP11Context` associated with the outbound message context.
`void`
`setSOAPClientContextLookupStrategy(Function<MessageContext,SOAPClientContext> strategy)`
Deprecated.
Set the strategy used to look up the `SOAPClientContext` associated with the outbound message context.
`protected Envelope`
`unmarshallResponse(InputStream responseStream)`
Deprecated.
Unmarshall the incoming response from a POST request.

### Methods inherited from class net.shibboleth.shared.component.AbstractInitializableComponent

`checkComponentActive, checkSetterPreconditions, destroy, doDestroy, ifDestroyedThrowDestroyedComponentException, ifInitializedThrowUnmodifiabledComponentException, ifNotInitializedThrowUninitializedComponentException, initialize, isDestroyed, isInitialized`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### log

@Nonnull private final org.slf4j.Logger log
Deprecated.
Class logger.

### httpClient

@NonnullAfterInit private org.apache.hc.client5.http.classic.HttpClient httpClient
Deprecated.
HTTP client used to send requests and receive responses.

### parserPool

@NonnullAfterInit private ParserPool parserPool
Deprecated.
Pool of XML parsers used to parser incoming responses.

### soapClientContextLookupStrategy

@Nonnull private Function<MessageContext,SOAPClientContext> soapClientContextLookupStrategy
Deprecated.
Strategy used to look up the `SOAPClientContext` associated with the outbound message context.

### soap11ContextLookupStrategy

@Nonnull private Function<MessageContext,SOAP11Context> soap11ContextLookupStrategy
Deprecated.
Strategy used to look up the `SOAP11Context` associated with the outbound message context.

## Constructor Details

### HttpSOAPClient

public HttpSOAPClient()
Deprecated.
Constructor.

## Method Details

### doInitialize

protected void doInitialize() throws ComponentInitializationException
Deprecated.

Overrides:
  `doInitialize` in class `AbstractInitializableComponent`
Throws:
  `ComponentInitializationException`

### setHttpClient

public void setHttpClient(@Nonnull org.apache.hc.client5.http.classic.HttpClient client)
Deprecated.
Set the client used to make outbound HTTP requests.

This client SHOULD employ a thread-safe `HttpClient` and may be shared with other objects.

Parameters:
  `client` - client object

### setParserPool

public void setParserPool(@Nonnull ParserPool parser)
Deprecated.
Set the pool of XML parsers used to parse incoming responses.

Parameters:
  `parser` - parser pool

### getSOAPClientContextLookupStrategy

@Nonnull public Function<MessageContext,SOAPClientContext> getSOAPClientContextLookupStrategy()
Deprecated.
Get the strategy used to look up the `SOAPClientContext` associated with the outbound message context.

Returns:
  strategy used to look up the `SOAPClientContext` associated with the outbound message context

### setSOAPClientContextLookupStrategy

public void setSOAPClientContextLookupStrategy(@Nonnull Function<MessageContext,SOAPClientContext> strategy)
Deprecated.
Set the strategy used to look up the `SOAPClientContext` associated with the outbound message context.

Parameters:
  `strategy` - strategy used to look up the `SOAPClientContext` associated with the outbound message context

### getSOAP11ContextLookupStrategy

@Nonnull public Function<MessageContext,SOAP11Context> getSOAP11ContextLookupStrategy()
Deprecated.
Get the strategy used to look up the `SOAP11Context` associated with the outbound message context.

Returns:
  strategy used to look up the `SOAP11Context` associated with the outbound message context

### setSOAP11ContextLookupStrategy

public void setSOAP11ContextLookupStrategy(@Nonnull Function<MessageContext,SOAP11Context> strategy)
Deprecated.
Set the strategy used to look up the `SOAP11Context` associated with the outbound message context.

Parameters:
  `strategy` - strategy used to look up the `SOAP11Context` associated with the outbound message context

### send

public void send(@Nonnull @NotEmpty String endpoint, @Nonnull InOutOperationContext context) throws SOAPException, SecurityException
Deprecated.
Sends a message and waits for a response.

Specified by:
  `send` in interface `SOAPClient`
Parameters:
  `endpoint` - the endpoint to which to send the message
  `context` - the operation context containing the outbound SOAP message
Throws:
  `SOAPException` - thrown if there is a problem sending the message or receiving the response or if the response is a SOAP fault
  `SecurityException` - thrown if the response does not meet any security policy associated with the message context

### createPostMethod

protected org.apache.hc.client5.http.classic.methods.HttpPost createPostMethod(@Nonnull @NotEmpty String endpoint, @Nullable HttpSOAPRequestParameters requestParams, @Nonnull Envelope message) throws SOAPClientException
Deprecated.
Create the post method used to send the SOAP request.

Parameters:
  `endpoint` - endpoint to which the message is sent
  `requestParams` - HTTP request parameters
  `message` - message to be sent
Returns:
  the post method to be used to send this message
Throws:
  `SOAPClientException` - thrown if the message could not be marshalled

### createRequestEntity

@Nonnull protected org.apache.hc.core5.http.HttpEntity createRequestEntity(@Nonnull Envelope message, @Nullable Charset charset) throws SOAPClientException
Deprecated.
Create the request entity that makes up the POST message body.

Parameters:
  `message` - message to be sent
  `charset` - character set used for the message
Returns:
  request entity that makes up the POST message body
Throws:
  `SOAPClientException` - thrown if the message could not be marshalled

### processSuccessfulResponse

protected void processSuccessfulResponse(@Nonnull org.apache.hc.core5.http.ClassicHttpResponse httpResponse, @Nonnull InOutOperationContext context) throws SOAPClientException
Deprecated.
Process a successful, as determined by an HTTP 200 status code, response.

Parameters:
  `httpResponse` - the HTTP response
  `context` - current operation context
Throws:
  `SOAPClientException` - thrown if there is a problem reading the response from the `HttpPost`

### processFaultResponse

protected void processFaultResponse(@Nonnull org.apache.hc.core5.http.ClassicHttpResponse httpResponse, @Nonnull InOutOperationContext context) throws SOAPClientException, SOAPFaultException
Deprecated.
Process a SOAP fault, as determined by an HTTP 500 status code, response.

Parameters:
  `httpResponse` - the HTTP response
  `context` - current operation context
Throws:
  `SOAPClientException` - thrown if the response can not be read from the `HttpPost`
  `SOAPFaultException` - an exception containing the SOAP fault

### unmarshallResponse

@Nonnull protected Envelope unmarshallResponse(@Nonnull InputStream responseStream) throws SOAPClientException
Deprecated.
Unmarshall the incoming response from a POST request.

Parameters:
  `responseStream` - input stream bearing the response
Returns:
  the response
Throws:
  `SOAPClientException` - thrown if the incoming response can not be unmarshalled into an `Envelope`