diff --git a/ee/katc/config.go b/ee/katc/config.go index fa45770d4..72e115e06 100644 --- a/ee/katc/config.go +++ b/ee/katc/config.go @@ -54,6 +54,13 @@ func (kst *katcSourceType) UnmarshalJSON(data []byte) error { } } +func (kst *katcSourceType) String() string { + if kst == nil { + return "" + } + return kst.name +} + // rowTransformStep defines an operation performed against a row of data // returned from a source. The `name` is the identifier parsed from the // JSON KATC config. diff --git a/ee/katc/table.go b/ee/katc/table.go index e27fda1a2..abeeca2c5 100644 --- a/ee/katc/table.go +++ b/ee/katc/table.go @@ -88,7 +88,7 @@ func newKatcTable(tableName string, cfg katcTableConfig, slogger *slog.Logger) ( // Add extra fields to slogger k.slogger = slogger.With( "table_name", tableName, - "table_type", cfg.SourceType, + "table_type", cfg.SourceType.String(), ) return &k, columns