@Singleton
public class SchemaResolver
extends java.lang.Object
| Constructor and Description |
|---|
SchemaResolver(com.fasterxml.jackson.databind.ObjectMapper objectMapper) |
| Modifier and Type | Method and Description |
|---|---|
org.apache.pulsar.client.api.Schema<?> |
decideSchema(io.micronaut.core.annotation.AnnotationValue<?> topicAnnotation,
java.lang.Class<?> messageBodyType)
Resolve which schema to use.
|
public SchemaResolver(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
public org.apache.pulsar.client.api.Schema<?> decideSchema(io.micronaut.core.annotation.AnnotationValue<?> topicAnnotation,
java.lang.Class<?> messageBodyType)
topicAnnotation - either producer or consumer annotationmessageBodyType - type of message body used with Pulsar topic