Runtime components : Channels components : AJAX channel : Concepts : Relationship between the AJAX channel and the HTML channel
  
Relationship between the AJAX channel and the HTML channel
This section describes the similarities and differences between the AJAX channel and the HTML channel.
Both AJAX requests and HTML requests are HTTP requests, and data is transmitted by HTTP requests from the browser to the back end server through an HTTP connection. However, an HTML request that is made through the HTML channel is used to handle business logic, usually a flow of business steps, while an AJAX request that is made through the AJAX channel is used to handle operations that deliver quick responses in an HTML channel state (for example, when customer information is queried in an account transfer page).
There are also differences in the number of HTML and AJAX requests that can be processed on the server-side at the same time. Only one HTML request at a time can be processed on the server-side; meanwhile, multiple AJAX requests can be processed concurrently on the server-side. Because multiple AJAX requests can be processed concurrently, you must be aware that if you use AJAX requests to update context data, the context data might become inconsistent. It is therefore strongly recommended that you use AJAX requests only to perform read context operations.
Note also that when the back end server receives a request, only one channel at a time can access a context. This means that when a context is being accessed through the HTML channel, no AJAX requests can be processed until the HTML requests that are made through the HTML channel have been processed. Because each AJAX request has a timeout value, it is possible that an AJAX request times out and an error message displayed before processing of the HTML request is complete.
Go up to
Concepts