From 9e4ebe9d69a9ec5db582c47adbc4f1fd92bfdc6a Mon Sep 17 00:00:00 2001 From: MatejNedic Date: Wed, 18 Dec 2024 23:01:13 +0100 Subject: [PATCH] Align `S3ConfigDataLocationResolver` resolving behavior with Spring Boot resolvers (#1299) Align `S3ConfigDataLocationResolver` behaviour with Spring Boot to resolve properties without taking profile names into account --- .../config/s3/S3ConfigDataLocationResolver.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/spring-cloud-aws-autoconfigure/src/main/java/io/awspring/cloud/autoconfigure/config/s3/S3ConfigDataLocationResolver.java b/spring-cloud-aws-autoconfigure/src/main/java/io/awspring/cloud/autoconfigure/config/s3/S3ConfigDataLocationResolver.java index ba6106ca9..3e52c4f68 100644 --- a/spring-cloud-aws-autoconfigure/src/main/java/io/awspring/cloud/autoconfigure/config/s3/S3ConfigDataLocationResolver.java +++ b/spring-cloud-aws-autoconfigure/src/main/java/io/awspring/cloud/autoconfigure/config/s3/S3ConfigDataLocationResolver.java @@ -27,7 +27,6 @@ import org.springframework.boot.context.config.ConfigDataLocation; import org.springframework.boot.context.config.ConfigDataLocationNotFoundException; import org.springframework.boot.context.config.ConfigDataLocationResolverContext; -import org.springframework.boot.context.config.Profiles; import org.springframework.boot.context.properties.bind.Bindable; import org.springframework.boot.context.properties.bind.Binder; import org.springframework.boot.logging.DeferredLogFactory; @@ -60,8 +59,8 @@ protected String getPrefix() { } @Override - public List resolveProfileSpecific(ConfigDataLocationResolverContext resolverContext, - ConfigDataLocation location, Profiles profiles) throws ConfigDataLocationNotFoundException { + public List resolve(ConfigDataLocationResolverContext resolverContext, + ConfigDataLocation location) throws ConfigDataLocationNotFoundException { S3Properties s3Properties = loadProperties(resolverContext.getBinder()); List locations = new ArrayList<>();