In our project we have a server which works as a router (i.e. routers calls from one server to other appropriate servers).
We have APIs as action API and callback APIs. This means, server1 would call router, which would call server2. After sometime the server2 will call router with the result of the request which router will forward to server1 back.
server 1 => action API on router => server 2 server 2 => callback API on router => server 1
We wanted to figure out if it is possible to capture how many calls are going through this whole cycle and how many of them might be failing?
Please let us know if it is possible to fulfil this requirement using APM. We have tried starting a custom transaction using
co.elastic.apm:apm-agent-api, but there seems to be no way to find an existing transaction and stop it in another API call.
Note: We are using multi replica containers, so we might not receive the action and callback on the same pod.