Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Use topics.regex instead of topics.pattern

...

This KIP introduces a new 'topics.patternregex' configuration option for Kafka Connect sinks that expects a string compatible with Java's regex Pattern class. Users may specify only one of 'topics' or 'topics.patternregex'.

Proposed Changes

If 'topics.patternregex' is specified, its string value will be used to instantiate a regex Pattern which will be passed to subscribe instead of a list of strings.

If both 'topics.patternregex' and 'topics' are specified, a ConfigException will be thrown to prevent startup.

Compatibility, Deprecation, and Migration Plan

'topics.patternregex' will default to the empty string "" so that existing configurations will not be affected by the additional option.

...

Additional regular expression specifications could be accommodated in the future by adding an additional configuration option 'topics.patternregex.type'.