Class KafkaCloudEventHelper
- java.lang.Object
-
- io.smallrye.reactive.messaging.kafka.impl.ce.KafkaCloudEventHelper
-
public class KafkaCloudEventHelper extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
KafkaCloudEventHelper.CloudEventMode
-
Field Summary
Fields Modifier and Type Field Description static String
CE_CONTENT_TYPE_PREFIX
static String
CE_HEADER_PREFIX
static String
KAFKA_HEADER_CONTENT_TYPE
static String
KAFKA_HEADER_FOR_CONTENT_TYPE
static String
KAFKA_HEADER_FOR_ID
static String
KAFKA_HEADER_FOR_SCHEMA
static String
KAFKA_HEADER_FOR_SOURCE
static String
KAFKA_HEADER_FOR_SPEC_VERSION
static String
KAFKA_HEADER_FOR_SUBJECT
static String
KAFKA_HEADER_FOR_TIME
static String
KAFKA_HEADER_FOR_TYPE
static DateTimeFormatter
RFC3339_DATE_FORMAT
static String
STRUCTURED_CONTENT_TYPE
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static org.apache.kafka.clients.producer.ProducerRecord<?,?>
createBinaryRecord(Message<?> message, String topic, OutgoingKafkaRecordMetadata<?> metadata, OutgoingCloudEventMetadata<?> ceMetadata, KafkaConnectorOutgoingConfiguration configuration)
static <T,K>
IncomingKafkaCloudEventMetadata<K,T>createFromBinaryCloudEvent(io.vertx.mutiny.kafka.client.consumer.KafkaConsumerRecord<?,T> record)
static <T,K>
IncomingKafkaCloudEventMetadata<K,T>createFromStructuredCloudEvent(io.vertx.mutiny.kafka.client.consumer.KafkaConsumerRecord<K,T> record)
static org.apache.kafka.clients.producer.ProducerRecord<?,?>
createStructuredRecord(Message<?> message, String topic, OutgoingKafkaRecordMetadata<?> metadata, OutgoingCloudEventMetadata<?> ceMetadata, KafkaConnectorOutgoingConfiguration configuration)
static KafkaCloudEventHelper.CloudEventMode
getCloudEventMode(io.vertx.mutiny.kafka.client.consumer.KafkaConsumerRecord<?,?> record)
-
-
-
Field Detail
-
KAFKA_HEADER_CONTENT_TYPE
public static final String KAFKA_HEADER_CONTENT_TYPE
- See Also:
- Constant Field Values
-
CE_CONTENT_TYPE_PREFIX
public static final String CE_CONTENT_TYPE_PREFIX
- See Also:
- Constant Field Values
-
CE_HEADER_PREFIX
public static final String CE_HEADER_PREFIX
- See Also:
- Constant Field Values
-
STRUCTURED_CONTENT_TYPE
public static final String STRUCTURED_CONTENT_TYPE
- See Also:
- Constant Field Values
-
KAFKA_HEADER_FOR_SPEC_VERSION
public static final String KAFKA_HEADER_FOR_SPEC_VERSION
- See Also:
- Constant Field Values
-
KAFKA_HEADER_FOR_TYPE
public static final String KAFKA_HEADER_FOR_TYPE
- See Also:
- Constant Field Values
-
KAFKA_HEADER_FOR_SOURCE
public static final String KAFKA_HEADER_FOR_SOURCE
- See Also:
- Constant Field Values
-
KAFKA_HEADER_FOR_ID
public static final String KAFKA_HEADER_FOR_ID
- See Also:
- Constant Field Values
-
KAFKA_HEADER_FOR_SCHEMA
public static final String KAFKA_HEADER_FOR_SCHEMA
- See Also:
- Constant Field Values
-
KAFKA_HEADER_FOR_CONTENT_TYPE
public static final String KAFKA_HEADER_FOR_CONTENT_TYPE
- See Also:
- Constant Field Values
-
KAFKA_HEADER_FOR_SUBJECT
public static final String KAFKA_HEADER_FOR_SUBJECT
- See Also:
- Constant Field Values
-
KAFKA_HEADER_FOR_TIME
public static final String KAFKA_HEADER_FOR_TIME
- See Also:
- Constant Field Values
-
RFC3339_DATE_FORMAT
public static final DateTimeFormatter RFC3339_DATE_FORMAT
-
-
Method Detail
-
createFromStructuredCloudEvent
public static <T,K> IncomingKafkaCloudEventMetadata<K,T> createFromStructuredCloudEvent(io.vertx.mutiny.kafka.client.consumer.KafkaConsumerRecord<K,T> record)
-
createFromBinaryCloudEvent
public static <T,K> IncomingKafkaCloudEventMetadata<K,T> createFromBinaryCloudEvent(io.vertx.mutiny.kafka.client.consumer.KafkaConsumerRecord<?,T> record)
-
createBinaryRecord
public static org.apache.kafka.clients.producer.ProducerRecord<?,?> createBinaryRecord(Message<?> message, String topic, OutgoingKafkaRecordMetadata<?> metadata, OutgoingCloudEventMetadata<?> ceMetadata, KafkaConnectorOutgoingConfiguration configuration)
-
createStructuredRecord
public static org.apache.kafka.clients.producer.ProducerRecord<?,?> createStructuredRecord(Message<?> message, String topic, OutgoingKafkaRecordMetadata<?> metadata, OutgoingCloudEventMetadata<?> ceMetadata, KafkaConnectorOutgoingConfiguration configuration)
-
getCloudEventMode
public static KafkaCloudEventHelper.CloudEventMode getCloudEventMode(io.vertx.mutiny.kafka.client.consumer.KafkaConsumerRecord<?,?> record)
-
-