From e18609ff1d0955c1676b810baf4715ae32aea9cf Mon Sep 17 00:00:00 2001 From: Mark Paluch Date: Fri, 31 Jan 2020 11:48:37 +0100 Subject: [PATCH] Un-deprecate ClientOptions.pingBeforeActivateConnection #1208 pingBeforeActivateConnection turns out to be useful when using RESP2 in cases where the connection authentication should be delayed. Another case is when the PING should be used as auth PING to test whether a reconnect was successful. Related ticket: #1201. --- src/main/java/io/lettuce/core/ClientOptions.java | 6 ------ .../java/io/lettuce/core/cluster/ClusterClientOptions.java | 1 - 2 files changed, 7 deletions(-) diff --git a/src/main/java/io/lettuce/core/ClientOptions.java b/src/main/java/io/lettuce/core/ClientOptions.java index 720b8c2ba8..b2b69ea71d 100644 --- a/src/main/java/io/lettuce/core/ClientOptions.java +++ b/src/main/java/io/lettuce/core/ClientOptions.java @@ -135,10 +135,7 @@ protected Builder() { * * @param pingBeforeActivateConnection true/false * @return {@code this} - * @deprecated since 5.2. PING during connection handshake becomes mandatory with RESP3. This method will be removed - * with Lettuce 6. */ - @Deprecated public Builder pingBeforeActivateConnection(boolean pingBeforeActivateConnection) { this.pingBeforeActivateConnection = pingBeforeActivateConnection; return this; @@ -328,10 +325,7 @@ public ClientOptions.Builder mutate() { * activated and enabled for use. If the check fails, the connect/reconnect is treated as failure. * * @return {@literal true} if {@literal PING} barrier is enabled. - * @deprecated since 5.2. PING during connection handshake becomes mandatory with RESP3. This method will be removed with - * Lettuce 6. */ - @Deprecated public boolean isPingBeforeActivateConnection() { return pingBeforeActivateConnection; } diff --git a/src/main/java/io/lettuce/core/cluster/ClusterClientOptions.java b/src/main/java/io/lettuce/core/cluster/ClusterClientOptions.java index 72da28680e..a82d25fb0e 100644 --- a/src/main/java/io/lettuce/core/cluster/ClusterClientOptions.java +++ b/src/main/java/io/lettuce/core/cluster/ClusterClientOptions.java @@ -177,7 +177,6 @@ public Builder topologyRefreshOptions(ClusterTopologyRefreshOptions topologyRefr } @Override - @Deprecated public Builder pingBeforeActivateConnection(boolean pingBeforeActivateConnection) { super.pingBeforeActivateConnection(pingBeforeActivateConnection); return this;