dolthub / dolthub/dolt

access to `dolt_branches` is not safe in multi-tenant environment

Open
#5,784 2 comments 1 reaction 0 assignees View on GitHub
concurrency customer issue enhancement
Dominant language
Go
Stars
24.4k
Forks
873
Avg merge
1d 5h
Merged PRs (30d)
108

Description

Queries like `select * from dolt_branches` can fail under concurrent load when other clients delete a branch. This is because `dolt_branches` and some other system tables don't currently respect transactional isolation and always read from the current tip of the entire database.

Expectation is that branch information is managed transactionally, the same as table data.

First milestone is read isolation: `dolt_branches` should have the same contents as it did at transaction start throughout a transaction, regardless of changes made by other clients.

Second milestone is write isolation: prevent conflicting writes to a particular branch by multiple clients. We currently are only principled about moving branch heads transactionally for the `dolt_commit()` procedure. We need to bring in `dolt_branch()`, `dolt_reset()` and other operations that can move or delete a branch head.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.