Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | [SERVER] Make buffer when reading for crc check larger | Simon Rettberg | 2019-09-11 | 1 | -1/+1 |
| | |||||
* | [SERVER] Make integrity checks on startup async | Simon Rettberg | 2019-09-10 | 3 | -31/+37 |
| | |||||
* | Fix compilation on older gcc | Simon Rettberg | 2019-09-09 | 1 | -2/+2 |
| | |||||
* | [SERVER] Fix warning on clang | Simon Rettberg | 2019-09-07 | 1 | -6/+1 |
| | |||||
* | [SERVER] picohttpparser: Merge 81fe3d99fd90a55cafb993e53fd3000dbc4d564c | Simon Rettberg | 2019-09-07 | 1 | -21/+46 |
| | |||||
* | [SERVER] rpc: Add cachemap feature | Simon Rettberg | 2019-09-06 | 4 | -1/+63 |
| | |||||
* | [SERVER] Introduce autoFreeDiskSpaceDelay | Simon Rettberg | 2019-09-05 | 3 | -6/+27 |
| | | | | | | | | This setting allows you to control the formerly hard-coded timeout of 10 hours before a proxy would start deleting old images in order to free up space for new images. Setting it to -1 entirely disables automatic deletion, in case you have an external process for freeing up disk space. | ||||
* | [SERVER] integrity checker: Improve flushing logic | Simon Rettberg | 2019-09-05 | 2 | -90/+111 |
| | |||||
* | [SERVER] Support limiting alt-servers to specific namespace | Simon Rettberg | 2019-09-04 | 5 | -18/+49 |
| | | | | | | Not really namespace but simple string matching for the image path. Path is matched from start with no support for glob or regex, so usually you want to have a trailing '/' to limit to certain directories. | ||||
* | [SERVER] Fix altservers_getListForClient() | Simon Rettberg | 2019-09-04 | 3 | -6/+66 |
| | | | | | The score wasn't reset when adding clients to the list, resulting in exactly one server filling up the whole list. | ||||
* | [SERVER] Fix indentation | Simon Rettberg | 2019-09-03 | 1 | -4/+4 |
| | |||||
* | [SERVER] Fix image_updateCachemap() | Simon Rettberg | 2019-09-03 | 1 | -4/+8 |
| | |||||
* | [SERVER] Move signal init to uplink_init | Simon Rettberg | 2019-09-02 | 1 | -10/+11 |
| | | | | | | | Initializing the signal in the thread lead to a race where we would init the uplink and queue a request for it before the thread actually initialized it. This was not harmful but lead to spurious warnings in the server's log. | ||||
* | [SERVER] uplink: Don't disable already disabled image | Simon Rettberg | 2019-09-02 | 1 | -1/+1 |
| | |||||
* | [SERVER] Fix compiler warnings | Simon Rettberg | 2019-09-02 | 3 | -5/+5 |
| | |||||
* | [SERVER] uplink: Don't reinit uplink when freeing it | Simon Rettberg | 2019-09-02 | 1 | -13/+3 |
| | |||||
* | [SERVER] Less debug spam, fix RTT interval calculation | Simon Rettberg | 2019-08-30 | 1 | -3/+5 |
| | |||||
* | [SERVER] Introduce debug spam | Simon Rettberg | 2019-08-30 | 2 | -9/+9 |
| | |||||
* | [SERVER] No uplink_init when checking working state; improve logging | Simon Rettberg | 2019-08-30 | 2 | -8/+11 |
| | |||||
* | [SERVER] Tear down whole uplink on idle timeout | Simon Rettberg | 2019-08-29 | 2 | -29/+24 |
| | | | | | | Keeping the uplink thread around forever even though we disconnected from the upstream server seems wasteful. Get rid of this and rear down the uplink entirely. | ||||
* | [SERVER] Use weakref for cache maps | Simon Rettberg | 2019-08-29 | 7 | -160/+220 |
| | | | | | | Gets rid of a bunch of locking, especially the hot path in net.c where clients are requesting data. Many clients unsing the same incomplete image previously created a bottleneck here. | ||||
* | [SERVER] reference: Fix error msg usage | Simon Rettberg | 2019-08-29 | 2 | -2/+2 |
| | |||||
* | [BENCH] Request random blocks | Simon Rettberg | 2019-08-29 | 2 | -3/+4 |
| | |||||
* | [SERVER] Speed up shutdown of integrity checker | Simon Rettberg | 2019-08-28 | 1 | -2/+5 |
| | |||||
* | [SERVER] Reintroduce check whether readFd is actually != -1 | Simon Rettberg | 2019-08-28 | 1 | -1/+3 |
| | |||||
* | Merge branch 'master' into atomic | Simon Rettberg | 2019-08-28 | 1 | -2/+2 |
|\ | |||||
| * | [FUSE] Increase socket timeout from 1 to 3 seconds | Simon Rettberg | 2019-08-28 | 1 | -2/+2 |
| | | |||||
* | | [SERVER] Make signal handling more POSIX | Simon Rettberg | 2019-08-28 | 8 | -33/+74 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | According to POSIX, a signal sent to a PID can be delivered to an arbitrary thread of that process that hasn't the signal blocked. This seens to never happen on Linux, but would mess things up since the code expected the main signal handler to only be executed by the main thread. This should now be fixed by examining the destination PID of the signal as well as the ID of the thread currently running the signal handler. If we notice the signal wasn't sent by our own PID and the handler is not currently run by the main thread, we re-send the signal to the main thread. Otherwise, if the signal was sent by our own PID but the handler is not run in the main thread, do nothing. This way we can use pthread_kill() to wake up threads that might be stuck in a blocking syscall when it's time to shut down. | ||||
* | | [SERVER] Remove old comments | Simon Rettberg | 2019-08-28 | 2 | -38/+0 |
| | | |||||
* | | [SERVER] Handle closeUnusedFd via timer | Simon Rettberg | 2019-08-28 | 2 | -25/+19 |
| | | |||||
* | | [SERVER] Add timer infrastructure | Simon Rettberg | 2019-08-27 | 2 | -10/+134 |
| | | | | | | | | To be used by "close unused fd" checks, and others... | ||||
* | | [SERVER] Fix swapped assignment | Simon Rettberg | 2019-08-27 | 1 | -1/+1 |
| | | |||||
* | | [SERVER] Use reference counting for uplink | Simon Rettberg | 2019-08-27 | 11 | -140/+311 |
| | | | | | | | | First step towards less locking for proxy mode | ||||
* | | [SERVER] Fix warnings, simplify locking | Simon Rettberg | 2019-08-26 | 2 | -12/+13 |
| | | |||||
* | | [BENCH] Check CMD_GET_BLOCK reply cmd type | Simon Rettberg | 2019-08-23 | 1 | -0/+3 |
| | | |||||
* | | [SERVER] Get rid of alt-servers thread, per-uplink rtt history | Simon Rettberg | 2019-08-22 | 9 | -485/+469 |
| | | | | | | | | | | | | | | | | | | | | Alt-Server checks are now run using the threadpool, so we don't need a queue and dedicated thread anymore. The rtt history is now kept per uplink, so many uplinks won't overwhelm the history, making its time window very short. Also the fail counter is now split up; a global one for when the server actually isn't reachable, a local (per-uplink) one for when the server is reachable but doesn't serve the requested image. | ||||
* | | [SERVER] Put request handle into CMD_ERROR reply | Simon Rettberg | 2019-08-22 | 1 | -1/+1 |
| | | |||||
* | | [SERVER] Add struct representing active connection to uplink server | Simon Rettberg | 2019-08-18 | 5 | -66/+60 |
| | | |||||
* | | [SERVER] uplink: More consistent type/variable naming | Simon Rettberg | 2019-08-18 | 5 | -288/+294 |
| | | | | | | | | | | * Change link to uplink everywhere * dnbd3_connection_t -> dnbd3_uplink_t | ||||
* | | [SERVER] altservers: Don't run check if <= 1 alt server available | Simon Rettberg | 2019-08-18 | 1 | -4/+11 |
| | | |||||
* | | [SERVER] net.c: Minor reordering | Simon Rettberg | 2019-08-18 | 1 | -8/+9 |
| | | |||||
* | | [SERVER] Lock free thread pool | Simon Rettberg | 2019-08-16 | 1 | -53/+57 |
| | | |||||
* | | [SHARED] Better errno handling in connect() helper | Simon Rettberg | 2019-08-15 | 1 | -0/+8 |
| | | |||||
* | | [SERVER] Better lock debugging: Always check lock order | Simon Rettberg | 2019-08-07 | 10 | -219/+192 |
| | | | | | | | | | | | | Lock order is predefined in locks.h. Immediately bail out if a lock with lower priority is obtained while the same thread already holds one with higher priority. | ||||
* | | [SERVER] Lock-free queue for altservers check thread | Simon Rettberg | 2019-08-07 | 2 | -48/+57 |
| | | |||||
* | | [BENCH] Allow specifying request block size | Simon Rettberg | 2019-08-07 | 4 | -19/+32 |
| | | |||||
* | | [SERVER] Use more _Atomic | Simon Rettberg | 2019-08-07 | 2 | -5/+4 |
| | | |||||
* | | [SERVER] Fix race condition and invalid lock order | Simon Rettberg | 2019-08-07 | 1 | -4/+7 |
| | | |||||
* | | [SERVER] uplink: Improve attaching to existing requests | Simon Rettberg | 2019-08-06 | 2 | -35/+74 |
| | | | | | | | | | | Allow attaching in ULR_PROCESSING state, leave lower slots empty to increase chances attaching to ULR_PROCESSING. | ||||
* | | [BENCH] Increase timeouts, fix block payload reading | Simon Rettberg | 2019-08-06 | 1 | -3/+3 |
| | |