Comments (10)
Read-only confirmed as working now. Thank you, good sir!
from bow.
This must be some update call bow makes when it's initializing. I'll be checking this later today, and hopefully commit a fix and let you know.
from bow.
Alright, sounds good; please let me know.
from bow.
Okay, I think I found the issue -- when you're Open
-ing a brand new database that hasn't been opened before, bow tries to create and store it's meta structure (containing information about buckets) even if it's opened with ReadOnly
.
This same problem happens when you access a bucket that doesn't exist -- bow will try to create it regardless of the ReadOnly
restriction.
Thanks for reporting this issue, I will fix it and let you know.
from bow.
Excellent. Read-only is a big deal if you access the database from a different process. Inside the same process, one can delegate all Bow operations to a dedicated goroutine and thus avoid dealing with DB locks.
from bow.
Update: I've set up a read-only test, and I'm fixing stuff until it passes. Will let you know.
from bow.
Commit 6703512 resolves this issue.
You can now Open
with SetReadOnly(true)
and you should be able to read freely, but not write.
Please let me know how it works out for you 😄
from bow.
When I attempt to open read-only in a directory that does not exist, I get a panic, rather than an error. Is that the intended behavior?
from bow.
@cbalano This behaviour is inherited from BadgerDB. Would you prefer to get an error when opening the database instead? Maybe something like ErrNoDatabase
?
from bow.
Well, it's a nicety, not a must.
from bow.
Related Issues (9)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bow.