4,144 questions
0 votes
0 answers
63 views
WebClient sending an empty multipart request to Flask service
I have a problem with sending multipart/form-data requests from my Java service (using WebClient but same history with RestTemplate) to Flask service. It seems like a sent body is just empty as I get ...
0 votes
0 answers
29 views
Unit Test with MockWebServer with OAUTH failing
I am trying to write a unit test for a webclient that has a oauth filter. I see the error , org.springframework.security.oauth2.client.ClientAuthorizationException: [server_error] at org....
0 votes
0 answers
36 views
MockWebServer throwing " unable to find valid certification path to requested target" error
I am trying to create a mockwebserver to unit test a webclient parent code : public DetailResponse getDetail(String id) { WebClient newWebClient = getLoggingWebClient(webClient); ...
0 votes
0 answers
61 views
Specific Error message depending on HttpStatus in WebClient .onStatus
I want depending on the HttpStatus of the error, throw an exception with the associated error message. But somehow response.rawStatusCode() doesn't work. This is currently my code: JsonNode APISong = ...
0 votes
1 answer
228 views
Spring WebClient returns 400 Bad Request when calling URL with encoded path, but the same URL works Postman
I'm using Spring Boot and WebClient to call an external REST service (not developed by me). To do that, I build a full URL by appending an encoded file path to the base service URL. When I copy the ...
0 votes
0 answers
56 views
Hoverfly Proxy setting not working with Spring WebClient
I am trying to mock the responses using hoverfly, but it not working with webclient. Same setup works if i switch to RestTemplate for service calls and i am using following webclient configs. @Bean ...
0 votes
0 answers
53 views
Spring webflux webclient inserting empty body for get requests
I am using webclient to integrate with external get API WebClient webClient = WebClient.builder().filter(logRequestAndResponse()).baseUrl("url").build(); return webClient.get() .uri(...
1 vote
0 answers
149 views
Why does my WebClient response return null for generic types in Spring WebFlux?
I'm using Spring WebFlux with WebClient to fetch data from an API. When the response contains a list of objects, everything works fine with .bodyToFlux(MyClass.class).collectList(). However, when I ...
0 votes
0 answers
83 views
Spring WebFlux WebClient - 400 Bad Request for Webclient POST call
I am trying to use spring Reactive Webclient to post payload remote microservice. When I post it via postman I am getting response back with { Status: “Success”, statusId:”dff-1244”}. But from via IJ ...
2 votes
0 answers
54 views
Spring WebFlux ExchangeFunctions logs missing request body details
Question Why doesn't the request body logging include serialized request data? How can I configure my application to log the complete request body details? I'm trying to log the request body sent ...
1 vote
0 answers
86 views
What are the differences between ExchangeStrategies and wiretap for WebClient logging?
I am working with Spring WebClient and exploring ways to enable detailed logging for debugging purposes. Specifically, I am looking at two approaches: ExchangeStrategies and wiretap. Below are the ...
0 votes
0 answers
48 views
how to force close socket in RestClient
What should I do if I want to disconnect while still receiving responses from RestClient? (java, kotlin) val result = restClient().get() .uri("") .exchange { : HttpRequest, ...
1 vote
0 answers
57 views
unable to get access_token from ADFS when spring webflux webclient is used
We have an existing code that makes calls to ADFS endpoint for UI authentication passing below 4 parameters "grant_type":"authorization_code" "redirect_uri":<...
1 vote
1 answer
90 views
Data duplication or async on-demand oriented communication on microservices
In our current microservice, we store the data that doesn't belong to us and we persist them all through external events. And we use these duplicate data (that doesn't belong to us) in our actual ...
-3 votes
1 answer
199 views
RestTemplate, RestClient VS WebClient
I have a Spring web application which does Http calls to external web services, for now it uses WebClient from webflux for making such calls, but every time it uses .block() since we don't need ...