worker's busy value is now dinamically computed

This commit is contained in:
Unbit
2013-02-14 09:17:59 +01:00
parent 0b8b6346be
commit f046d47eb2
8 changed files with 30 additions and 18 deletions
+2 -2
View File
@@ -1995,14 +1995,14 @@ PyObject *py_uwsgi_workers(PyObject * self, PyObject * args) {
if (uwsgi.workers[i + 1].cheaped) {
zero = PyString_FromString("cheap");
}
else if (uwsgi.workers[i + 1].suspended && !uwsgi.workers[i + 1].busy) {
else if (uwsgi.workers[i + 1].suspended && !uwsgi_worker_is_busy(i+1)) {
zero = PyString_FromString("pause");
}
else {
if (uwsgi.workers[i + 1].sig) {
zero = PyString_FromFormat("sig%d",uwsgi.workers[i + 1].signum);
}
else if (uwsgi.workers[i + 1].busy) {
else if (uwsgi_worker_is_busy(i+1)) {
zero = PyString_FromString("busy");
}
else {