From 80f568bd47424ebc22b1695d55c1a073f3b452ab Mon Sep 17 00:00:00 2001 From: Madhura Bhave Date: Thu, 1 Aug 2019 15:59:24 -0700 Subject: [PATCH] Clarify RestTemplateBuilder rootUri documentation Closes gh-15343 --- .../springframework/boot/web/client/RestTemplateBuilder.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/spring-boot-project/spring-boot/src/main/java/org/springframework/boot/web/client/RestTemplateBuilder.java b/spring-boot-project/spring-boot/src/main/java/org/springframework/boot/web/client/RestTemplateBuilder.java index 0be891182d..721df5882d 100644 --- a/spring-boot-project/spring-boot/src/main/java/org/springframework/boot/web/client/RestTemplateBuilder.java +++ b/spring-boot-project/spring-boot/src/main/java/org/springframework/boot/web/client/RestTemplateBuilder.java @@ -133,7 +133,10 @@ public class RestTemplateBuilder { /** * Set a root URL that should be applied to each request that starts with {@code '/'}. - * See {@link RootUriTemplateHandler} for details. + * Since this works by adding a {@link UriTemplateHandler} to the + * {@link RestTemplate}, the root URL will only apply when {@code String} variants of + * the {@link RestTemplate} methods are used for specifying the request URL. See + * {@link RootUriTemplateHandler} for details. * @param rootUri the root URI or {@code null} * @return a new builder instance */