public class DefaultReceiverHeadersInterceptor
extends java.lang.Object
message interceptor that is able to add some commonly required header attributes in
Synapse services.
The DefaultReceiverHeadersInterceptor is active by default for all
receiver endpoints. It can be disabled by
setting 'synapse.receiver.default-headers.enabled=false'.
| Constructor and Description |
|---|
DefaultReceiverHeadersInterceptor(SynapseProperties synapseProperties)
Creates a new DefaultReceiverHeadersInterceptor with default configuration.
|
DefaultReceiverHeadersInterceptor(SynapseProperties synapseProperties,
java.time.Clock clock)
Creates an instance of DefaultReceiverHeadersInterceptor for testing purposes.
|
| Modifier and Type | Method and Description |
|---|---|
Message<java.lang.String> |
addDefaultHeaders(Message<java.lang.String> message) |
public DefaultReceiverHeadersInterceptor(SynapseProperties synapseProperties)
synapseProperties - the properties used to configure the interceptorpublic DefaultReceiverHeadersInterceptor(SynapseProperties synapseProperties, java.time.Clock clock)
synapseProperties - the properties used to configure the interceptorclock - the clock used to generate timestamp attributes@Nullable @MessageInterceptor(endpointType=RECEIVER) public Message<java.lang.String> addDefaultHeaders(@Nonnull Message<java.lang.String> message)