Class RawToStringConverter

java.lang.Object
io.debezium.connector.oracle.converters.RawToStringConverter
All Implemented Interfaces:
io.debezium.spi.converter.CustomConverter<org.apache.kafka.connect.data.SchemaBuilder,io.debezium.spi.converter.RelationalColumn>

public class RawToStringConverter extends Object implements io.debezium.spi.converter.CustomConverter<org.apache.kafka.connect.data.SchemaBuilder,io.debezium.spi.converter.RelationalColumn>
Oracle emits all RAW columns as BYTES by default. There may be use cases where the event should emit the raw data as a STRING data type instead, and this converter can be used to easily convert the RAW column bytes into a string representation of the data.

If the RAW column cannot be expressed as string-based data, this converter should not be used.
Author:
Chris Cranford
  • Nested Class Summary

    Nested classes/interfaces inherited from interface io.debezium.spi.converter.CustomConverter

    io.debezium.spi.converter.CustomConverter.Converter, io.debezium.spi.converter.CustomConverter.ConverterRegistration<S extends Object>
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private static final String
     
    private static final org.slf4j.Logger
     
    private Predicate<io.debezium.spi.converter.RelationalColumn>
     
    static final String
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    configure(Properties properties)
     
    void
    converterFor(io.debezium.spi.converter.RelationalColumn field, io.debezium.spi.converter.CustomConverter.ConverterRegistration<org.apache.kafka.connect.data.SchemaBuilder> registration)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • RawToStringConverter

      public RawToStringConverter()
  • Method Details

    • configure

      public void configure(Properties properties)
      Specified by:
      configure in interface io.debezium.spi.converter.CustomConverter<org.apache.kafka.connect.data.SchemaBuilder,io.debezium.spi.converter.RelationalColumn>
    • converterFor

      public void converterFor(io.debezium.spi.converter.RelationalColumn field, io.debezium.spi.converter.CustomConverter.ConverterRegistration<org.apache.kafka.connect.data.SchemaBuilder> registration)
      Specified by:
      converterFor in interface io.debezium.spi.converter.CustomConverter<org.apache.kafka.connect.data.SchemaBuilder,io.debezium.spi.converter.RelationalColumn>