Questions tagged [spring-mono]

20 questions
0
votes
1 answer

Throw new RuntimeException() from a Mono, in AOP

I have a reactive springboot application, in it an aspect @Before("approveRejectPointcut()") public void logAfterReturning(JoinPoint joinPoint) { Status newStatus = AspectUtils.returnFirstParameterOfTypeOrFail(allParameters, Status.class,…
0
votes
1 answer

Spring 5 Reactive Mono - Pass Mono value to property of object and call another mono

I'm new to the whole Spring reactive webflux. My problem is pretty simple. In my addActions() I am trying to get a Mono by calling getCurrentVal(). This works fine. But I need to get the value of that and update a property (submission.stateVal).…
John Doe
  • 1,950
  • 9
  • 32
  • 53
0
votes
1 answer

Java Spring WebClient how to get atribute from body response and set to a given class?

I'm trying to consume a given API that returns a body response like this: "access_token": "xkeo94s4qviHSTDIuTCbgRQSeNfrrMamiCN0w6wu", "token_type": "Bearer", "expires_in": 9600, "refresh_token": "PpF0LfLPmdsm9FJFu4YmDBPENqTwGQIqQjw8MqOP" So I…
0
votes
1 answer

Spring Webflux Mono always responds with successful response

I have a endpoint that takes id parameter and send delete product api to delete. productService.delete also returns Mono. The problem is when productService.delete method returns mono error, the endpoint always responds with http 200. And I can see…
0
votes
1 answer

How to solve the, calling for Mono then the result will be used to another Mono, which will then return Mono?

Hi I just started learning reactive programming I have this piece of code here and my process here should be I will call tokenRepository to get the token and then, use the token.getAccessToken() to be used as a parameter on the…
1
2