The general interaction between a state-aware AppServer and client proceeds as follows:
1. The client connects to the AppServer broker with or without the help of a NameServer, which provides the address of the broker from a list of AppServers that support a specified application service.
Note: The algorithm the NameServer uses to choose the broker depends on whether the NameServer is configured for load balancing. For more information, see Loadbalancing and session models.
2. The AppServer broker connects the client to an available AppServer agent, which makes the session context available from any client previously connected to this agent. The broker is then available to accept a connection request from another client.
3. The client invokes an application service request (synchronously or asynchronously).
4. The connected agent executes the request and returns the results to the client.
5. The client handles the results of the application service request and either invokes another request as in Step 3 or disconnects from the AppServer as in Step 6.
6. When the client no longer requires the application service, it disconnects from the AppServer agent and cleans up after its connection to the application service, making the AppServer agent available to handle another client connection.
The number of available simultaneous client connections to a state-aware AppServer corresponds to the number of AppServer agents that it is configured to start up and manage at one time.