(name string)
| 1601 | } |
| 1602 | |
| 1603 | func normalizeBinlogFilename(name string) string { |
| 1604 | // See `posUUIDSuffixSeparator` in pingcap/dm. |
| 1605 | re := regexp.MustCompile("^(.*)\\|.+(\\..*)$") |
| 1606 | sm := re.FindStringSubmatch(name) |
| 1607 | if len(sm) == 3 { |
| 1608 | return sm[1] + sm[2] |
| 1609 | } else { |
| 1610 | return name |
| 1611 | } |
| 1612 | } |
| 1613 | |
| 1614 | func (b *BinlogReader) GetQueueSize() int { |
| 1615 | if b != nil && b.binlogStreamer0 != nil { |