I have made a http web service application which will be called from remote clients (browser).
This web service also in turn fetches data from another web service running locally on the server via http ReST calls, then is supposed to return what it got from the local service to the remote client. In short, my application, an intermediary server, is also a client to that other local server.
I have had a problem figuring out how to get the response from the local service into my handler that is supposed to return the result to the remote clients, since the call to the local other server is asynchronous and so does not return anything directly. In other words how do I get my "Sub Handle(req As ServletRequest, resp As ServletResponse)" to resp.Write(the result of my http client)?
I guess there's probably a simple way to do this that I'm just not getting.
Help appreciated.
This web service also in turn fetches data from another web service running locally on the server via http ReST calls, then is supposed to return what it got from the local service to the remote client. In short, my application, an intermediary server, is also a client to that other local server.
I have had a problem figuring out how to get the response from the local service into my handler that is supposed to return the result to the remote clients, since the call to the local other server is asynchronous and so does not return anything directly. In other words how do I get my "Sub Handle(req As ServletRequest, resp As ServletResponse)" to resp.Write(the result of my http client)?
I guess there's probably a simple way to do this that I'm just not getting.
Help appreciated.