Weblogic Authors: Yeshim Deniz, Elizabeth White, Michael Meiner, Michael Bushong, Avi Rosenthal

Related Topics: Weblogic

Weblogic: Article

Maximizing Performance, Availability, and Security of BEA WebLogic Clusters

Maximizing Performance, Availability, and Security of BEA WebLogic Clusters

Through advanced clustering capabilities, BEA WebLogic Server-based e-business applications can be scaled across multiple servers. (Note: WebLogic Server supports multiple types of clustering, only one of which is relevant here - what is referred to as Web Clustering. In Web Clustering, the clustering of the HTTP or presentation layer of the Web application is addressed. This is what is referred to here.) Availability is enhanced by replicating application components and their state, as well as client session state information. In the event of the failure of a server mid-session, the client's session can be restored on another server without loss of session data. The WebLogic Server cluster makes this functionality transparent to clients who view the cluster as a single "virtual server."

As software infrastructure evolved to include specialized applications servers optimized for the delivery of Web content, the network infrastructure also evolved to become "content aware." Cisco Systems is an early pioneer in the development of content switching, a category of network devices which are designed to optimize the delivery of Web-based applications. These high-performance networking devices understand the nature of Web-based transactions and how to route them to the most capable server at any given moment in time. They are used to increase the scalability, performance, availability, and security of Web-based applications. This article describes how Cisco CSS 11000 Series Content Services Switches ("Cisco Content Switches") can be used to maximize the capabilities of BEA WebLogic Clusters.

WebLogic Clustering in Action
A single client transaction may require multiple HTTP operations to complete. A simple example of this might be the presentation interface for a Web-based stock trading portal. A client might go through several steps in executing a trade (getting quotes, doing research, placing the order, receiving a confirmation, etc.) The application keeps track of the "state" of this transaction through each of its subsequent phases. In order to provide protection from failure, this session state can be replicated to another server. In the event of failure of the primary server, the session can be reinitiated to a new server (either the server which hosted the state replica or a third server that recovers the session state from it). WebLogic supports three different methods for replicating and recovering session state: database replication (via JDBC), file-based replication, and in-memory replication.

File and database replication are similar. Each server in the cluster maintains connections to a shared file server or database server. State information is written to a file or to a database record as it is created or changed. Upon failure of a server in the cluster, subsequent client requests are routed to another available member of the cluster (more on this shortly). The new server reads the session ID (established at the initiation of the session and stored in a cookie or encoded in the URL of the request) and fetches the associated state from the database or file system. The new server can now continue processing the client's transaction.

In-memory replication sends state information from a primary server to a designated backup, where it is maintained in memory. Upon failure of the primary server, the client will be routed to a new server. This new server will either have the state replica (in which case it designates a new server as the backup, creates a backup copy of the session state, and assumes the primary role) or it will fetch the state from the backup (in which case it assumes the primary role, cleans up the session state from the old backup, elects a new backup server, and creates a new state replica on the backup). Like the session ID, the backup server ID is encoded in the cookie or URL, allowing the new server to recover session state from the backup. The new server can now continue processing the client's transaction.

Request Routing
Because multiple servers in a cluster are capable of servicing a particular set of client requests, some mechanism must be used to route client requests made to the "virtual server" to one of the real servers in the cluster. The first, and simplest, goal of a request routing mechanism is stated as follows:

1.   To balance load across the available servers in the cluster
For transactions that span multiple HTTP operations (and possibly multiple TCP connections), once a client session has been established with a particular server cluster member, subsequent operations should be directed to the same member until the session completes. This will reduce the overhead and latency associated with fetching session state from another server for each successive operation, thereby improving user response time and improving overall utilization of the cluster.

Therefore a second goal of request routing for WebLogic clusters is:

2.   To maintain "persistent sessions" between clients and cluster members who are cooperating to perform complex transaction logic
Simple DNS-based load balancing available in public domain DNS servers such as BIND will allow the operator to configure multiple host addresses in association with a particular domain name (e.g., www.mystore.com). Clients attempting to access this site will be resolved to each of the configured addresses in "round robin" fashion. Clients will cache the returned name-to-address mapping for the time-to-live configured in the DNS server by the domain name owner. (Note: Although this is the specified behavior for DNS clients, actual behavior varies considerably by operating system and by browser.) Subsequent requests to the same host name will be directed to the same server (using the cached mapping) - thereby performing a crude type of session persistence. A major downfall of DNS-based schemes, however, is that they are incapable of routing around a server failure. Once a client is "bound" to a server, that binding remains in place until the time-to-live for the cached name-to-address mapping expires. Clients can, therefore, continue to attempt to contact a host even though that server has failed or been taken out of service. Clearly, then, something more than simple round-robin DNS is needed for a robust local request routing mechanism. (Note: DNS-based techniques, when deployed in conjunction with more robust local request routing schemes, are in fact very useful for disaster recovery and for balancing load between multiple geographically separate locations.) It is therefore appropriate to expand our list of request routing goals.

3.   To rapidly detect and route around server and process failures
Proxy Web server-based request routing takes the approach of front ending the cluster with an additional server which accepts incoming client requests and directs them to the appropriate server. A BEA WebLogic Server acting as a proxy for third-party Web servers is an example of this approach. By participating in the clustering protocol, the proxy is able to detect failure of servers quickly and route around them. Session persistence is provided via examination of the session cookie. Because it is a full member of the cluster, the proxy understands the session cookie format and the associations between sessions and servers. Because they are general-purpose application servers, however, these proxies are not optimized for the task of request routing and are, therefore, lower performance than specialized load-balancing appliances.

Load-balancing appliances are general-purpose PCs with software tuned for loadbalancing applications. Much like first-generation routers, these general-purpose architectures use a single, centralized CPU for all load-balancing decisions as well as for packet forwarding. Additional functionality is added by utilizing off-the-shelf PC boards (such as SSL acceleration cards) and writing drivers to integrate them with the rest of the system. By focusing on a specific task, these appliances provide better performance, redundancy, and features than their proxy server-based counterparts. Ultimately, however, the hardware architecture of appliances becomes the limiting factor in the performance and scalability of the cluster. For enterprise-class applications, performance must be included as one of the goals for request routing.This goal may be stated as follows.

4.   To scale in accordance with the anticipated client request volume and data transfer rates
In much the same way that general-purpose computing architectures became a limiting factor to scaling for first-generation routers, general-purpose PC architectures have become a limiting factor for request routing. Recognizing this, Cisco Systems pioneered the development of the technology now known as "content switching." The core intellectual property associated with content switches is a switching architecture that separates the processing of the control functions associated with request routing (such as server selection, session establishment, and health checking, etc.) from the processing associated with the packet forwarding functions of request routing (such as network address translation [NAT], TTL decrementing, MAC address replacement, etc.) This fundamental separation of function allows Cisco Content Switches to provide both superior features and function as well as superior performance compared to PC-based load-balancing equipment.

Cisco Content Switches Provide High Server Farm Availability
From a logical perspective, Cisco Content Switches are deployed in front of the WebLogic cluster, as shown in Figure 1. Client requests to the cluster are directed to a Virtual IP address (VIP), representing the cluster to the outside world. A Cisco Content Switch receives connections and HTTP requests from the outside world and routes them to the appropriate member(s) of the cluster based on configured policies. These policies will take into account the failover and persistence mechanisms discussed earlier.

Cisco Content Switches provide a complete set of features for maintaining a high-availability WebLogic cluster, including switch redundancy, session state failover, and advanced health checking.

Switch Redundancy
Cisco Content Switches are typically deployed in redundant pairs. In the event of a failure of the primary switch, the secondary switch will take over. Depending on the configuration of session state redundancy, this failover may take place without disrupting the client-to-server connection. Certain configurations may use both switches as simultaneously active and backup for certain groups of servers or content types - a configuration known as "Active-Active" redundancy.

Session State Redundancy
For some applications, it is critical for the Cisco Content Switch failover to occur without disrupting existing client-to-server connections. For such applications, the content switches can be configured to maintain session state information on both primary and secondary switches. In the event of a failure, the redundant switch will forward packets associated with the existing connection between client and server as soon as the underlying network reconverges.

Advanced Health Checking
Cisco Content Switches use both active and passive techniques to monitor server health. By periodically probing servers, the content switch will rapidly detect server failures and quickly re-route connections to available servers. A large variety of health checking features are supported, including the ability to verify Web servers, SSL servers, Application servers, databases, FTP servers, streaming media Servers, and others.

Cookie Switching Technology Offers Flexible Session Persistence Options
As I previously discussed, for performance reasons, once the initial selection of a server within the cluster is made, it is important to keep connections from the same client routed to the same server until the transaction is completed. This is referred to as "session persistence." It is absolutely critical that the content switch leave the session cookies sent from server to client and from client to server intact. Cisco Content Switches also support two different methods for achieving session state persistence for WebLogic clusters.

Active Cookie Insert
When using this method, the content switch is configured to insert a unique cookie for each server when a new session is detected. This cookie is then sent by the client back to the server and used by the content switch to keep the session routed to the same server.

Cookie Matching
In this mode of operation, the content switch is configured to look for a specific string in the cookie that indicates the server which initially set it. This may either be a string that is uniquely identified in the session cookie for this purpose or a different cookie set by the WebLogic programmer. Although this method is potentially more complex from a programming perspective, it gives the Web application designer the most flexibility in controlling the application behavior. (Note: Cookie matching can be used for numerous purposes, including dynamic load shedding and third-party routing. These techniques will not be discussed here.)

Cisco Content Switches Enhance Site Security
Cisco Content Switches can protect the WebLogic Cluster in four different ways.

Access Control Lists
By constructing access control lists on content switches, the operator can control who has access to the real IP addresses of the cluster members as well as who has access to the switches themselves.

Network Address Translation (NAT)
Cisco Content Switches perform NAT from the Virtual IP address (which represents the cluster to the outside world) to the real IP addresses of the cluster members. This allows the server cluster members to be numbered using private IP address space. More importantly, it hides the details of the internals of the cluster configuration.

Denial-of-Service Protection
Because Cisco Content Switches participate in both TCP and HTTP, they are in an ideal position to detect and stop TCP-and HTTP-based denial of service attacks - before they can impact a server.

Firewall Load Balancing
If the application generates enough traffic to warrant additional firewalls, Cisco Content Switches can be used to load balance multiple firewalls.

SSL Acceleration Improves Performance and Enables Persistence
Running SSL on WebLogic Servers is a tremendous drain on server resources. Cisco SSL Acceleration technology (available in Cisco CSS 11500 Content Switches and Catalyst 6500 switches) can offload SSL processing, enabling server resources to be focused on value-added WebLogic functions. In addition, as persistence information used by the Cisco Content Switches is inside the HTTP header, it is no longer visible when carried inside SSL-encrypted sessions. Cisco SSL Acceleration technology terminates these sessions prior to applying content switching decisions, enabling all of the persistence options previously discussed to become available for secure sites.

High Scalability and Performance Options
In addition to raw switching performance, Cisco Content Switches provide capabilities that can be leveraged to scale the performance of WebLogic Servers as well as the performance of client to Server connections.

Server Farm Partitioning
Cisco Content Switches can partition components of a single Web application across multiple cluster members. For example the following two URLs: http://www.mycompany.com/quotes/getquote.jsp and http://www.mycompany.com/trades/order.jsp could be located on two different servers even though the domain name is the same. This allows the application developer to easily scale the application to multiple servers without many code modifications. Furthermore, it maximizes the cache coherency (and thus, performance) of the servers by keeping requests for the same pages on the same servers.

Additionally, Cisco Content Switches may be used to push requests for cacheable content (such as image files) to a set of caches which may serve them more cost effectively than the application servers themselves.

HTTP 1.1 Connection Remapping
When using HTTP 1.1, clients may request multiple URLs over the same TCP connection. This allows the client and server to run more efficiently by reducing the overhead of TCP connection maintenance. When content is partitioned across multiple servers and/or caches as described in the preceding section, it is important to be able to send multiple HTTP GETs for different pieces of content that might arrive over the same HTTP 1.1 connection to different servers. Effectively, the client side HTTP 1.1 connection must be "remapped" from one server to another. Cisco Content Switches perform this function to maximize connection efficiency.

BEA WebLogic Servers include advanced clustering capabilities to scale applications. Cisco Content Switches maximize the performance, availability, and security of BEA WebLogic Server clusters by understanding the nature of Web-based transactions and routing them to the most capable server at any given moment in time. This combined solution results in maximum end-user experience.


  • www.bea.com/products/weblogic/server/ paper_wls_clustering.pdf
  • More Stories By Vadim Rosenberg

    Vadim Rosenberg is the product marketing manager for BEA WebLogic Server. Before joining BEA two years ago, Vadim had spent 13 years in business software engineering, most recently at Compaq Computers (Tandem Division) developing a fault-tolerant and highly scalable J2EE framework.

    More Stories By Brian Walck

    Brian Walck is the director of Product Management at Cisco Systems. His responsibilities include developing products for Cisco’s content switching product line, as well as developing core strategies in content billing and provisioning. He sits on the Networld+Interop advisory board, and has authored numerous white papers.

    Comments (0)

    Share your thoughts on this story.

    Add your comment
    You must be signed in to add a comment. Sign-in | Register

    In accordance with our Comment Policy, we encourage comments that are on topic, relevant and to-the-point. We will remove comments that include profanity, personal attacks, racial slurs, threats of violence, or other inappropriate material that violates our Terms and Conditions, and will block users who make repeated violations. We ask all readers to expect diversity of opinion and to treat one another with dignity and respect.

    @ThingsExpo Stories
    To get the most out of their data, successful companies are not focusing on queries and data lakes, they are actively integrating analytics into their operations with a data-first application development approach. Real-time adjustments to improve revenues, reduce costs, or mitigate risk rely on applications that minimize latency on a variety of data sources. In his session at @BigDataExpo, Jack Norris, Senior Vice President, Data and Applications at MapR Technologies, reviewed best practices to ...
    A strange thing is happening along the way to the Internet of Things, namely far too many devices to work with and manage. It has become clear that we'll need much higher efficiency user experiences that can allow us to more easily and scalably work with the thousands of devices that will soon be in each of our lives. Enter the conversational interface revolution, combining bots we can literally talk with, gesture to, and even direct with our thoughts, with embedded artificial intelligence, whic...
    Cloud Expo | DXWorld Expo have announced the conference tracks for Cloud Expo 2018. Cloud Expo will be held June 5-7, 2018, at the Javits Center in New York City, and November 6-8, 2018, at the Santa Clara Convention Center, Santa Clara, CA. Digital Transformation (DX) is a major focus with the introduction of DX Expo within the program. Successful transformation requires a laser focus on being data-driven and on using all the tools available that enable transformation if they plan to survive ov...
    Smart cities have the potential to change our lives at so many levels for citizens: less pollution, reduced parking obstacles, better health, education and more energy savings. Real-time data streaming and the Internet of Things (IoT) possess the power to turn this vision into a reality. However, most organizations today are building their data infrastructure to focus solely on addressing immediate business needs vs. a platform capable of quickly adapting emerging technologies to address future ...
    With tough new regulations coming to Europe on data privacy in May 2018, Calligo will explain why in reality the effect is global and transforms how you consider critical data. EU GDPR fundamentally rewrites the rules for cloud, Big Data and IoT. In his session at 21st Cloud Expo, Adam Ryan, Vice President and General Manager EMEA at Calligo, examined the regulations and provided insight on how it affects technology, challenges the established rules and will usher in new levels of diligence arou...
    In his session at 21st Cloud Expo, Raju Shreewastava, founder of Big Data Trunk, provided a fun and simple way to introduce Machine Leaning to anyone and everyone. He solved a machine learning problem and demonstrated an easy way to be able to do machine learning without even coding. Raju Shreewastava is the founder of Big Data Trunk (www.BigDataTrunk.com), a Big Data Training and consulting firm with offices in the United States. He previously led the data warehouse/business intelligence and B...
    "Digital transformation - what we knew about it in the past has been redefined. Automation is going to play such a huge role in that because the culture, the technology, and the business operations are being shifted now," stated Brian Boeggeman, VP of Alliances & Partnerships at Ayehu, in this SYS-CON.tv interview at 21st Cloud Expo, held Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA.
    SYS-CON Events announced today that Synametrics Technologies will exhibit at SYS-CON's 22nd International Cloud Expo®, which will take place on June 5-7, 2018, at the Javits Center in New York, NY. Synametrics Technologies is a privately held company based in Plainsboro, New Jersey that has been providing solutions for the developer community since 1997. Based on the success of its initial product offerings such as WinSQL, Xeams, SynaMan and Syncrify, Synametrics continues to create and hone inn...
    "Evatronix provides design services to companies that need to integrate the IoT technology in their products but they don't necessarily have the expertise, knowledge and design team to do so," explained Adam Morawiec, VP of Business Development at Evatronix, in this SYS-CON.tv interview at @ThingsExpo, held Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA.
    The 22nd International Cloud Expo | 1st DXWorld Expo has announced that its Call for Papers is open. Cloud Expo | DXWorld Expo, to be held June 5-7, 2018, at the Javits Center in New York, NY, brings together Cloud Computing, Digital Transformation, Big Data, Internet of Things, DevOps, Machine Learning and WebRTC to one location. With cloud computing driving a higher percentage of enterprise IT budgets every year, it becomes increasingly important to plant your flag in this fast-expanding busin...
    In his Opening Keynote at 21st Cloud Expo, John Considine, General Manager of IBM Cloud Infrastructure, led attendees through the exciting evolution of the cloud. He looked at this major disruption from the perspective of technology, business models, and what this means for enterprises of all sizes. John Considine is General Manager of Cloud Infrastructure Services at IBM. In that role he is responsible for leading IBM’s public cloud infrastructure including strategy, development, and offering m...
    Nordstrom is transforming the way that they do business and the cloud is the key to enabling speed and hyper personalized customer experiences. In his session at 21st Cloud Expo, Ken Schow, VP of Engineering at Nordstrom, discussed some of the key learnings and common pitfalls of large enterprises moving to the cloud. This includes strategies around choosing a cloud provider(s), architecture, and lessons learned. In addition, he covered some of the best practices for structured team migration an...
    No hype cycles or predictions of a gazillion things here. IoT is here. You get it. You know your business and have great ideas for a business transformation strategy. What comes next? Time to make it happen. In his session at @ThingsExpo, Jay Mason, an Associate Partner of Analytics, IoT & Cybersecurity at M&S Consulting, presented a step-by-step plan to develop your technology implementation strategy. He also discussed the evaluation of communication standards and IoT messaging protocols, data...
    Recently, REAN Cloud built a digital concierge for a North Carolina hospital that had observed that most patient call button questions were repetitive. In addition, the paper-based process used to measure patient health metrics was laborious, not in real-time and sometimes error-prone. In their session at 21st Cloud Expo, Sean Finnerty, Executive Director, Practice Lead, Health Care & Life Science at REAN Cloud, and Dr. S.P.T. Krishnan, Principal Architect at REAN Cloud, discussed how they built...
    SYS-CON Events announced today that Evatronix will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Evatronix SA offers comprehensive solutions in the design and implementation of electronic systems, in CAD / CAM deployment, and also is a designer and manufacturer of advanced 3D scanners for professional applications.
    22nd International Cloud Expo, taking place June 5-7, 2018, at the Javits Center in New York City, NY, and co-located with the 1st DXWorld Expo will feature technical sessions from a rock star conference faculty and the leading industry players in the world. Cloud computing is now being embraced by a majority of enterprises of all sizes. Yesterday's debate about public vs. private has transformed into the reality of hybrid cloud: a recent survey shows that 74% of enterprises have a hybrid cloud ...
    22nd International Cloud Expo, taking place June 5-7, 2018, at the Javits Center in New York City, NY, and co-located with the 1st DXWorld Expo will feature technical sessions from a rock star conference faculty and the leading industry players in the world. Cloud computing is now being embraced by a majority of enterprises of all sizes. Yesterday's debate about public vs. private has transformed into the reality of hybrid cloud: a recent survey shows that 74% of enterprises have a hybrid cloud ...
    DevOps at Cloud Expo – being held June 5-7, 2018, at the Javits Center in New York, NY – announces that its Call for Papers is open. Born out of proven success in agile development, cloud computing, and process automation, DevOps is a macro trend you cannot afford to miss. From showcase success stories from early adopters and web-scale businesses, DevOps is expanding to organizations of all sizes, including the world's largest enterprises – and delivering real results. Among the proven benefits,...
    @DevOpsSummit at Cloud Expo, taking place June 5-7, 2018, at the Javits Center in New York City, NY, is co-located with 22nd Cloud Expo | 1st DXWorld Expo and will feature technical sessions from a rock star conference faculty and the leading industry players in the world. The widespread success of cloud computing is driving the DevOps revolution in enterprise IT. Now as never before, development teams must communicate and collaborate in a dynamic, 24/7/365 environment. There is no time to wait...
    SYS-CON Events announced today that T-Mobile exhibited at SYS-CON's 20th International Cloud Expo®, which will take place on June 6-8, 2017, at the Javits Center in New York City, NY. As America's Un-carrier, T-Mobile US, Inc., is redefining the way consumers and businesses buy wireless services through leading product and service innovation. The Company's advanced nationwide 4G LTE network delivers outstanding wireless experiences to 67.4 million customers who are unwilling to compromise on qua...