Skip to content

[maintenance events] Push notification listener #4194

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 29 commits into
base: feature/maintenance-events
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
9d5f0f3
Introduce push handler
ggivo Jun 20, 2025
0f96e2d
Introduce PushHandlerChain for composable push event handling
ggivo Jun 23, 2025
4aec187
Handle relax timeout for maintenance events
ggivo Jun 25, 2025
67d4afa
Merge branch 'master' into feature/hu-notifications
ggivo Jul 2, 2025
ab62e9d
Support custom Push listeners for Jedis client
ggivo Jul 1, 2025
b36d7f8
Add proactiveRebindEnabled configuration option
ggivo Jul 3, 2025
0452a93
PushHandler is now provided through JedisClientConfig instead through…
ggivo Jul 4, 2025
4bd38da
Fix NPE in CacheConnection
ggivo Jul 4, 2025
4ad3fce
[cleanup] Use weak reference in AdaptiveTimeoutHandler to avoid memor…
ggivo Jul 7, 2025
f475177
[cleanup] Fix javadoc errors
ggivo Jul 7, 2025
56cd409
[cleanup] Fix TransactionCommandsTest mocked test
ggivo Jul 7, 2025
175b773
Moving/Rebind initial support
ggivo Jul 9, 2025
c19d8a5
Mocked relaxed timeout test
ggivo Jul 9, 2025
4ee525d
Mocked rebind test
ggivo Jul 9, 2025
b940ad7
Fix : wrong order connection.rebind pool.clear
ggivo Jul 10, 2025
7efbe72
[clean up] Address review comments from a-TODO-rov
ggivo Jul 10, 2025
b0987e0
add more rebind tests
ggivo Jul 11, 2025
7e11737
clean up
ggivo Jul 11, 2025
b769492
clean up remove unused test method
ggivo Jul 11, 2025
e7ffd1d
fix relaxed timeout on blocking command
ggivo Jul 21, 2025
a67b5cb
format
ggivo Jul 21, 2025
d34f72d
Merge branch 'redis:master' into feature/hu-notifications
ggivo Jul 28, 2025
5a59b85
enforce code formating for new classes
ggivo Jul 28, 2025
5d6c322
reformat to fix java docs
ggivo Jul 28, 2025
c6dec9b
force formating of TimeoutOptions.java
ggivo Jul 28, 2025
f5d57d4
Address review comments
ggivo Jul 28, 2025
15dc654
Address review comments
ggivo Jul 29, 2025
0e39aa4
Address review comments
ggivo Jul 29, 2025
8d9a43f
format ConnectionTestHelper
ggivo Jul 29, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -348,6 +348,14 @@
<include>src/test/java/redis/clients/jedis/commands/jedis/ClusterStreamsCommandsTest.java</include>
<include>src/test/java/redis/clients/jedis/commands/jedis/PooledStreamsCommandsTest.java</include>
<include>src/test/java/redis/clients/jedis/resps/StreamEntryDeletionResultTest.java</include>
<include>**/Maintenance*.java</include>
<include>**/Push*.java</include>
<include>**/Rebind*.java</include>
<include>src/test/java/redis/clients/jedis/upgrade/*.java</include>
<include>src/test/java/redis/clients/jedis/util/server/*.java</include>
<include>**/TimeoutOptions.java</include>
<include>**/*Handler.java</include>
<include>**/ConnectionTestHelper.java</include>
</includes>
</configuration>
<executions>
Expand Down
25 changes: 25 additions & 0 deletions src/main/java/redis/clients/jedis/AbstractListenerHandler.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
package redis.clients.jedis;

import java.util.Collection;
import java.util.List;
import java.util.concurrent.CopyOnWriteArrayList;

abstract class AbstractListenerHandler<T> implements ListenerHandler<T> {
private final List<T> listeners = new CopyOnWriteArrayList<>();

public void addListener(T listener) {
listeners.add(listener);
}

public void removeListener(T listener) {
listeners.remove(listener);
}

public void removeAllListeners() {
listeners.clear();
}

public Collection<T> getListeners() {
return listeners;
}
}
Loading
Loading