The difference between request response and the new Web 2 programming model
connomon 0600010TDW Visits (2646)
As programmers, new technology is always interesting. But for most of us - when that technology surfaces in a usable programming model - is when it becomes real.
The Web 2 programming model is fundamentally different than the Web or ICCS programming models of the past.
The Web programming model revolved around designing a group of forms that in some way map to our desired business process. In many ways the information processed on each form was sequential; start here - do this - end here. As well, we were reasonably limited by what could fit on available real estate.
As a result, A user entered a request (form or URL), our application processes it, builds the next form, sent it, waited for a response, then built the next form sent it ... and on and on. After each request and before each response the user waits. 1 second, 5 seconds, 1 minute, etc. The traditional Web programming model is like this - and fancy enough - the traditional CICS programming model, albeit "green screen" driven, was also identical to this.
Things have changed. Users don't want to spend their time hitting buttons or function keys to move from form to form. And they don't want to wait. They do want to do more. They want to process more information now - the more information - the better the decision making process - and the more productive and ultimately revenue driven the user can be.
We still do requests and responses. But now the requests and responses can happen in an asynchronous manner. Only part, not all of the form waits for the response from the server. The user can go to other pages, other parts of the current page, even move on to other URL's.
Even better yet, as well the entire page - as in a traditional web application - doesn't have to reload and redraw.
And a side advantage - our back end servers aren't spending all their time serving up HTML web pages. They still do that on occasion. But the requests for information result in responses in XML. The web page doesn't have to be resent unless the application requires it.
And a second side advantage - the new programming model is easier. Developers need not be constrained by always having to manage the sequential form flows discussed above.
And yes, you can still create whole pages - that wait for responses - if that's what you like. But you'll still use the Web 2 model rather than the legacy Web model discussed above.
Wait, did I just use legacy and Web in the same sentence. Yes, any fundamental change has the potential to make the past legacy. I think this is a good thing. It means we're still being innovative and continue to evolve. And someday the Web 2 model will be legacy too. But the good news. The older Web model still works, is being developed - and isn't going away anytime soon, as the older CICS "green screen" model is still working and being developed as well. But as we've seen in the past and will continue to see into the future - there now is a better way.