I created a spring cloud task to create a new user in my db,is there any way to post the successfull response message back to my rest service ?,from which i invoked this task.
Asked
Active
Viewed 137 times
1 Answers
0
You could control the desired behavior of the spring-cloud-task
application's lifecycle with the exit codes, but there's no OOTB support to register an automatic callback routine.
In your custom task application, after the DB persistence, you could make a REST call to let the client application update its state.
Alternatively, if you'd like to do this in an asynchronous manner, you could consider writing the outcome to a topic/queue backed by messaging middleware of choice and then have your REST application listen and consume the messages from the broker for relevant updates.

Sabby Anandan
- 5,636
- 2
- 12
- 21