proxy
Configuration for an outbound HTTP proxy.
Defines the address, optional authentication credentials, and TLS configuration for connecting to a proxy.
Can be used as a child element in <httpClientConfig> to route client connections through a proxy server.
XML Example:
<proxy host="proxy.example.com" port="3128" authentication="true" username="user" password="secret">
<ssl keystoreLocation="classpath:proxy-client.jks" keystorePassword="changeit"/>
</proxy>
YAML (experimental):
proxy:
host: proxy.example.com
port: 3128
authentication: true
username: user
password: secret
ssl:
keystoreLocation: classpath:proxy-client.jks
keystorePassword: changeit
Can be used in:
httpClientConfig, router and bean
Syntax
<proxy name="string"
port="integer"
blockRequest="[true,false]"
blockResponse="[true,false]">
[interceptors]*
</proxy>
Sample
<proxy name="HTTP Proxy" port="3128" >
<transform xslt="strip.xslt"/>
<switch>
<case xPath="//convert" url="http://www.thomas-bayer.com/axis2/" />
</switch>
</proxy>
Attributes
| Name | Required | Default | Description | Examples |
| password |
false |
(not set)
|
Password for authenticating with the proxy server. Only used when authentication="true".
|
secret
|
| port |
false |
0
|
TCP port on which the proxy server is listening.
|
3128
|
| host |
false |
- |
The hostname or IP address of the proxy server. Required for proxy usage.
|
proxy.example.com
|
| username |
false |
(not set)
|
Username for authenticating with the proxy server. Only used when authentication="true".
|
user
|
| authentication |
false |
false
|
Whether to send a Basic Authentication header with proxy requests. If set to true, <username> and <password> must be provided.
|
- |