mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-02-01 02:52:00 +00:00
MINOR: stream/htx: Add info about the HTX structs in "show sess all" command
For HTX streams, info about the HTX structure is now dumped for the request and the response channels in "show sess all" command. The patch may be backported to 1.9.
This commit is contained in:
parent
1bb812fd80
commit
b9af88151a
20
src/stream.c
20
src/stream.c
@ -3087,6 +3087,16 @@ static int stats_dump_full_strm_to_buffer(struct stream_interface *si, struct st
|
||||
strm->txn ? strm->txn->req.next : 0, (unsigned int)ci_data(&strm->req),
|
||||
(unsigned int)strm->req.buf.size);
|
||||
|
||||
if (IS_HTX_STRM(strm)) {
|
||||
struct htx *htx = htxbuf(&strm->req.buf);
|
||||
|
||||
chunk_appendf(&trash,
|
||||
" htx=%p size=%u data=%u used=%u wrap=%s extra=%llu\n",
|
||||
htx, htx->size, htx->data, htx->used,
|
||||
(!htx->used || htx->tail+1 == htx->wrap) ? "NO" : "YES",
|
||||
(unsigned long long)htx->extra);
|
||||
}
|
||||
|
||||
chunk_appendf(&trash,
|
||||
" res=%p (f=0x%06x an=0x%x pipe=%d tofwd=%d total=%lld)\n"
|
||||
" an_exp=%s",
|
||||
@ -3116,6 +3126,16 @@ static int stats_dump_full_strm_to_buffer(struct stream_interface *si, struct st
|
||||
strm->txn ? strm->txn->rsp.next : 0, (unsigned int)ci_data(&strm->res),
|
||||
(unsigned int)strm->res.buf.size);
|
||||
|
||||
if (IS_HTX_STRM(strm)) {
|
||||
struct htx *htx = htxbuf(&strm->res.buf);
|
||||
|
||||
chunk_appendf(&trash,
|
||||
" htx=%p flags=0x%x size=%u data=%u used=%u wrap=%s extra=%llu\n",
|
||||
htx, htx->flags, htx->size, htx->data, htx->used,
|
||||
(!htx->used || htx->tail+1 == htx->wrap) ? "NO" : "YES",
|
||||
(unsigned long long)htx->extra);
|
||||
}
|
||||
|
||||
if (ci_putchk(si_ic(si), &trash) == -1) {
|
||||
si_rx_room_blk(si);
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user