Comments (3)
Can you post your full source code? Without details, it's hard to see what's the actual problem is.
from zbox.
Well just looking it at the code makes it obvious: a File
can't receive consecutive writes from different threads, since begin_write()
initializes a thread local TXID
, which will not be set on a second write from a different thread.
So with the current design, File
should really be !Send
.
from zbox.
Your looking is right. When shared with multiple threads, File
works like a reader-writer lock, that is, you can only have one thread to modify it, but you can have multiple threads to read. So I think !Send
is still valid.
from zbox.
Related Issues (20)
- Absolute file URLs on Windows HOT 5
- Zbox storage needs destroy method
- RepoInfo.uri() should not mask secretive data
- Is zbox secure agains storage file tampering? HOT 3
- Confusing abort if omit zbox::init_env HOT 7
- zbox::Error is not accessible from within std::io::Error HOT 1
- Stress-testing multiple reads, writes and seeks produces an unreadable file (IO error: File not found)
- Problems when `file://` storage runs out of space HOT 42
- Panic when writing to `Mutex<zbox::File>` from multiple threads. HOT 1
- Panic when trying to write a file after interrupted previous attempt. HOT 1
- FR: `zbox::Repo::ongoing_transaction` HOT 5
- Is zbox::Repo::rename atomic? HOT 1
- Add dedup file option when creating repo
- RepoInfo lack of dedup_file entry
- Snapshots? HOT 2
- Failed open repo in file mode
- Question: reason not support symbolic link?
- storage-sqlite RepoOpener not creating path
- Future plans and continuation HOT 1
- Python support
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 zbox.