Class AdapterUtils
java.lang.Object
org.springframework.kafka.listener.adapter.AdapterUtils
Utilities for listener adapters.
- Since:
- 2.5
-
Field Summary
Modifier and TypeFieldDescriptionstatic final org.springframework.expression.ParserContext
Parser context for runtime SpEL using ! as the template prefix. -
Method Summary
Modifier and TypeMethodDescriptionstatic ConsumerRecordMetadata
Build aConsumerRecordMetadata
from data which must be aConsumerRecord
.static Object
Build aConsumerRecordMetadata
from the firstConsumerRecord
in data, if any.static String
Return the default expression when no SendTo value is present.
-
Field Details
-
PARSER_CONTEXT
public static final org.springframework.expression.ParserContext PARSER_CONTEXTParser context for runtime SpEL using ! as the template prefix.- Since:
- 2.2.15
-
-
Method Details
-
buildConsumerRecordMetadataFromArray
Build aConsumerRecordMetadata
from the firstConsumerRecord
in data, if any.- Parameters:
data
- the data array.- Returns:
- the metadata or null if data does not contain a
ConsumerRecord
.
-
buildConsumerRecordMetadata
Build aConsumerRecordMetadata
from data which must be aConsumerRecord
.- Parameters:
data
- the record.- Returns:
- the metadata or null if data is not a
ConsumerRecord
.
-
getDefaultReplyTopicExpression
Return the default expression when no SendTo value is present.- Returns:
- the expression.
- Since:
- 2.2.15
-