Browse Source

mp pool: Decrease result polling time from 0.2 to 1.0.

Ask Solem 13 năm trước cách đây
mục cha
commit
9edf44cc89
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      celery/concurrency/processes/pool.py

+ 2 - 2
celery/concurrency/processes/pool.py

@@ -442,7 +442,7 @@ class ResultHandler(PoolThread):
         debug('result handler starting')
         while 1:
             try:
-                ready, task = poll(0.2)
+                ready, task = poll(1.0)
             except (IOError, EOFError), exc:
                 debug('result handler got %r -- exiting' % (exc, ))
                 return
@@ -462,7 +462,7 @@ class ResultHandler(PoolThread):
         time_terminate = None
         while cache and self._state != TERMINATE:
             try:
-                ready, task = poll(0.2)
+                ready, task = poll(1.0)
             except (IOError, EOFError), exc:
                 debug('result handler got %r -- exiting' % (exc, ))
                 return