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.
Due to limitations of the
filesystem
backend, I decided to push aredis
backend which will store all pastes and metadata to a Redis instance. The current data storage scheme is:Paste Storage
Paste Metadata Storage
Due to the List Pastes feature, this backend has to run the Redis
KEYS
command, which according to the official documentation is not recommended for production. However, after checking the recommended options a little bit, this command might be necessary for the app to work. In addition to that, some benchmarks I ran against theKEYS
command and thefilesystem
backend indicate that theKEYS
command can run up to hundreds of thousands of keys (currently 1/3rd of them will be pastes) in under one second, which is much faster than thebackend
filesystem.I am open of course to other options to store data using Redis and will not merge until some time, so we can evaluate alternatives. Until then, use of this backend will of course not be supported and there will be no guarantees of compatibility across versions. These guarantees only exist after merging to
master
.