Skip to content

Commit d2309e8

Browse files
committed
fix: Remove unnecessary throws in AutoCloseable.close() implementation
1 parent 80ac694 commit d2309e8

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

entraid/src/main/java/redis/clients/authentication/entraid/EntraIDTokenAuthConfigBuilder.java

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
* Builder class for configuring EntraID token authentication.
2323
* This class provides methods to set various configuration options for EntraID token authentication.
2424
* It extends the TokenAuthConfig.Builder class and implements AutoCloseable.
25-
*
25+
*
2626
* <p>Default values:</p>
2727
* <ul>
2828
* <li>DEFAULT_EXPIRATION_REFRESH_RATIO: 0.75F</li>
@@ -31,22 +31,22 @@
3131
* <li>DEFAULT_MAX_ATTEMPTS_TO_RETRY: 5</li>
3232
* <li>DEFAULT_DELAY_IN_MS_TO_RETRY: 100 (0.1 second)</li>
3333
* </ul>
34-
*
34+
*
3535
* <p>Configuration options:</p>
3636
* <ul>
3737
* <li>{@link #clientId(String)}: Sets the client ID.</li>
3838
* <li>{@link #secret(String)}: Sets the client secret and configures access with secret.</li>
39-
* <li>{@link #key(PrivateKey, X509Certificate)}: Sets the private key and certificate,
39+
* <li>{@link #key(PrivateKey, X509Certificate)}: Sets the private key and certificate,
4040
* and configures access with certificate.</li>
4141
* <li>{@link #authority(String)}: Sets the authority URL.</li>
4242
* <li>{@link #systemAssignedManagedIdentity()}: Configures system-assigned managed identity.</li>
43-
* <li>{@link #userAssignedManagedIdentity(UserManagedIdentityType, String)}:
43+
* <li>{@link #userAssignedManagedIdentity(UserManagedIdentityType, String)}:
4444
* Configures user-assigned managed identity.</li>
4545
* <li>{@link #customEntraIdAuthenticationSupplier(Supplier)}: Sets a custom authentication supplier.</li>
4646
* <li>{@link #scopes(Set)}: Sets the scopes for the token request.</li>
4747
* <li>{@link #tokenRequestExecTimeoutInMs(int)}: Sets the token request execution timeout in milliseconds.</li>
4848
* </ul>
49-
*
49+
*
5050
* <p>Usage:</p>
5151
* <pre>
5252
* {@code
@@ -58,7 +58,7 @@
5858
* .build();
5959
* }
6060
* </pre>
61-
*
61+
*
6262
* <p>Note:</p>
6363
* <ul>
6464
* <li>Only one of ServicePrincipal, ManagedIdentity or customEntraIdAuthenticationSupplier can be configured.</li>
@@ -67,10 +67,10 @@
6767
* For more information and details on how to use, please see:
6868
* <p>https://github.com/redis/jedis/blob/master/docs/advanced-usage.md#token-based-authentication
6969
* <p>https://github.com/redis/lettuce/blob/main/docs/user-guide/connecting-redis.md#microsoft-entra-id-authentication
70-
*
70+
*
7171
* @see TokenAuthConfig.Builder
7272
* @see AutoCloseable
73-
*
73+
*
7474
*/
7575
public class EntraIDTokenAuthConfigBuilder extends TokenAuthConfig.Builder<EntraIDTokenAuthConfigBuilder>
7676
implements AutoCloseable {
@@ -187,7 +187,7 @@ public TokenAuthConfig build() {
187187
}
188188

189189
@Override
190-
public void close() throws Exception {
190+
public void close() {
191191
clientId = null;
192192
secret = null;
193193
key = null;

0 commit comments

Comments
 (0)