Skip to content

Node.js: Phase 2 client-side caching - serverAssisted field and clientTrackingInfo#5964

Draft
affonsov wants to merge 1 commit into
affonsov/client-side-caching-phase2from
affonsov/csc-phase2-node
Draft

Node.js: Phase 2 client-side caching - serverAssisted field and clientTrackingInfo#5964
affonsov wants to merge 1 commit into
affonsov/client-side-caching-phase2from
affonsov/csc-phase2-node

Conversation

@affonsov
Copy link
Copy Markdown
Collaborator

@affonsov affonsov commented May 15, 2026

Summary

Adds serverAssisted field to Node.js ClientSideCache config and clientTrackingInfo() diagnostic command.

Issue link

This Pull Request is linked to issue: Implement client-side caching Phase 2: server-assisted invalidation via CLIENT TRACKING
Closes #5961

Features / Behaviour Changes

  • serverAssisted?: boolean in ClientSideCacheConfig interface and ClientSideCache class (default false)
  • clientTrackingInfo() on BaseClient - available on both GlideClient and GlideClusterClient
  • clientTrackingInfo(options?: RouteOption) cluster override on GlideClusterClient for routing to specific nodes
  • clientTrackingInfo() in BaseBatch

Implementation

  • ClientSideCache.ts: serverAssisted field added to config interface and class; serialized to protobuf
  • BaseClient.ts: clientTrackingInfo() - routes to a single node, consistent with CLIENT INFO behavior
  • GlideClusterClient.ts: cluster override with optional RouteOption - use AllNodes to get tracking info from all cluster connections
  • Batch.ts: batch method

Limitations

  • serverAssisted: true requires RESP3 protocol (enforced by glide-core)
  • In cluster mode, the no-arg variant routes to a single random node; use RouteOption to query all nodes

Testing

Checklist

  • This Pull Request is related to one issue.
  • Commit message has a detailed description of what changed and why.
  • Tests are added or updated.
  • CHANGELOG.md and documentation files are updated.
  • Linters have been run and Prettier has been run.
  • Destination branch is correct - main or release
  • Create merge commit if merging release branch into main, squash otherwise.

@affonsov affonsov force-pushed the affonsov/client-side-caching-phase2 branch from 25224b0 to 125fbf9 Compare May 16, 2026 02:25
@affonsov affonsov force-pushed the affonsov/csc-phase2-node branch 3 times, most recently from d2332be to 5ac400b Compare May 16, 2026 02:51
…isted caching

Signed-off-by: affonsov <67347924+affonsov@users.noreply.github.com>
@affonsov affonsov force-pushed the affonsov/csc-phase2-node branch from 5ac400b to 8abe1cf Compare May 16, 2026 03:06
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.

1 participant