Class DefaultDebeziumHeaderMapper
java.lang.Object
org.springframework.integration.debezium.support.DefaultDebeziumHeaderMapper
- All Implemented Interfaces:
HeaderMapper<List<io.debezium.engine.Header<Object>>>
public class DefaultDebeziumHeaderMapper
extends Object
implements HeaderMapper<List<io.debezium.engine.Header<Object>>>
Specifies how to convert Debezium
ChangeEvent.headers()
into a MessageHeaders
.- Since:
- 6.2
- Author:
- Christian Tzolov, Artem Bilan
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
fromHeaders
(MessageHeaders headers, List<io.debezium.engine.Header<Object>> target) void
setHeaderNamesToMap
(String... headerNames) Comma-separated list of names of Debezium's Change Event headers to be mapped to the outbound Message headers.
-
Constructor Details
-
DefaultDebeziumHeaderMapper
public DefaultDebeziumHeaderMapper()
-
-
Method Details
-
setHeaderNamesToMap
Comma-separated list of names of Debezium's Change Event headers to be mapped to the outbound Message headers. The Debezium New Record State Extraction 'add.headers' property is used to configure the metadata to be set in the produced ChangeEvent headers. Note that you must prefix the 'headerNames' used the 'setHeaderNamesToMap' with the prefix configured by the 'add.headers.prefix' debezium property. Later defaults to '__'. For example for 'add.headers=op,name' and 'add.headers.prefix=__' you should use headerNames == "__op", "__name".- Parameters:
headerNames
- The values in this list can be a simple patterns to be matched against the header names.- See Also:
-
toHeaders
- Specified by:
toHeaders
in interfaceHeaderMapper<List<io.debezium.engine.Header<Object>>>
-
fromHeaders
- Specified by:
fromHeaders
in interfaceHeaderMapper<List<io.debezium.engine.Header<Object>>>
-