-
-
Notifications
You must be signed in to change notification settings - Fork 50
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
Read only support for rocksdb #98
Conversation
OK. So looks like I'll need a windows machine to try to debug the appveyer messages. |
It's probably due to:
But I don't think we have to use |
@vweevers So, just test that it can still work on regular databases, don't worry about testing whether it can work with read-only databases? I can do that :-) My own use case was using the database from a read-only file system, but you're right, the other major use case is just loading a database without mutating any state, which is probably what most people are trying to do. |
Side note: because |
@vweevers I believe so! I haven't tested this my self with a live writing process. But would definitely work for 2 read only processes. |
Making a parent directory read only doesn't cascade to the files in that folder like in *nix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I still prefer not using chmod, feels out of scope, but we can postpone that discussion.
We can simplify some of the tests when upgrading |
3.1.0 |
This PR adds read only rocksdb support.
This PR closes #72 and quite a few comments on #13
There's a new
readOnly
boolean option to the database options object that can be used to open a rocksdb database in readonly mode.I've also included some tests which use
chmod
to set the database to read only to set the various edge cases.I've also published a version to
@eugeneware/rocksdb
in case this doesn't get merged for a while for people to use.