« phAtJAX, AJAX Client and Server implementation | Main | The Ajax Experience 2006 »

AJAX Applications vs Server Load?

Squink asked in Slashdot about AJAX applications and server load related. Certainly we could find now many useful information about AJAX but there is not yet so many good benchmarks or profiling done for real applications.

"I've got the fun job of having to recode a medium sized (500-1000 users) community site from the ground up. For this project, gratuitous use of XMLHttpRequest appears to be in order. However - with the all of the hyperbole surrounding AJAX, I've not been able to find any useful information regarding server load [Apache + MySQL] when using some of the more useful AJAX applications, such as autocomplete. Is this really a non-issue, or are people neglecting to discuss this for fear of popping the Web2.0 bubble?"

I think the answer have been said in the comments, its all about caching. Everytime we talk about high traffic and memory consumption for servers the first thing that came in mind, not only with AJAX but even for all other applications, is caching. But you'll ask in what requesting cached data will be useful for AJAX ?

I have experienced high traffic problem in my website for example, let's take the case of syndication file which was generated by server everytime. Even that this was not using too much memory, but multiply it with the number of users online it will be so much ! And the solution was to generate a static XML file everytime there is something new. Requesting static data from the server will solve the scalability problem and it does.

The same could goes for AJAX, if an application will have high traffic the most easy and efficient solution is to generate static files in the server side that the client will request everytime. It could be even session based, but could have other security issues. But the most important is to have in the server side the necessary tools to update this static file or regenerate it.

This is the way to get more performance with less ressources, we could also scale the servers to support some applications by distributed architecture, or other more complex systems this will cost more compared to the optimizations that could be done on the application level.

Bookmark this article at these sites
Comments
1

At the bottom of our Ajax Catalog Search Engine, you can find a table indicating, per-request and average response time for:
- server (1 million record database)
- internet
- client javascript

Enjoy !

Post a comment





(Email will remain hidden)





Please enter the security code you see here




Related entries
Email to a friend
Email this article to:


Your email address:


Message (optional):