Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Reduce bandwith - save state on client  RSS feed

 
camilla bat
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We're using myfaces and we have some problems regarding performance on the website. Our clients have quite thin networklines, so we need to reduce the amount of data that is floating on the net.
we have done some monitoring and it seems like the web is sending the whole site as response for each request, even if only a small value has changed. The site is about 200 kB which is too heavy for the clients when more clients are using the application at the same time.

Does someone know whether we could save more state at the browser, so the whole page doesn't have to be sent each time?
The Ajax technology could possibly help by sending just part of the page, but we don't have time to start changing the application to using that.

Any ideas? :roll:
 
Alexander Jesse
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Possible alternatives are:
- AJAX (a security nightmare, as it is based on Javascript)
- Javascript pure (sort of AJAX do-it-yourself)
- Eclipse RCP-application using webservices or remote-EJB to communicate with the backend
- Java-Applet (doing your own protocol for backend-access)
 
Tim Holloway
Bartender
Posts: 18531
61
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually, JavaScript's more secure than some things I can mention, but keeping state info on the client side is perilous anyway. I can do extremely evil things to a webapp if it's foolish enough to send me stuff it uses internally.

AJAX/JSF isn't an either/or proposition. You can use AJAX for selected areas of a JSF page as long as you're reasonably careful.

Actually, I expect to see more and more dual-mode (AJAX/Server-maintained) JSF controls coming out in the near future. JSF is great for that, since it can be used to fall back to server-maintained display data if the user has JavaScript disabled , but automatically send AJAX code to the client for better performance if the client will permit it.

Another possibility for partial display update is frames. I realize frames have a bad reputation, but all the objections to frames I know of are about 4 years obsolete now.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!