Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Initially, I thought it would be a good idea to mimic CouchDB in the design of having unique database instances be separate Sled instances. Through some conversations and thoughts, I decided to refactor how local and server are defined. Before this change, local was only for a single database. After this change, local is where the multi-db abstraction lives, and the server crate's purpose is to expose
local
over the network.This keeps each crate's purpose as focused as possible and allowed me to remove many "internal" APIs because the boundaries are better defined -- that's a testament to this being the right refactor. Additionally, many of my original concerns about "number of open files" and ways to optimize sled are waved away, because there is only one sled instance now, and databases are just groups of trees within sled.