You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
create table t (c_int int, d_int int, primary key (c_int), key(d_int)) partition by hash (c_int) partitions 4 ;
insert into t values (1, 2);
(session 1)
begin pessimistic;
select * from t where d_int in (select d_int from t where c_int = 1) for update;
(session 2)
begin pessimistic;
select * from t where d_int = 2 for update;
2. What did you expect to see? (Required)
Session 1 and session 2 tries to acquire the lock for the same record, so one of them should be blocked and waited for the lock.
3. What did you see instead (Required)
Neither select ... for update is blocked.
4. What is your TiDB version? (Required)
I reproduced this bug in the latest master, but it should be reproduced in all existing releases that support pessimistic lock and (hash?) partitions.
5. Additional information
This bug is actually found when @blacktear23 trying to solve #21509, both of the bugs are caused by the same reason. You can check #21509 for more details.
The text was updated successfully, but these errors were encountered:
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
2. What did you expect to see? (Required)
Session 1 and session 2 tries to acquire the lock for the same record, so one of them should be blocked and waited for the lock.
3. What did you see instead (Required)
Neither
select ... for update
is blocked.4. What is your TiDB version? (Required)
I reproduced this bug in the latest master, but it should be reproduced in all existing releases that support pessimistic lock and (hash?) partitions.
5. Additional information
This bug is actually found when @blacktear23 trying to solve #21509, both of the bugs are caused by the same reason. You can check #21509 for more details.
The text was updated successfully, but these errors were encountered: