Skip to content
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

LevelDB storage type #4066

Open
ashduino101 opened this issue Feb 8, 2024 · 1 comment
Open

LevelDB storage type #4066

ashduino101 opened this issue Feb 8, 2024 · 1 comment
Labels
Feature Request Requests for Features

Comments

@ashduino101
Copy link

ashduino101 commented Feb 8, 2024

Feature Description: An option to save map tiles and data in the LevelDB format would be nice. This would allow for the data to be stored as a collection of moderately-sized files in a single flat directory instead of millions of individual files (filesystem), a database that probably supports a lot more functionality than is necessary, degrading query performance (SQLite), or a database that is stored at a low filesystem level and is difficult to migrate or control, as well as the necessity for a socket to be running (MySQL/MariaDB/PostgreSQL). For the database keys, perhaps a format similar to Bedrock Edition's world format would suffice, where tile coordinates are serialized as int32s along with an indicator to differentiate the tiles from other types of data being stored (e.g. entities, dimensions, general metadata), a dimension ID, and maybe a map type ID as well, just as an example.

Additional context: In case you don't know what LevelDB is, it's essentially a glorified on-disk dictionary, with extremely fast query times for large amounts of binary rows. MCBE/MCPE uses it, allowing for extremely small world sizes (some of the fairly large example maps are under 8 megabytes!), low memory usage, and fairly succinct filesystem storage.

@ashduino101 ashduino101 added the Feature Request Requests for Features label Feb 8, 2024
@rautamiekka
Copy link

I'd just go with H2 instead if SQLite won't do, since it seems to have less problems with performance than SQLite.

^ According to https://stackoverflow.com/a/62845028 it has a high-likelihood of corruption if the app shuts down illegally, though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Request Requests for Features
Projects
None yet
Development

No branches or pull requests

2 participants