binlog: use node.Restore()
to add TiDB-specified feature comments
#31147
Labels
type/enhancement
The issue or PR belongs to an enhancement.
Enhancement
For TiDB-specified features like
AUTO_RANDOM
attributes, we comment them in TiDB-specified comments for binlog-based replication(deprecated, but still used by some customers) and TiCDC.After pingcap/tiflow#3755, TiCDC used the
node.Restore()
method fromparser
to add the comments in pingcap/tiflow#3845, rather than the regex-based way for binlog.Although using
node.Restore()
is slower than regex, IMO it's better to adoptnode.Restore()
to replace the regex implementation for basically 2 reasons:The text was updated successfully, but these errors were encountered: