3 ms·
It is a service, and a library(C++). You can always check the implementation, but obviously that's the wrong answer to that question :) The README states that
by markpapadakis 10y ago
It is a service, and a library(C++). You can always check the implementation, but obviously that's the wrong answer to that question :)
The README states that replication is not implemented yet. I encourage you to also check this issue https://github.com/phaistos-networks/TANK/issues/14 https://github.com/phaistos-networks/TANK/issues/14 for some details on the I/O semantics, and the Wiki for answers to other questions: https://github.com/phaistos-networks/TANK/wiki https://github.com/phaistos-networks/TANK/wiki
- biokoda 10y agoSo single threaded, blocking file io. Not very impressive or useful (as a lib).
- markpapadakis 10y agoYes, single threaded, because the contention to the various files and the cost of serialisation would likely negate the benefits of using multiple threads. Network I/O is obviously asynchronous - you may want to check the codebase. Disk I/O is synchronous, but: - uses sendfile() and read readahead() to reduce or eliminate the likelihood of blocking reads: see here please https://github.com/phaistos-networks/TANK/issues/14#issuecomment-232614206 https://github.com/phaistos-networks/TANK/issues/14#issuecom... - AIO is either broken or supported on XFS (depending on kernel release, and also in the past, appending to a file on an XFS fs could block and degrade performance). But not using DirectI/O so writes end up in memory and only get flushed if it hits the commit count, or periodically - so, particularly for local disks, HDDs or SSDs, this in practice never blocks for more than a few ms when flushing, if at all.
- biokoda 10y ago> Yes, single threaded, because the contention to the various files and the cost of serialisation would likely negate the benefits of using multiple threads. Multithreaded does not mean multiple files. > But not using DirectI/O so writes end up in memory and only get flushed if it hits the commit count, or periodically - so, particularly for local disks, HDDs or SSDs, this in practice never blocks for more than a few ms when flushing, if at all. Unless you are actually using it under a high throughput scenario which is why you would use a lib like this. It will work great until you hit the actual flush point, then possibly block for seconds even minutes. If your performance needs are high, mandating XFS is not unreasonable.
- krenoten 10y agoIt's totally unreasonable to mandate a particular FS for modern general purpose software. Multiple files does mean multiple threads. Unless you manage to run this without a modern operating system.
- biokoda 10y ago> It's totally unreasonable to mandate a particular FS for modern general purpose software. That is completely debatable. We are talking about a "a high performance distributed log service". Not a word processor. > Multiple files does mean multiple threads. Which is something entirely different from what I said...
- the_duke 10y agoYou are making all kinds of assumptions without knowing anything about the implementation.