https://bz.apache.org/bugzilla/show_bug.cgi?id=64338

--- Comment #9 from Yann Ylavic <[email protected]> ---
I'd suggest using the PROXY_WORKER_*_STAT characters or proxy_wstat_tbl strings
rather than the numeric/mask value. Something like this maybe:

static char *worker_status_str(apr_pool_t *p, const proxy_worker *worker)
{
    apr_array_header_t *str = apr_array_make(p, 13, sizeof(char));
    proxy_wstat_t *wstat = proxy_wstat_tbl;
    while (wstat->flag) {
        if (worker->s->status & wstat->bit) {
            APR_ARRAY_PUSH(str, char) = wstat->flag;
        }
        wstat++;
    }
    APR_ARRAY_PUSH(str, char) = '\0';
    return str->elts;
}

Regarding the X-Worker-Status header, possibly it could be conditional (opt-in)
to "ProxyAddWorkerHeaders on" or alike (similar to ProxyAddHeaders)? One does
not necessarily want to expose this information to the backend.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to