cmu-db / peloton

The Self-Driving Database Management System
http://pelotondb.io
Apache License 2.0
2.03k stars 623 forks source link

Infinite loop in select * when there is an uncommitted update towards pg_table #1297

Open DeanChensj opened 6 years ago

DeanChensj commented 6 years ago

This is from PR-1289 #1289

In our PR, we add support for ALTER TABLE RENAME column, where we made modification to the catalog, columnCatalog and the pg_table.

The failure happens when you :

  1. begin a transaction
  2. do alter table, does not commit
  3. begin another transaction to select *

The second transaction will trap into an infinite loop in the src/executor/index_scan_executor.cpp. In the log trace of ExecSecondaryIndexLookup, there's 'passed evaluation, but txn read fails'. After that src/planner/index_scan_plan.cpp will start create another index scan plan...