diff --git a/spring-web/src/main/java/org/springframework/web/client/support/RestClientHttpServiceGroupAdapter.java b/spring-web/src/main/java/org/springframework/web/client/support/RestClientHttpServiceGroupAdapter.java index 57d8d776d6..a48497c56b 100644 --- a/spring-web/src/main/java/org/springframework/web/client/support/RestClientHttpServiceGroupAdapter.java +++ b/spring-web/src/main/java/org/springframework/web/client/support/RestClientHttpServiceGroupAdapter.java @@ -23,7 +23,7 @@ import org.springframework.web.service.registry.HttpServiceGroupConfigurer; /** * Adapter for groups backed by {@link RestClient}. - * + * * @author Rossen Stoyanchev * @since 7.0 */ diff --git a/spring-web/src/main/java/org/springframework/web/service/registry/AbstractHttpServiceRegistrar.java b/spring-web/src/main/java/org/springframework/web/service/registry/AbstractHttpServiceRegistrar.java index 999afabe76..e0adc829ac 100644 --- a/spring-web/src/main/java/org/springframework/web/service/registry/AbstractHttpServiceRegistrar.java +++ b/spring-web/src/main/java/org/springframework/web/service/registry/AbstractHttpServiceRegistrar.java @@ -169,8 +169,8 @@ public abstract class AbstractHttpServiceRegistrar implements private ClassPathScanningCandidateComponentProvider getScanner() { if (this.scanner == null) { - Assert.state(environment != null, "Environment has not been set"); - Assert.state(resourceLoader != null, "ResourceLoader has not been set"); + Assert.state(this.environment != null, "Environment has not been set"); + Assert.state(this.resourceLoader != null, "ResourceLoader has not been set"); this.scanner = new HttpExchangeClassPathScanningCandidateComponentProvider(); this.scanner.setEnvironment(this.environment); this.scanner.setResourceLoader(this.resourceLoader); @@ -302,14 +302,14 @@ public abstract class AbstractHttpServiceRegistrar implements @Override public GroupSpec register(Class... serviceTypes) { - addHttpServiceTypes(groupName, clientType, serviceTypes); + addHttpServiceTypes(this.groupName, this.clientType, serviceTypes); return this; } @Override public GroupSpec detectInBasePackages(Class... packageClasses) { for (Class packageClass : packageClasses) { - detect(groupName, clientType, packageClass.getPackageName()); + detect(this.groupName, this.clientType, packageClass.getPackageName()); } return this; } @@ -317,7 +317,7 @@ public abstract class AbstractHttpServiceRegistrar implements @Override public GroupSpec detectInBasePackages(String... packageNames) { for (String packageName : packageNames) { - detect(groupName, clientType, packageName); + detect(this.groupName, this.clientType, packageName); } return this; } diff --git a/spring-web/src/main/java/org/springframework/web/service/registry/HttpServiceGroup.java b/spring-web/src/main/java/org/springframework/web/service/registry/HttpServiceGroup.java index a4ed906615..de5632cd07 100644 --- a/spring-web/src/main/java/org/springframework/web/service/registry/HttpServiceGroup.java +++ b/spring-web/src/main/java/org/springframework/web/service/registry/HttpServiceGroup.java @@ -69,10 +69,10 @@ public interface HttpServiceGroup { /** * Not specified, falling back on a default. * @see ImportHttpServices#clientType() - * @see HttpServiceGroups#clientType() + * @see HttpServiceGroups#clientType() * @see AbstractHttpServiceRegistrar#setDefaultClientType */ - UNSPECIFIED; + UNSPECIFIED } } diff --git a/spring-web/src/main/java/org/springframework/web/service/registry/HttpServiceProxyRegistryFactoryBean.java b/spring-web/src/main/java/org/springframework/web/service/registry/HttpServiceProxyRegistryFactoryBean.java index 4c9dc096c6..421510c710 100644 --- a/spring-web/src/main/java/org/springframework/web/service/registry/HttpServiceProxyRegistryFactoryBean.java +++ b/spring-web/src/main/java/org/springframework/web/service/registry/HttpServiceProxyRegistryFactoryBean.java @@ -89,14 +89,13 @@ public final class HttpServiceProxyRegistryFactoryBean Assert.notNull(this.applicationContext, "ApplicationContext not initialized"); // Set client builders - groupAdapters.forEach((clientType, groupAdapter) -> { + this.groupAdapters.forEach((clientType, groupAdapter) -> this.groupSet.stream() .filter(group -> group.clientType().equals(clientType)) - .forEach(group -> group.initialize(groupAdapter)); - }); + .forEach(group -> group.initialize(groupAdapter))); // Apply group configurers - groupAdapters.forEach((clientType, groupAdapter) -> { + this.groupAdapters.forEach((clientType, groupAdapter) -> { Collection> configurers = this.applicationContext.getBeansOfType(groupAdapter.getConfigurerType()).values(); @@ -181,7 +180,7 @@ public final class HttpServiceProxyRegistryFactoryBean return this.declaredGroup.clientType(); } - public void initialize(HttpServiceGroupAdapter adapter) { + public void initialize(HttpServiceGroupAdapter adapter) { this.clientBuilder = adapter.createClientBuilder(); this.groupAdapter = adapter; } diff --git a/spring-web/src/main/java/org/springframework/web/service/registry/ImportHttpServices.java b/spring-web/src/main/java/org/springframework/web/service/registry/ImportHttpServices.java index 65f96f609e..6ee756f26b 100644 --- a/spring-web/src/main/java/org/springframework/web/service/registry/ImportHttpServices.java +++ b/spring-web/src/main/java/org/springframework/web/service/registry/ImportHttpServices.java @@ -28,7 +28,7 @@ import org.springframework.core.annotation.AliasFor; import org.springframework.web.service.annotation.HttpExchange; /** - * Annotation to identify HTTP Service types (interfaces with + * Annotation to declare HTTP Service types (interfaces with * {@link HttpExchange @HttpExchange} methods) for which to create client proxies, * and have those proxies registered as beans. *