Class ExtractNewRecordState.FieldReference

java.lang.Object
io.debezium.transforms.ExtractNewRecordState.FieldReference
Enclosing class:
ExtractNewRecordState<R extends org.apache.kafka.connect.connector.ConnectRecord<R>>

private static class ExtractNewRecordState.FieldReference extends Object
Represents a field that should be added to the outgoing record as a header attribute or struct field.
  • Field Details

    • struct

      private final String struct
      The struct ("source", "transaction") hosting the given field, or null for "op" and "ts_ms".
    • field

      private final String field
      The simple field name.
    • newField

      private final String newField
      The name for the outgoing attribute/field, e.g. "__op" or "__source_ts_ms" when the prefix is "__"
  • Constructor Details

    • FieldReference

      private FieldReference(String prefix, String field)
  • Method Details

    • determineStruct

      private static String determineStruct(String simpleFieldName)
      Determines the struct hosting the given unqualified field.
    • fromConfiguration

      static List<ExtractNewRecordState.FieldReference> fromConfiguration(String fieldPrefix, String addHeadersConfig)
    • getNewField

      public String getNewField()
    • getValue

      Object getValue(org.apache.kafka.connect.data.Struct originalRecordValue)
    • getSchema

      org.apache.kafka.connect.data.Schema getSchema(org.apache.kafka.connect.data.Schema originalRecordSchema)