Skip to content

Commit 21bf696

Browse files
committed
formating
1 parent 779edca commit 21bf696

File tree

2 files changed

+20
-14
lines changed

2 files changed

+20
-14
lines changed

src/main/java/io/lettuce/core/ClientOptions.java

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -706,33 +706,40 @@ public TimeoutOptions getTimeoutOptions() {
706706

707707
/**
708708
* Defines the re-authentication behavior of the Redis client in relation to the {@link CredentialsProvider}.
709-
*/s
709+
*/
710710
public enum ReauthenticateBehavior {
711711

712712
/**
713713
* This is the default behavior. The client will fetch current credentials from the underlying
714714
* {@link RedisCredentialsProvider} only when required.
715715
*
716-
* <p>No re-authentication is performed automatically when new credentials are emitted by the
717-
* {@link StreamingCredentialsProvider} .</p>
716+
* <p>
717+
* No re-authentication is performed automatically when new credentials are emitted by the
718+
* {@link StreamingCredentialsProvider} .
719+
* </p>
718720
*
719-
* <p>This behavior is suitable for use cases with static credentials or where explicit reconnection
720-
* is required to change credentials.</p>
721+
* <p>
722+
* This behavior is suitable for use cases with static credentials or where explicit reconnection is required to change
723+
* credentials.
724+
* </p>
721725
*/
722726
DEFAULT,
723727

724728
/**
725729
* Automatically triggers re-authentication whenever new credentials are emitted by the
726730
* {@link StreamingCredentialsProvider} or any other credentials manager.
727731
*
728-
* <p>When enabled, the client subscribes to the credentials stream provided by the
729-
* {@link StreamingCredentialsProvider} (or other compatible sources) and issues an {@code AUTH}
730-
* command to the Redis server each time new credentials are received. This behavior supports
731-
* dynamic credential scenarios, such as token-based authentication, or credential rotation where credentials
732-
* are refreshed periodically to maintain access.</p>
732+
* <p>
733+
* When enabled, the client subscribes to the credentials stream provided by the {@link StreamingCredentialsProvider}
734+
* (or other compatible sources) and issues an {@code AUTH} command to the Redis server each time new credentials are
735+
* received. This behavior supports dynamic credential scenarios, such as token-based authentication, or credential
736+
* rotation where credentials are refreshed periodically to maintain access.
737+
* </p>
733738
*
734-
* <p>Note: {@code AUTH} commands issued as part of this behavior may interleave with user-submitted
735-
* commands, as the client performs re-authentication independently of user command flow.</p>
739+
* <p>
740+
* Note: {@code AUTH} commands issued as part of this behavior may interleave with user-submitted commands, as the
741+
* client performs re-authentication independently of user command flow.
742+
* </p>
736743
*/
737744
ON_NEW_CREDENTIALS
738745
}

src/test/java/io/lettuce/core/cluster/RedisClusterStreamingCredentialsProviderlIntegrationTests.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,8 +140,7 @@ void nodeSelectionApiShouldWork() {
140140
@Test
141141
void shouldPerformNodeConnectionReauth() {
142142
ClusterClientOptions origClientOptions = redisClient.getClusterClientOptions();
143-
origClientOptions.mutate()
144-
.reauthenticateBehavior(ClientOptions.ReauthenticateBehavior.ON_NEW_CREDENTIALS).build();
143+
origClientOptions.mutate().reauthenticateBehavior(ClientOptions.ReauthenticateBehavior.ON_NEW_CREDENTIALS).build();
145144
redisClient.setOptions(origClientOptions.mutate()
146145
.reauthenticateBehavior(ClientOptions.ReauthenticateBehavior.ON_NEW_CREDENTIALS).build());
147146

0 commit comments

Comments
 (0)