diff --git a/spring-boot-project/spring-boot-docs/src/main/java/org/springframework/boot/docs/io/restclient/webclient/ssl/Details.java b/spring-boot-project/spring-boot-docs/src/main/java/org/springframework/boot/docs/io/restclient/webclient/ssl/Details.java new file mode 100644 index 00000000000..88c9821c53f --- /dev/null +++ b/spring-boot-project/spring-boot-docs/src/main/java/org/springframework/boot/docs/io/restclient/webclient/ssl/Details.java @@ -0,0 +1,21 @@ +/* + * Copyright 2012-2023 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.springframework.boot.docs.io.restclient.webclient.ssl; + +public class Details { + +} diff --git a/spring-boot-project/spring-boot-docs/src/main/java/org/springframework/boot/docs/io/restclient/webclient/ssl/MyService.java b/spring-boot-project/spring-boot-docs/src/main/java/org/springframework/boot/docs/io/restclient/webclient/ssl/MyService.java index 7ed0790f8f2..d564c602f8d 100644 --- a/spring-boot-project/spring-boot-docs/src/main/java/org/springframework/boot/docs/io/restclient/webclient/ssl/MyService.java +++ b/spring-boot-project/spring-boot-docs/src/main/java/org/springframework/boot/docs/io/restclient/webclient/ssl/MyService.java @@ -19,7 +19,6 @@ package org.springframework.boot.docs.io.restclient.webclient.ssl; import reactor.core.publisher.Mono; import org.springframework.boot.autoconfigure.web.reactive.function.client.WebClientSsl; -import org.springframework.boot.docs.io.restclient.webclient.Details; import org.springframework.stereotype.Service; import org.springframework.web.reactive.function.client.WebClient; diff --git a/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/MyService.kt b/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/MyService.kt index 4c318306812..dc9848d6f2b 100644 --- a/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/MyService.kt +++ b/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/MyService.kt @@ -30,7 +30,8 @@ class MyService(webClientBuilder: WebClient.Builder) { } fun someRestCall(name: String?): Mono
{ - return webClient.get().uri("/{name}/details", name).retrieve().bodyToMono(Details::class.java) + return webClient.get().uri("/{name}/details", name) + .retrieve().bodyToMono(Details::class.java) } } diff --git a/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/ssl/Details.kt b/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/ssl/Details.kt new file mode 100644 index 00000000000..589e3db8069 --- /dev/null +++ b/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/ssl/Details.kt @@ -0,0 +1,19 @@ +/* + * Copyright 2012-2023 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.springframework.boot.docs.io.restclient.webclient.ssl + +class Details diff --git a/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/ssl/MyService.kt b/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/ssl/MyService.kt index 3ddac190f95..011d84f73fe 100644 --- a/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/ssl/MyService.kt +++ b/spring-boot-project/spring-boot-docs/src/main/kotlin/org/springframework/boot/docs/io/restclient/webclient/ssl/MyService.kt @@ -17,7 +17,6 @@ package org.springframework.boot.docs.io.restclient.webclient.ssl import org.springframework.boot.autoconfigure.web.reactive.function.client.WebClientSsl -import org.springframework.boot.docs.io.restclient.webclient.Details import org.springframework.stereotype.Service import org.springframework.web.reactive.function.client.WebClient import reactor.core.publisher.Mono @@ -28,11 +27,13 @@ class MyService(webClientBuilder: WebClient.Builder, ssl: WebClientSsl) { private val webClient: WebClient init { - webClient = webClientBuilder.baseUrl("https://example.org").apply(ssl.fromBundle("mybundle")).build() + webClient = webClientBuilder.baseUrl("https://example.org") + .apply(ssl.fromBundle("mybundle")).build() } fun someRestCall(name: String?): Mono
{ - return webClient.get().uri("/{name}/details", name).retrieve().bodyToMono(Details::class.java) + return webClient.get().uri("/{name}/details", name) + .retrieve().bodyToMono(Details::class.java) } }