Class RecordConverter

  • All Implemented Interfaces:
    MessageConverter, javax.enterprise.inject.spi.Prioritized

    @ApplicationScoped
    public class RecordConverter
    extends Object
    implements MessageConverter
    Convert an incoming Kafka message into a Record.
    • Constructor Detail

      • RecordConverter

        public RecordConverter()
    • Method Detail

      • canConvert

        public boolean canConvert​(Message<?> in,
                                  Type target)
        Description copied from interface: MessageConverter
        Checks whether this instance of converter can convert the given message in into a Message<T> with T being the type represented by target. When reactive messaging looks for a converter, it picks the first converter returning true for a given message.
        Specified by:
        canConvert in interface MessageConverter
        Parameters:
        in - the input message, not null
        target - the target type, generally the type ingested by a method
        Returns:
        true if the conversion is possible, false otherwise.