Try OpenEdge Now
skip to main content
Developing AppServer Applications
AppServer and Client Interaction : Understanding synchronous and asynchronous requests : Process control flow

Process control flow

The following figure compares the process flow within an application using synchronous and asynchronous requests.
Figure 1. Synchronous and asynchronous requests
In this figure, one client (Client1) makes synchronous requests and another client (Client2) makes asynchronous requests to two AppServers (Server1 and Server2). For Client1, control flows in sequence between client and AppServer. For Client2, control flows in parallel between client and AppServer. Assuming that the clients and AppServers perform the same work, Client2 can conceivably complete the work in less time than can Client1. The advantage for Client2 comes with the parallelism that asynchronous requests can achieve. In this case, the actual advantage that Client2 affords depends on its ability to respond to the results from the AppServers at the moment they arrive, while doing its own share of the work until the results actually do arrive.