Closed thuyenptr closed 5 years ago
Tag: @july2993, please.
you are welcome to ask any question. sorry for not quite so understand your problem, what do you means "resolving item at start_ts = 5".
if it can't get any item from a pump, it will block to output data to downstream because it can't know which one is the minimum one.
"resolving item at start_ts = 5", I mean sorter will try to resolve Commit Binlog correspond with Prewrite Binlog (confirm commit_ts from TiKV).
You say: "if it can't get any item from a pump, it will block to output data to downstream", can you show me where the code says "block to output data to downstream"?. I can see in this code, skip nil source, but this still got items from any available source
Thank you for your support. I understood that concept.
Hi,
First, I'm sorry because I'm asking too much, but currently, I'm curious about the mechanism of TiDB-Binlog deeply.
When I read the code, I'm very confused about how drainer guarantees the order of Binlogs, in this situation:
When the maxCommitTS of 2 pump instance different, in this picture you can see
PullBinlog
pull all Binlog fromlast=3
tomaxCommitTS
of each pump instance and then transfer Binlog toMerger
. After that Merger gets min Binlog andAdd(item)
toSyncer
. WhenDrainer
calls PullBinlog again (interval = 10 seconds), unfortunately, Pump is resolving item at start_ts = 5, and pump2 working normally, and then I lose the order Binlog item (5,7,9,11).Can you explain this situation to me? Thank you.