diff --git a/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/couchbase/CouchbaseAutoConfiguration.java b/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/couchbase/CouchbaseAutoConfiguration.java index 28d1a2e31f1..f4e99d186cd 100644 --- a/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/couchbase/CouchbaseAutoConfiguration.java +++ b/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/couchbase/CouchbaseAutoConfiguration.java @@ -129,6 +129,7 @@ public class CouchbaseAutoConfiguration { .trustManagerFactory(getTrustManagerFactory(this.properties.getEnv().getSsl(), sslBundles))); } + @SuppressWarnings("removal") private TrustManagerFactory getTrustManagerFactory(CouchbaseProperties.Ssl ssl, SslBundles sslBundles) { if (ssl.getKeyStore() != null) { return loadTrustManagerFactory(ssl); @@ -140,6 +141,7 @@ public class CouchbaseAutoConfiguration { throw new IllegalStateException("A key store or bundle must be configured when SSL is enabled"); } + @SuppressWarnings("removal") private TrustManagerFactory loadTrustManagerFactory(CouchbaseProperties.Ssl ssl) { String resource = ssl.getKeyStore(); try { diff --git a/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/couchbase/CouchbaseProperties.java b/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/couchbase/CouchbaseProperties.java index c8d9b3ae36a..6132c73bbd3 100644 --- a/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/couchbase/CouchbaseProperties.java +++ b/spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/couchbase/CouchbaseProperties.java @@ -19,6 +19,7 @@ package org.springframework.boot.autoconfigure.couchbase; import java.time.Duration; import org.springframework.boot.context.properties.ConfigurationProperties; +import org.springframework.boot.context.properties.DeprecatedConfigurationProperty; import org.springframework.util.StringUtils; /** @@ -177,18 +178,26 @@ public class CouchbaseProperties { this.enabled = enabled; } + @Deprecated(since = "3.1.0", forRemoval = true) + @DeprecatedConfigurationProperty( + reason = "SSL bundle support with spring.ssl.bundle and spring.couchbase.env.ssl.bundle should be used instead") public String getKeyStore() { return this.keyStore; } + @Deprecated(since = "3.1.0", forRemoval = true) public void setKeyStore(String keyStore) { this.keyStore = keyStore; } + @Deprecated(since = "3.1.0", forRemoval = true) + @DeprecatedConfigurationProperty( + reason = "SSL bundle support with spring.ssl.bundle and spring.couchbase.env.ssl.bundle should be used instead") public String getKeyStorePassword() { return this.keyStorePassword; } + @Deprecated(since = "3.1.0", forRemoval = true) public void setKeyStorePassword(String keyStorePassword) { this.keyStorePassword = keyStorePassword; }