Sfoglia il codice sorgente

Cap the number of retries on connection failure.

I think it is better to have a default limit to the number of attempts
when trying to send a command after a connection failure, I am just not
sure if 20 is a good value but we can adjust it later.
Daniele Alessandri 9 anni fa
parent
commit
0ec9f3351f
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      src/Connection/Aggregate/SentinelReplication.php

+ 1 - 1
src/Connection/Aggregate/SentinelReplication.php

@@ -62,7 +62,7 @@ class SentinelReplication extends MasterSlaveReplication
      *  0 = no retry attempts (fails immediatly)
      *  n = fail only after n retry attempts
      */
-    protected $retryLimit = -1;
+    protected $retryLimit = 20;
 
     /**
      * Flag for automatic fetching of available sentinels.