potential DATA RACE in update operation #25496
Labels
component/test
severity/minor
sig/transaction
SIG:Transaction
type/bug
The issue is confirmed as a bug.
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
It is found in CI of #21148 but not necessarily caused by that change.
Update executor will read data from its children executor and write the data to the unistore, the children executor maybe
running concurrently, so there will be goroutine reading from the unistore, and at the same time some goroutine writing the unistore. This is potential risky, especially when the selectLock executor exists: selectLock is a read executor but it also write locks to the unistore.
The data race affect the unistore engine, the tikv engine is not affected, because lockKeys on TiKV will marthal the data and send the distsql request.
2. What did you expect to see? (Required)
No data race
3. What did you see instead (Required)
data race
4. What is your TiDB version? (Required)
#21148
The text was updated successfully, but these errors were encountered: