3.3 Strategies for scalability
On demand computing requires the ability to scale up or scale down an application, depending on the current requirements. Thus, scalability is important to improve efficiency and reduce cost.
We start by discussing scalability strategies using WAS that can help us in ensuring high availability, load balancing, and removing bottlenecks.
The basic infrastructure components that make up a WebSphere application are:
- HTTP server and Web server plug-in
- Web container
- EJB container
- Database(s)
IBM WAS implements Web containers and EJB containers in each appserver. The appservers each run in their own JVM.
If we have all components co-located on a single machine, they might:
- Compete for machine resources
- Influence each other's behavior
- Have unauthorized access to strategic resources
One strategy is to physically separate some components, preventing them from competing for resources (CPU, memory, I/O, network, and so on) or to restrict the access to a resource from another machine (for example, inserting a firewall in order to protect confidential information).
The figure above shows the Web container and the EJB container separated on different machines. Although this is a possible configuration, it is not recommended because doing so results in out-of-process calls from the EJB clients in the Web container to the EJB container and will likely have a negative impact on performance. As a result, we will not cover this split JVM topology further in this chapter.
We can also distribute the load among the most appropriate resources, and use workload management techniques such as vertical and horizontal scaling on a clustered configuration.