Comparing Ajax to the JSF Cycle
The steps for an ordinary JSF cycle:
- Invoke a URL by clicking on a link
- Handle the request on the server and write to the response
- Overwrite the previous response with a new response
The steps for an Ajax cycle:
- Invoke a URL from JavaScript code on the client
- Handle the URL on the server and write to the response
- After the response is complete, integrate the response into the DOM
(Document Object Model—discussed later)
In an Ajax request, the entire page is not refreshed; only part of the page
is updated.
This subtle difference opens the door to interesting interactions.