I am new to spring boot and created 2 micro services. They need to communicate with one other in synchronous and asynchronous way. For synchronous communication, I can use the RestTemplate. But how to do for asynchronous calling ? my requirement for Asynchonous is: lets say I am querying for something from one micro service. To fetch the queried data it will take sometime because of queried for large sum of data. In this case, I need to save the request into some transaction table and return the response with transactionId and callBackAPI. After sometime if I call the callBackAPI with transactionId. Then I should be able to get the previously queried data.
Please help me with this.
Thanks.