- 15 11月, 2014 1 次提交
-
-
由 antirez 提交于
-
- 12 11月, 2014 4 次提交
-
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
RDB EOF detection was relying on the final part of the RDB transfer to be a magic 40 bytes EOF marker. However as the slave is put online immediately, and because of sockets timeouts, the replication stream is actually contiguous with the RDB file. This means that to detect the EOF correctly we should either: 1) Scan all the stream searching for the mark. Sucks CPU-wise. 2) Start to send the replication stream only after an acknowledge. 3) Implement a proper chunked encoding. For now solution "2" was picked, so the master does not start to send ASAP the stream of commands in the case of diskless replication. We wait for the first REPLCONF ACK command from the slave, that certifies us that the slave correctly loaded the RDB file and is ready to get more data.
-
- 11 11月, 2014 1 次提交
-
-
由 antirez 提交于
-
- 30 10月, 2014 4 次提交
-
-
由 Matt Stancliff 提交于
Same as the original bind fixes (we just missed these the first time around). This helps Redis not automatically send connections from the first IP on an interface if we are bound to a specific IP address (e.g. with multiple IP aliases on one interface, you want to send from _your_ IP, not from the first IP on the interface).
-
由 Matt Stancliff 提交于
We need to pick the port based on the _last_ colon, not the first one.
-
由 Matt Stancliff 提交于
IP format is now any of: - 127.0.0.1:6379 - ::1:6379
-
由 Matt Stancliff 提交于
Closes #2066
-
- 29 10月, 2014 1 次提交
-
-
由 antirez 提交于
This caused BGSAVE to be triggered a second time without any need when we switch from socket to disk target via the command CONFIG SET repl-diskless-sync no and there is already a slave waiting for the BGSAVE to start. Also comments clarified about what is happening.
-
- 27 10月, 2014 5 次提交
- 24 10月, 2014 2 次提交
- 22 10月, 2014 3 次提交
-
-
由 antirez 提交于
EWOULDBLOCK with the fdset rio target is returned when we try to write but the send timeout socket option triggered an error. Better to translate the error in something the user can actually recognize as a timeout.
-
由 antirez 提交于
We need to avoid that a child -> slaves transfer can continue forever. We use the same timeout used as global replication timeout, which is documented to also affect I/O operations during bulk transfers.
-
由 antirez 提交于
-
- 17 10月, 2014 10 次提交
-
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
While the socket is set in blocking mode, we still can get short writes writing to a socket.
-
由 antirez 提交于
-
由 antirez 提交于
To perform a socket write() for each RDB rio API write call was extremely unefficient, so now rio has minimal buffering capabilities. Writes are accumulated into a buffer and only when a given limit is reacehd are actually wrote to the N slaves FDs. Trivia: rio lacked support for buffering since our targets were: 1) Memory buffers. 2) C standard I/O. Both were buffered already.
-
由 antirez 提交于
-
由 antirez 提交于
This is useful for normal replication in order to refresh the slave when we are persisting on disk, but for diskless replication the child is already receiving data while in WAIT_BGSAVE_END state.
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
- 16 10月, 2014 6 次提交
-
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
If we turn from diskless to disk-based replication via CONFIG SET, we need a way to start a BGSAVE if there are slaves alerady waiting for a BGSAVE to start. Normally with disk-based replication we do it as soon as the previous child exits, but when there is a configuration change via CONFIG SET, we may have slaves in WAIT_BGSAVE_START state without an RDB background process currently active.
-
由 antirez 提交于
-
由 antirez 提交于
-
- 15 10月, 2014 3 次提交