From 490aaa1ed888082d793faa3cd7084e683a1a7c23 Mon Sep 17 00:00:00 2001 From: Gihwan Kim Date: Thu, 28 Dec 2023 21:02:27 +0900 Subject: [PATCH 1/2] Fix usage of WebClientAdapter in reference documentation See gh-31917 --- .../modules/ROOT/pages/integration/rest-clients.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework-docs/modules/ROOT/pages/integration/rest-clients.adoc b/framework-docs/modules/ROOT/pages/integration/rest-clients.adoc index 9350587756f..04ef7c970e0 100644 --- a/framework-docs/modules/ROOT/pages/integration/rest-clients.adoc +++ b/framework-docs/modules/ROOT/pages/integration/rest-clients.adoc @@ -906,8 +906,8 @@ For `WebClient`: [source,java,indent=0,subs="verbatim,quotes"] ---- - WebClient client = WebClient.builder().baseUrl("https://api.github.com/").build(); - WebClientAdapter adapter = WebClientAdapter.forClient(webClient) + WebClient webClient = WebClient.builder().baseUrl("https://api.github.com/").build(); + WebClientAdapter adapter = WebClientAdapter.create(webClient) HttpServiceProxyFactory factory = HttpServiceProxyFactory.builderFor(adapter).build(); RepositoryService service = factory.createClient(RepositoryService.class); From b1c0b6566630a8605366c18e015d8d0bf2df5390 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Nicoll?= Date: Thu, 28 Dec 2023 13:52:57 +0100 Subject: [PATCH 2/2] Polish "Fix usage of WebClientAdapter in reference documentation" See gh-31917 --- .../modules/ROOT/pages/integration/rest-clients.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/framework-docs/modules/ROOT/pages/integration/rest-clients.adoc b/framework-docs/modules/ROOT/pages/integration/rest-clients.adoc index 04ef7c970e0..d2fb293e204 100644 --- a/framework-docs/modules/ROOT/pages/integration/rest-clients.adoc +++ b/framework-docs/modules/ROOT/pages/integration/rest-clients.adoc @@ -907,7 +907,7 @@ For `WebClient`: [source,java,indent=0,subs="verbatim,quotes"] ---- WebClient webClient = WebClient.builder().baseUrl("https://api.github.com/").build(); - WebClientAdapter adapter = WebClientAdapter.create(webClient) + WebClientAdapter adapter = WebClientAdapter.create(webClient); HttpServiceProxyFactory factory = HttpServiceProxyFactory.builderFor(adapter).build(); RepositoryService service = factory.createClient(RepositoryService.class); @@ -1090,7 +1090,7 @@ responses performed through the client: .defaultStatusHandler(HttpStatusCode::isError, resp -> ...) .build(); - WebClientAdapter clientAdapter = WebClientAdapter.forClient(webClient); + WebClientAdapter clientAdapter = WebClientAdapter.create(webClient); HttpServiceProxyFactory factory = HttpServiceProxyFactory .builder(clientAdapter).build(); ----