فهرست منبع

Make the redis_socket_timeout setting official (from 75ab5c3656c5fd04e6d86506cd4995a363813edd)

Ask Solem 9 سال پیش
والد
کامیت
e7b01149f1
2فایلهای تغییر یافته به همراه11 افزوده شده و 0 حذف شده
  1. 1 0
      celery/app/defaults.py
  2. 10 0
      docs/configuration.rst

+ 1 - 0
celery/app/defaults.py

@@ -171,6 +171,7 @@ NAMESPACES = Namespace(
         max_connections=Option(type='int'),
         max_connections=Option(type='int'),
         password=Option(type='string'),
         password=Option(type='string'),
         port=Option(type='int'),
         port=Option(type='int'),
+        socket_timeout=Option(5.0, type='float'),
     ),
     ),
     result=Namespace(
     result=Namespace(
         __old__=old_ns('celery_result'),
         __old__=old_ns('celery_result'),

+ 10 - 0
docs/configuration.rst

@@ -692,6 +692,16 @@ redis_max_connections
 Maximum number of connections available in the Redis connection
 Maximum number of connections available in the Redis connection
 pool used for sending and retrieving results.
 pool used for sending and retrieving results.
 
 
+.. setting:: redis_socket_timeout
+
+redis_socket_timeout
+~~~~~~~~~~~~~~~~~~~~
+
+Socket timeout for connections to Redis from the result backend
+in seconds (int/float)
+
+Default is 5 seconds.
+
 .. _conf-mongodb-result-backend:
 .. _conf-mongodb-result-backend:
 
 
 MongoDB backend settings
 MongoDB backend settings