Requests during a table's DELETING window answer differently from DynamoDB

Đang mở
#505 0 bình luận 0 reaction 1 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 4 ngày

@LeeroyHannigan đang làm issue này rồi.

Từ ngày 25/10/2026.

  • #550 của @LeeroyHannigan — đang mở

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
48/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
postgresql, rust
Lĩnh vực
backend, databases

Hướng nghiên cứu

Start with crates/storage-postgres/src/delete_table.rs and update_table.rs, then trace the data-plane table lookup that excludes DELETING rows. Compare the PostgreSQL behavior with the DynamoDB responses listed for the four requests; the other backends are unmeasured. Done means the control-plane requests return the stated service error and the data-plane behavior during deletion is decided and matches the service.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

bug postgresql

Summary

While a table is DELETING, ExtendDB answers four requests differently from DynamoDB. The service reports the window as a table that is still there and in use; ExtendDB reports it as a table that does not exist, or with a different sentence.

Measured on the service 2026-10-24 09:30 UTC (two repeats, identical) and on ExtendDB with the PostgreSQL backend at main 744ea291 and on #504, with the window held open by an ACCESS SHARE lock on the table's data table. The other backends are not measured here.

Request during the window ExtendDB DynamoDB
second DeleteTable 400 ResourceNotFoundException Requested resource not found 400 ResourceInUseException Attempt to change a resource which is still in use: Table is being deleted: <name>
UpdateTable (any member) 400 ResourceInUseException Table <name> is not in ACTIVE state 400 ResourceInUseException Attempt to change a resource which is still in use: Table is being deleted: <name>
PutItem 400 ResourceNotFoundException 200
GetItem 400 ResourceNotFoundException 200 with the item

DescribeTable (TableStatus DELETING) and CreateTable with the name (ResourceInUseException Table already exists: <name>) match the service.

Cause

crates/storage-postgres/src/delete_table.rs selects the row WHERE ... table_status IN ('ACTIVE', 'CREATING'), so a DELETING row reads as TableNotFound. update_table.rs locks the row and answers TableNotActive for any status other than ACTIVE, which the engine words as Table <name> is not in ACTIVE state. The data-plane table lookup excludes DELETING rows, so reads and writes answer ResourceNotFoundException until the row is gone.

Fix shape

For the two control-plane requests, look the name up without the status filter when the filtered select returns nothing and answer a DELETING row with the service's sentence; delete_table.rs already does this for a table that is being restored. For the data plane, the service serves reads and writes until the table is gone, so the lookup would include DELETING rows; whether writes during the window should be served or refused is a design question, since a write that lands between the data drop and the row delete is lost on both sides.

With the default delete delay the window on ExtendDB lasts as long as the data drop takes, so a client only sees it when another connection holds a lock on the table's data.

Found while fixing #449 (#504).

Ngôn ngữ chính
Rust
Star
517
Fork
60
Merge trung bình
5 ngày 5 giờ
Pull request đã merge (30 ngày)
41

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của ExtendDB/extenddb

Tất cả issue của ExtendDB/extenddb

Issue tương tự

Thêm issue về Rust

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.