Remove obsolete field from SecureValueRecovery2Configuration

This commit is contained in:
Chris Eager
2023-05-19 14:30:11 -05:00
committed by Jon Chambers
parent fa8f19fd43
commit a3c37aed47
7 changed files with 4 additions and 20 deletions

View File

@@ -32,7 +32,6 @@ public class SecureValueRecovery2Client {
private final ExternalServiceCredentialsGenerator secureValueRecoveryCredentialsGenerator;
private final URI deleteUri;
private final FaultTolerantHttpClient httpClient;
private final boolean enabled;
@VisibleForTesting
static final String DELETE_PATH = "/v1/delete";
@@ -53,15 +52,10 @@ public class SecureValueRecovery2Client {
.withSecurityProtocol(FaultTolerantHttpClient.SECURITY_PROTOCOL_TLS_1_2)
.withTrustedServerCertificates(configuration.svrCaCertificates().toArray(new String[0]))
.build();
this.enabled = configuration.enabled();
}
public CompletableFuture<Void> deleteBackups(final UUID accountUuid) {
if (!enabled) {
return CompletableFuture.completedFuture(null);
}
final ExternalServiceCredentials credentials = secureValueRecoveryCredentialsGenerator.generateForUuid(accountUuid);
final HttpRequest request = HttpRequest.newBuilder()