WebClient
개념 및 예시
WebClient webClient = WebClient.create("<http://localhost:8080>");
Mono<BookDto.Response> response =
webClient
.patch()
.uri("/v10/books/{book-id}", 20)
.bodyValue(requestBody)
.retrieve()
.bodyToMono(BookDto.Response.class);
response.subscribe(book -> {
log.info("bookId: {}", book.getBookId());
log.info("description: {}", book.getDescription());
});Timeout 처리
exchangeToMono / exchangeToFlux
Last updated