Skip to content

feat: child db for concurrent state #87

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Mar 4, 2025
Merged

feat: child db for concurrent state #87

merged 6 commits into from
Mar 4, 2025

Conversation

prestwich
Copy link
Member

@prestwich prestwich commented Mar 3, 2025

Allows Arc<ConcurrentState> to spawn and absorb Child DBs

Copy link
Member Author

prestwich commented Mar 3, 2025

This stack of pull requests is managed by Graphite. Learn more about stacking.

@prestwich prestwich marked this pull request as ready for review March 3, 2025 20:48
@Evalir Evalir self-requested a review March 3, 2025 22:11
Copy link
Member

@Evalir Evalir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, just two comments

}
}

// TODO make cache aware of transitions dropping by having global transition counter.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's ticket this?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is actually reproduced from revm. And I don't think they are planning on it anytime soon.

/// the child may be cloned AFTER this check is made, but BEFORE the child
/// is merged. In this case the function will spuriously return `Ok(())`
/// even though the merge will fail. To avoid this, ensure that the child
/// is not shared between threads when [`Self::can_merge`] is called.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

really really far out idea that might not be worth the trouble, but what if we codify this rule into some state machine-like type

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would be possible but seems like more effort than it's worth 🤔

@prestwich prestwich changed the base branch from prestwich/driver-commit to main March 4, 2025 11:50
@prestwich prestwich merged commit 121563a into main Mar 4, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants