1. 19 12月, 2013 4 次提交
  2. 17 12月, 2013 7 次提交
  3. 13 12月, 2013 4 次提交
  4. 12 12月, 2013 4 次提交
  5. 11 12月, 2013 8 次提交
  6. 10 12月, 2013 1 次提交
    • A
      Slaves heartbeat while loading RDB files. · 27db38d0
      antirez 提交于
      Starting with Redis 2.8 masters are able to detect timed out slaves,
      while before 2.8 only slaves were able to detect a timed out master.
      
      Now that timeout detection is bi-directional the following problem
      happens as described "in the field" by issue #1449:
      
      1) Master and slave setup with big dataset.
      2) Slave performs the first synchronization, or a full sync
         after a failed partial resync.
      3) Master sends the RDB payload to the slave.
      4) Slave loads this payload.
      5) Master detects the slave as timed out since does not receive back the
         REPLCONF ACK acknowledges.
      
      Here the problem is that the master has no way to know how much the
      slave will take to load the RDB file in memory. The obvious solution is
      to use a greater replication timeout setting, but this is a shame since
      for the 0.1% of operation time we are forced to use a timeout that is
      not what is suited for 99.9% of operation time.
      
      This commit tries to fix this problem with a solution that is a bit of
      an hack, but that modifies little of the replication internals, in order
      to be back ported to 2.8 safely.
      
      During the RDB loading time, we send the master newlines to avoid
      being sensed as timed out. This is the same that the master already does
      while saving the RDB file to still signal its presence to the slave.
      
      The single newline is used because:
      
      1) It can't desync the protocol, as it is only transmitted all or
      nothing.
      2) It can be safely sent while we don't have a client structure for the
      master or in similar situations just with write(2).
      27db38d0
  7. 09 12月, 2013 1 次提交
  8. 08 12月, 2013 1 次提交
  9. 06 12月, 2013 7 次提交
  10. 05 12月, 2013 3 次提交