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

DoNotOverwrite - feature request #139

Closed
cmumford opened this issue Sep 9, 2014 · 2 comments
Closed

DoNotOverwrite - feature request #139

cmumford opened this issue Sep 9, 2014 · 2 comments
Assignees

Comments

@cmumford
Copy link
Contributor

cmumford commented Sep 9, 2014

Original issue 133 created by doppelbauer on 2012-12-27T21:21:37.000Z:

It would be great to have a WriteOption "DoNotOverwrite".
If two threads append a new record (new_key = last_key + 1), they would overwrite their records.

@cmumford
Copy link
Contributor Author

If I'm understanding correctly this can be easily fixed by application code to synchronize these two threads. This doesn't sound like a feature that should be in the database.

@jessetane
Copy link

Personally I think it would be convenient to have this as a WriteOption. The issue can be worked around in application code, but it can still be a bit of a pain / gotcha.

IndexedDB appears to specify this functionality:
https://www.w3.org/TR/IndexedDB/#widl-IDBObjectStore-add-IDBRequest-any-value-any-key

so, in addition to being handy for Node peoples, having this feature here might even simplify Chromium's implementation?
https://code.google.com/p/chromium/codesearch#chromium/src/content/browser/indexed_db/indexed_db_database.cc&rcl=1453854707&l=995

njwhite added a commit to njwhite/leveldb that referenced this issue May 3, 2016
xyb added a commit to xyb/homebrew-core that referenced this issue Dec 24, 2021
Upstream had refused to add pkg-config due to moved to cmake,
so pick up Homebrew/legacy-homebrew#31773 again
and fix google/leveldb#139
maochongxin pushed a commit to maochongxin/leveldb that referenced this issue Jul 21, 2022
Fix doc sample typos in header and README
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants