- 12 2月, 2013 17 次提交
-
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
When we are preparing an handshake with the slave we can't touch the connection buffer as it'll be used to accumulate differences between the sent RDB file and what arrives next from clients. So in short we can't use addReply() family functions. However we just use write(2) because we know that the socket buffer is empty, since a prerequisite for SYNC to work is that the static buffer and the output list are empty, and in general it is not expected that a client SYNCs after doing some heavy I/O with the master. However a short write connection is explicitly handled to avoid fragility (we simply close the connection and the slave will retry).
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
-
由 antirez 提交于
SELECT was still transmitted to slaves using the inline protocol, that is conceived mostly for humans to type into telnet sessions, and is notably not understood by redis-cli --slave. Now the new protocol is used instead.
-
由 antirez 提交于
A Redis master sends PING commands to slaves from time to time: doing this ensures that even if absence of writes, the master->slave channel remains active and the slave can feel the master presence, instead of closing the connection for timeout. This commit changes the way PINGs are sent to slaves in order to use the standard interface used to replicate all the other commands, that is, the function replicationFeedSlaves(). With this change the stream of commands sent to every slave is exactly the same regardless of their exact state (Transferring RDB for first synchronization or slave already online). With the previous implementation the PING was only sent to online slaves, with the result that the output stream from master to slaves was not identical for all the slaves: this is a problem if we want to implement partial resyncs in the future using a global replication stream offset. TL;DR: this commit should not change the behaviour in practical terms, but is just something in preparation for partial resynchronization support.
-
由 antirez 提交于
Before this commit every Redis slave had its own selected database ID state. This was not actually useful as the emitted stream of commands is identical for all the slaves. Now the the currently selected database is a global state that is set to -1 when a new slave is attached, in order to force the SELECT command to be re-emitted for all the slaves. This change is useful in order to implement replication partial resynchronization in the future, as makes sure that the stream of commands received by slaves, including SELECT commands, are exactly the same for every slave connected, at any time. In this way we could have a global offset that can identify a specific piece of the master -> slaves stream of commands.
-
由 Salvatore Sanfilippo 提交于
Format to fit 80 columns
-
- 11 2月, 2013 1 次提交
-
-
由 antirez 提交于
-
- 09 2月, 2013 4 次提交
-
-
由 antirez 提交于
-
由 Steven Penny 提交于
This makes it readable on GitHub and editors without auto wrapping.
-
由 antirez 提交于
Otherwise we end with less reliable connections because it's too easy that a single packet gets lost.
-
由 antirez 提交于
-
- 08 2月, 2013 4 次提交
- 05 2月, 2013 6 次提交
-
-
由 antirez 提交于
-
由 charsyam 提交于
Further details from @antirez: It was reported by @StopForumSpam on Twitter that the Redis replication link was strangely using multiple TCP packets for multiple commands. This wastes a lot of bandwidth and is due to the TCP_NODELAY option we enable on the socket after accepting a new connection. However the master -> slave channel is a one-way channel since Redis replication is asynchronous, so there is no point in trying to reduce the latency, we should aim to reduce the bandwidth. For this reason this commit introduces the ability to disable the nagle algorithm on the socket after a successful SYNC. This feature is off by default because the delay can be up to 40 milliseconds with normally configured Linux kernels.
-
由 antirez 提交于
-
由 Salvatore Sanfilippo 提交于
Make redis test suite tcl version agnostic, v2
-
由 Salvatore Sanfilippo 提交于
retval doesn't initalized
-
由 Rock Li 提交于
If each if conditions are all fail, variable retval will under uninitlized
-
- 04 2月, 2013 4 次提交
-
-
由 Salvatore Sanfilippo 提交于
Fix a few typos and improve grammar of redis.conf
-
由 Salvatore Sanfilippo 提交于
Fix a bug in srandmemberWithCountCommand()
-
由 Gengliang Wang 提交于
In CASE 2, the call sunionDiffGenericCommand will involve the string "srandmember" > sadd foo one (integer 1) > sadd srandmember two (integer 2) > srandmember foo 3 1)"one" 2)"two"
-
由 David Celis 提交于
Make several edits to the example redis.conf configuration file for improved flow and grammar. Signed-off-by: NDavid Celis <me@davidcel.is>
-
- 01 2月, 2013 1 次提交
-
-
由 antirez 提交于
-
- 31 1月, 2013 1 次提交
-
-
由 Salvatore Sanfilippo 提交于
fix comments forgotten in #285 (zipmap -> ziplist)
-
- 29 1月, 2013 2 次提交