jQuery in Action, 2nd edition*
The moose likes Servlets and the fly likes scalability Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "scalability" Watch "scalability" New topic
Author

scalability

chris crompton
Greenhorn

Joined: Feb 20, 2004
Posts: 3
Given this scenario I could do with some advice:
Having done lots of Java many years ago (Java 1.1) I have recently done a jsp course and feel confident putting together a few jsp pages to access a large database using stored procedures and a small pool of database connections. The intended web server being Apache Tomcat on Windows.
Does anyone have any suggestions on how best (from a simplicity point of view) I could ensure this application has maximum scaleability?
Thanks
Frank Carver
Sheriff

Joined: Jan 07, 1999
Posts: 6920
Wow. To achieve maximum scaleability is a huge task. The best discussion of this I can think of at the moment is in the book "Running Weblogs with Slash" from O'Reilly. The folks at Slashdot have to handle phenomenal traffic - but it took them years to get to a point where they can handle it. At the very least you will need multiple high-bandwidth network connections and multiple machines to service them, then you will need an architecture which supports the maximum amount of static cacheing, to minimise the amount of data that needs be transferred between machines or fetched and processed dynamically.
Without knowing more about your situation, it's hard to give any more detailled suggestions. Can you tell us more about what throughput you are expecting (both in terms of hits and bandwidth) and where you think any bottlenecks or lengthy processing might take place? Are you expecting more "reads" than "writes" or the other way round?


Read about me at frankcarver.me ~ Raspberry Alpha Omega ~ Frank's Punchbarrel Blog
Matthew Phillips
Ranch Hand

Joined: Mar 09, 2001
Posts: 2676
I don't mean to be a Microsoft basher, but running it on Windows will incur some scalability issues. If you run it on a Windows workstation OS, there is a 10 connection limit. If you run it on a Windows server OS, they you are limited by licensing. You may want to consider a different OS.


Matthew Phillips
Kyle Brown
author
Ranch Hand

Joined: Aug 10, 2001
Posts: 3892
    
    5
Besides the hardware an OS issues, the thing you can do to make sure your application is scaleable is to make it stateless. Completely and totally stateless. Each URL should be a world unto its own as much as possible, only tied together through information passed in on the URL or in hidden fields or cookies.
Session state scalability depends on the container you use. That's the price you pay for keeping session state and not having a stateless application. Some vendor's containers are much more scalable than others. With Tomcat, for instance, you get what you pay for.
Kyle


Kyle Brown, Author of Persistence in the Enterprise and Enterprise Java Programming with IBM Websphere, 2nd Edition
See my homepage at http://www.kyle-brown.com/ for other WebSphere information.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: scalability