regExReplacer
Description
Runs a regular-expression-replacement on either the message body (default) or all header values.
Can be used in
spring:beans, api, bean, if, interceptor, internalProxy, proxy, registration, request, response, serviceProxy, soapProxy, stompProxy, swaggerProxy, transport and wsStompReassembler
Syntax
<regExReplacer regex="string" replace="string" target="header|body" />
Listing 1: regExReplacer Syntax
Sample
<serviceProxy port="2000"> <regExReplacer regex="Hallo" replace="Hello" /> </serviceProxy>
Listing 2: regExReplacer Example
Attributes
Name | Required | Default | Description | Example |
---|---|---|---|---|
regex | true | - | Regex to match against the body. | Hallo |
replace | true | - | String used to replace matched parts. | Hello |
target | false | body | Whether the replacement should affect the message body or the header values. Possible values are body and header. | header |