GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Add out-of-band push notification handling by ggivo · Pull Request #4489 · redis/jedis

Conversation

@ggivo

@ggivo ggivo commented Apr 16, 2026 •
edited by cursor Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Collaborator

Handle unsupported push notifications gracefully instead of failing the connection.

Fixes errors occurring when push messages are received on connections that are not configured to process them. For example, enabling CLIENT TRACKING on a regular Connection may result in errors when invalidate push messages are delivered.

This change introduces initial support for out-of-band push notifications by:

  • detecting push messages on the connection
  • silently skipping unsupported push types

Note

Medium Risk
Changes the core reply parsing path (Protocol.read/Connection) to detect and handle RESP3 push frames, which can affect command-reply decoding and connection stability if edge cases are missed.

Overview
Adds first-class handling of RESP3 out-of-band push messages by introducing a PushConsumer/PushConsumerChain API and wiring it into Protocol.read so > frames can be consumed (or selectively propagated) while reading normal command replies.

Updates Connection to maintain a default push-consumer chain (propagating pub/sub pushes, silently consuming other pushes) and lets CacheConnection register a new PushInvalidateConsumer to evict CSC keys on invalidate pushes instead of relying on protocol-layer cache hooks.

Expands unit/integration coverage with a new TCP-based mock server plus new tests/benchmarks validating push consumption/propagation and ensuring arbitrary pushes no longer break connections; adjusts existing mocks to the new Protocol.read(is, chain) signature.

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

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@github-actions

github-actions Bot commented Apr 16, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

Test Results

  195 files  ±0    195 suites  ±0   9m 36s ⏱️ -13s
7 766 tests ±0  7 404 ✅  - 310  362 💤 +310  0 ❌ ±0 
7 786 runs  ±0  7 422 ✅  - 312  364 💤 +312  0 ❌ ±0 

Results for commit 71d619b. ± Comparison against base commit f4ee6d1.

This pull request skips 310 tests.
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][10]
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][11]
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][12]
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][1]
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][2]
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][3]
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][4]
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][5]
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][6]
redis.clients.jedis.commands.commandobjects.CommandObjectsJsonCommandsTest[1] ‑ testJsonSetWithFphaParams(String, Keyword, FphaType)[1][7]
…

♻️ This comment has been updated with latest results.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@jit-ci

jit-ci Bot commented Apr 16, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

🛡️ Jit Security Scan Results

CRITICAL HIGH MEDIUM

✅ No security findings were detected in this PR


Security scan by Jit
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@ggivo
Add out-of-band push notification handling
5d1160a
Handle unsupported push notifications gracefully instead of failing the connection.

Fixes errors occurring when push messages are received on connections that are not configured to process them. For example, enabling CLIENT TRACKING on a regular Connection may result in errors when invalidate push messages are delivered.

This change introduces initial support for out-of-band push notifications by:
- detecting push messages on the connection
- silently skipping unsupported push types
@ggivo
ggivo force-pushed the topic/ggivo/CAE-2660-push-notifications branch from e2c8c24 to 5d1160a Compare April 16, 2026 11:33
@ggivo
clean up tests
4d1619f
@ggivo
ggivo marked this pull request as ready for review April 16, 2026 15:52
cursor[bot]
cursor Bot reviewed Apr 16, 2026
View reviewed changes
Comment thread src/main/java/redis/clients/jedis/PushConsumerChain.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

@ggivo
fix: Wrong @experimental annotation
1b80bc0
cursor[bot]
cursor Bot reviewed Apr 16, 2026
View reviewed changes
Comment thread src/main/java/redis/clients/jedis/csc/CacheConnection.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/main/java/redis/clients/jedis/csc/CacheConnection.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

@ggivo
add unit test for PushConsumerChainImpl
a63af1f
cursor[bot]
cursor Bot reviewed Apr 17, 2026
View reviewed changes
Comment thread src/main/java/redis/clients/jedis/Connection.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

ggivo added 3 commits April 17, 2026 08:45
@ggivo
address review comments
10217a3
@ggivo
add test PushInvalidateConsumer triggers cache invalidations
627b68b
@ggivo
format
4424074
cursor[bot]
cursor Bot reviewed Apr 17, 2026
View reviewed changes
Comment thread src/main/java/redis/clients/jedis/Connection.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

@ggivo
ggivo requested review from atakavci and uglide April 17, 2026 09:47
ggivo added 2 commits April 17, 2026 19:25
@ggivo
[csc] protocolReadPushes now uses pushConsumers instead of custom inv…
e447cd1
…alidate processing
@ggivo
Merge branch 'master' into topic/ggivo/CAE-2660-push-notifications
dad4cd7
cursor[bot]
cursor Bot reviewed Apr 17, 2026
View reviewed changes
Comment thread src/main/java/redis/clients/jedis/PushConsumerChainImpl.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/main/java/redis/clients/jedis/Protocol.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

uglide
uglide reviewed Apr 20, 2026
View reviewed changes
Comment thread src/main/java/redis/clients/jedis/csc/CacheConnection.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/main/java/redis/clients/jedis/Protocol.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/main/java/redis/clients/jedis/Protocol.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/main/java/redis/clients/jedis/Protocol.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/main/java/redis/clients/jedis/Protocol.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/main/java/redis/clients/jedis/PushConsumerChainImpl.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

atakavci
atakavci previously approved these changes Apr 20, 2026
View reviewed changes

@atakavci atakavci left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!
my comments are more like personal preference with the semantics.
also, i aggre with @uglide on the use of literals.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread src/main/java/redis/clients/jedis/PushConsumerContext.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/main/java/redis/clients/jedis/Protocol.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

@ggivo
Merge branch 'master' into topic/ggivo/CAE-2660-push-notifications
3daf107
cursor[bot]
cursor Bot reviewed May 5, 2026
View reviewed changes
Comment thread src/main/java/redis/clients/jedis/csc/CacheConnection.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

ggivo added 5 commits May 5, 2026 18:35
@ggivo
extract known push message types as consts
8e2a0e4
@ggivo
remove commented code
f2f7f0d
@ggivo
push consumer chain is now required
ca2b5a5
@ggivo
document push handling
a8035a2
@ggivo
enforce push message as required when initialising PushMessageContext
1212363
@ggivo
ggivo dismissed atakavci’s stale review via 1212363 May 5, 2026 15:35
cursor[bot]
cursor Bot reviewed May 5, 2026
View reviewed changes
Comment thread src/main/java/redis/clients/jedis/Protocol.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

@ggivo
Merge branch 'master' into topic/ggivo/CAE-2660-push-notifications
fbd0dbd
atakavci
atakavci approved these changes May 12, 2026
View reviewed changes

@atakavci atakavci left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
ggivo added 4 commits May 14, 2026 10:57
@ggivo
Merge branch 'master' into topic/ggivo/CAE-2660-push-notifications
cdcf7ae
@ggivo
Merge branch 'master' into topic/ggivo/CAE-2660-push-notifications
280741f
@ggivo
add benchmark for Protocol.read(RedisInputStream,PushConsumerChain)
1b2bf12
@ggivo
perf: eliminate string decoding in PushMessage type checking
7897d31
Replace string-based type checking with byte array comparisons using
Arrays.equals(). PushMessage.getType() now returns byte[] directly
from content.get(0) without decoding or caching.

Adds *_BYTES constants to PushMessageTypes for efficient comparison.
cursor[bot]
cursor Bot reviewed May 18, 2026
View reviewed changes

@cursor cursor Bot left a comment

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 7897d31. Configure here.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread src/main/java/redis/clients/jedis/PushConsumerChainImpl.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/main/java/redis/clients/jedis/csc/PushInvalidateConsumer.java Resolved

Uh oh!

There was an error while loading. Please reload this page.

ggivo added 6 commits May 18, 2026 17:39
@ggivo
Merge branch 'master' into topic/ggivo/CAE-2660-push-notifications
68f170d
@ggivo
address review comments
f429888
 - npe guard
 - check invalidation message format
 - fix tests
@ggivo
format
f643b27
@ggivo
Merge remote-tracking branch 'origin/master' into topic/ggivo/CAE-266…
77192e8
…0-push-notifications
@ggivo
Merge remote-tracking branch 'origin/master' into topic/ggivo/CAE-266…
5de397b
…0-push-notifications
@ggivo
Merge branch 'master' into topic/ggivo/CAE-2660-push-notifications
71d619b
uglide
uglide approved these changes May 20, 2026
View reviewed changes
@ggivo
ggivo merged commit 76be487 into master May 20, 2026
20 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@ggivo
ggivo deleted the topic/ggivo/CAE-2660-push-notifications branch May 20, 2026 08:30
@ggivo ggivo added enhancement techdebt Things that can be improved or refactored labels May 22, 2026
@ggivo ggivo added this to the 8.0.0 milestone May 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@uglide uglide uglide approved these changes
@atakavci atakavci atakavci approved these changes
+1 more reviewer
@cursor cursor[bot] cursor[bot] left review comments
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

enhancement techdebt Things that can be improved or refactored

Projects

None yet

Milestone

8.0.0

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@ggivo @uglide @atakavci
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.