.oO SearXNG Developer Documentation Oo.
|
Public Member Functions | |
__init__ (self) | |
is_suspended (self) | |
suspend (self, int suspended_time, str suspend_reason) | |
resume (self) |
Public Attributes | |
threading.Lock | lock = threading.Lock() |
int | continuous_errors = 0 |
float | suspend_end_time = 0 |
str | suspend_reason = "" |
Static Private Attributes | |
str | __slots__ = 'suspend_end_time', 'suspend_reason', 'continuous_errors', 'lock' |
Class to handle suspend state.
Definition at line 27 of file abstract.py.
searx.search.processors.abstract.SuspendedStatus.__init__ | ( | self | ) |
Definition at line 32 of file abstract.py.
searx.search.processors.abstract.SuspendedStatus.is_suspended | ( | self | ) |
Definition at line 39 of file abstract.py.
References suspend_end_time.
searx.search.processors.abstract.SuspendedStatus.resume | ( | self | ) |
Definition at line 55 of file abstract.py.
References continuous_errors, searx.metrics.models.CounterStorage.lock, lock, suspend_end_time, and suspend_reason.
searx.search.processors.abstract.SuspendedStatus.suspend | ( | self, | |
int | suspended_time, | ||
str | suspend_reason ) |
Definition at line 42 of file abstract.py.
References continuous_errors, searx.metrics.models.CounterStorage.lock, lock, suspend_end_time, and suspend_reason.
|
staticprivate |
Definition at line 30 of file abstract.py.
int searx.search.processors.abstract.SuspendedStatus.continuous_errors = 0 |
Definition at line 34 of file abstract.py.
threading.Lock searx.search.processors.abstract.SuspendedStatus.lock = threading.Lock() |
Definition at line 33 of file abstract.py.
float searx.search.processors.abstract.SuspendedStatus.suspend_end_time = 0 |
Definition at line 35 of file abstract.py.
Referenced by is_suspended(), resume(), and suspend().
str searx.search.processors.abstract.SuspendedStatus.suspend_reason = "" |
Definition at line 36 of file abstract.py.