Skip to content

fix(client): expose watch, rbs and rbp fields in CLIENT INFO and CLIENT LIST replies - #3415

Open
abhijeet117 wants to merge 1 commit into
redis:masterfrom
abhijeet117:fix/client-info-missing-fields
Open

fix(client): expose watch, rbs and rbp fields in CLIENT INFO and CLIENT LIST replies#3415
abhijeet117 wants to merge 1 commit into
redis:masterfrom
abhijeet117:fix/client-info-missing-fields

Conversation

@abhijeet117

@abhijeet117 abhijeet117 commented Aug 23, 2026

Copy link
Copy Markdown
Contributor

Summary

CLIENT INFO and CLIENT LIST replies silently dropped three server fields: rbs and rbp (returned since Redis 7.0) and watch (added in 7.4). catClientInfoString in networking.c emits them, but ClientInfoReply and the reply parser ignored them, so consumers could not read buffer stats or watched-key counts. They are now optional typed fields parsed with the same guarded Number() pattern as the other version-gated fields. CLIENT LIST shares the transformer, so both commands are covered.

Testing

Reproduced with a captured CLIENT INFO string containing watch=2 rbs=1024 rbp=2048: the new spec assertion failed on master (fields undefined) and passes after the fix. Parser spec, type tests, client build and eslint run locally; Docker-backed integration tests run in CI.

Checklist

  • bug reproduced before fix
  • root cause identified
  • bug fixed
  • tests passed

Note

Low Risk
Parser-only additive fields on a read-only command; no auth, protocol, or connection-behavior changes.

Overview
Exposes three Redis client-info fields that the parser previously dropped: watch (7.4) and rbs/rbp (7.0). They are now optional numbers on ClientInfoReply, so CLIENT INFO and CLIENT LIST (which reuses the same transformer) can report watched-key counts and output-buffer stats.

Adds a unit test that feeds a captured reply string and asserts the new fields parse correctly.

Reviewed by Cursor Bugbot for commit f54aea3. Bugbot is set up for automated code reviews on this repo. Configure here.

@PavelPashov

Copy link
Copy Markdown
Contributor

@abhijeet117 Thanks for the PR. We’ll review it when we have capacity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants