DBMS
 

 


Partitioning Applications: Application Partitioning Comes of Age in a Web-centric World. By Nelson King.

To paraphrase a slogan: The Internet -- this changes everything. What that means for most people who design and develop applications has yet to sink in, but it will. Even if you don't develop for the Internet, its influence on the design of your applications will be powerful. This might happen in several ways, but near the top of the list is application partitioning, which is often defined as breaking an application into components to improve performance and effectiveness. The Internet is an environment that almost demands this approach. It's a fairly sure bet that within 10 years nobody will build an application without at least considering how it can be made into components and then partitioned. This, of course, needs some explanation.

There was a simpler time, about 15 years ago, when applications of all kinds ran either on a central computer or on individual personal computers. To use a slightly pejorative term, these were monolithic applications, built as a complete unit for one environment. This type of architecture has faded rapidly in the last 10 years. The need to share data forced developers to connect computers of all kinds. Soon came the notion that PCs and their inexpensive processing power should run the user interface, and larger computers (such as mainframes, minicomputers, and server PCs) should handle the data. In effect, the PC user-interface part of an application became the client of the database management server. In terms of partitioning, client/server is described as two-tier. Two-tier client/server is the simplest form of partitioning; the trend toward n-tier architectures is an extension of this first step.

There are many reasons to use this approach, but they can be boiled down to three:

More efficient use of resources. By dedicating hardware and specialized software to specific tasks, you can achieve better performance. In essence, multiple CPUs in their own optimized environments are better than one giant, centralized CPU. Furthermore, instead of shipping vast amounts of data across a network to be processed at each workstation, the processing takes place at the server, and only the requested data is sent to the workstation. For transaction processing (TP) monitors, the server also saves resources by channeling many clients through fewer database connections.

Improved maintenance. By breaking up functionality between data and user interface, a greater degree of fault tolerance and data integrity is possible. A fault-tolerant architecture means that one server can pick up the workload of another server that fails. This is easier to do if an application is partitioned as opposed to monolithic. To a certain extent, the ongoing chore of data maintenance is easier because it is (more or less) centralized. In theory, a partitioned application requires less work if one of the major components such as the database management software is changed. There is a degree of hardware and software independence.

Scalability. Once the partition is made, it becomes easier to use more and/or bigger data servers to scale up the application to include different platforms and networks. The general rationale for client/server computing has become familiar. PCs should run the user interface because their CPU time is less expensive, and server machines should handle data processing rather than clog networks transmitting data to "fat-client" PCs. Still, it took over 10 years for client/server implementations to become widespread. There are reasons for the delay, which are also applicable to other partitioning schemes:

You could add to this list plain old inertia. Unless the superiority of a new system is overwhelming, its acceptance will usually be slow and measured. Compare, for example, the adoption of client/server computing with that of the Internet.

Time to Split

Even before the onslaught of the Internet, the two-tier model of partitioning was under pressure to evolve. To help you understand why, a specific example might be helpful. The story begins with the founding of the Orinoco Music Company, a retailer of music CDs, in 1991. The company's claim to fame was its large catalog of titles (about 36,000), which customers could access via computers in the store. A LAN with three workstations and one server accomplished this arrangement. One workstation handled the business transactions: sales, inventory, and correspondence. The farsighted owners invested in a custom client/server system using two of the fledgling programs of the time: Powersoft PowerBuilder (now part of Sybase) and SQL Windows (now Centura).

In 1992, the successful store instituted a buyer's club that offered CDs at a substantial discount depending on a variety of factors such as season, volume of purchases, and type of music. In the terms we use today, the store added over 300 business rules to the system. Their innovation, and it was an important one, was delivering the club members' current standing with every purchase -- on the spot -- as a marketing tool. The club idea was successful, bringing in 2,500 new members in one year, which suggested that additional stores might be appropriate. In 1993, the company built two new stores and was faced with the typical design issues involved with linking the stores via computer.

A difficult factor, as you might guess, was the desire to continue providing a realtime summary for the club members at the point of purchase. Because of the geographic separation, the speed and reliability of communications (or the lack thereof) would affect the normal transaction processing that assembled the customer's information, updated it, and prepared the printed form. Up to this point, most of the business rules had been coded into the client software, but now the company faced an unwieldy communications bottleneck getting data to and from the workstation, and it also faced the difficulty of updating each store's software when the business rules changed (which they often did).

The company could have thrown a fast and expensive communications link at the problem, but instead it chose to use one of the new partitioning products, in this case from Forté Software Inc. (Oakland, Calif.). This decision separated the business rules from both the data management and client software, putting them into an independent process. Using this approach, the system assembled club member's status summaries at a central server and only the final format -- ready for printing -- was sent to the workstation at a store. This is a representative description of three-tier partitioning.

Partitioning the Middle Ground

As it turns out, managing business rules is only one of many application services that can be partitioned in the middle ground between client and server. In fact, an industry seems to be emerging in this area of computing, spearheaded by a cohort of aggressive new companies and products. To give you the flavor of what's involved, here's a rundown of typical services and some of the products associated with them:

Transaction Monitoring

Almost by definition, tiered applications update the state of the business, which makes it extremely important to ensure the reliability of each database update. Some vendors, such as Forté, do this themselves; however, most vendors farm out the responsibility for transaction monitoring to well-known OLTP products such as BEA Systems Inc.'s (Sunnyvale, Calif.) Tuxedo.

Performance Monitoring and Load Balancing

As the volume of activity increases and the amount of network communication among the data server, application server (the third tier), and client becomes more complex, some applications can benefit from constant monitoring of performance and the ability to adjust parameters for load balancing. This is another area in which some products, such as Forté, handle most of the service internally and others provide hooks to specialized performance-monitoring software (such as BMC Software Inc. [Houston] and Tivoli Systems Inc. [a subsidiary of IBM Corp., Austin, Texas]).

Legacy System Encapsulation

Several products that feature partitioning, notably Antares Alliance Group's (Dallas) ObjectStar and Sapiens ISA Inc.'s (Durham, N.C.) ObjectPool, specialize in the encapsulation of legacy systems within wrapper classes. This method of encapsulation makes it possible to distribute data and at least some of the application logic among three tiers. For example, legacy data is linked to the same server routines that handle all application data, and business logic is extracted and made available to both the client and server.

Component Management

As an application becomes partitioned, it is broken into several components that are distributed to at least the workstations and a server -- although the hardware configuration is typically more complex. In this environment, it is important to make sure that all components remain consistent with each other -- for example, making sure that they are of the same version. This is an area in which some of the older partitioning products from Forté, Seer Technologies Inc. (Cary, N.C.), and Dynasty Technologies Inc. (Lisle, Ill.) have developed the most advanced services, usually in the form of some kind of object identification and version control.

Fault Tolerance

As environments become more distributed, the probability of a node or network failure increases. Network fault-tolerant measures might protect data on the server, but you may require fault tolerance built into the application to preserve the integrity of application activity. For example, Seer HPS provides alternative routing, transparent gateways, and store and forward mechanisms to ensure that applications remain active. With Forté, you can replicate critical application services, and Forté will automatically redirect service requests to the backup copy whenever the primary copy is unavailable.

Repartitioning

In situations where changes in the server environment are common, the ability to change the mix of tiers and services as they are distributed on different pieces of hardware -- "repartitioning" -- is emerging as a major battleground for vendors. Some products use a map of the physical environment and the developer (or administrator) can drag-and-drop application components from one node to another. Other vendors, such as Four Seasons Software Inc. (Edison, N.J.) and Passport Corp. (Paramus, N.J.), feature dynamic repartitioning schemes. Passport uses incremental compilation of objects at run time to enable application logic to determine the distribution of objects. In a different tack, Four Seasons SuperNova uses a dispatch table configured at the time of deployment to determine how application objects are partitioned.

Business-Rule Management

Although it may be one of the older reasons for partitioning an application, business-rule management has taken on new importance from the widespread use of business process reengineering (BPR) and, frankly, because the state of business-rule maintenance in most existing applications is dreadful. Most of the partitioning products and many of the client/server development systems offer business-rule management, and several vendors have focused their products in this area. For example, USoft's (Brisbane, Calif.) USoft Developer specializes in running a business-rules engine that unifies all business logic at one server. Instead of using application code, the rules are stored as entries in a repository that organizes them for easy maintenance.

Application Management

Most of the other services I've already listed can radically affect the operation of an application. At some point, probably earlier than later, it becomes important to monitor and manage the application as a whole. This is a relatively new area for partitioning. One product, Unify Corp.'s (Sacramento, Calif.) AppMan for VISION, is an early example of a client/server development tool that takes a comprehensive approach to all key requirements of application management: event management, performance management, software distribution, administration, security, and asset management.

Obviously, not all of these services are appropriate for all applications, nor do they all necessarily coexist on a single server. There are so many options for application design that it can't really be called three-tier any more: The operative buzzword is "n-tier architecture." (See Figure 1.)

Objects and Partitions

Although partitioning in various forms existed before object orientation entered into the mainstream, it is important to emphasize that objects are a vital enabling technology for partitioning. Although it was possible to partition an application by breaking it up as files or modules, nothing beats objects for the job. You have the ability to create almost any size object, and there is great control over the content of each object. It's possible to encode business rules as relatively large objects with names such as "invoice" or "bill-of-lading" that directly relate to the domain of the application, or use very small objects that contain a single method -- for instance, one SQL query call.

The flexibility of packaging an application within objects makes it much easier to segregate user-interface code from data and business rules. That, in turn, makes it easier to partition, especially for programs such as Four Seasons' SuperNova and Dynasty Technologies' Dynasty, which use the object (class) definitions to perform automatic or dynamic repartitioning.

Then, too, object-oriented programming is now the standard for developing the client side of an application. Nearly all client/server and partitioning products offer a GUI development system based on one version of OOP or another. At this point, only the environment of the relational database servers isn't object-oriented, and if that's bothersome, you can try one of the object-oriented DBMSs.

Enter the Web

In some ways, the Internet -- more specifically the Web -- is just another network. Some have called it the world's largest client/server system, where you have "thin clients" (browsers) and Web servers for HTML pages. Described this way, application partitioning on the Web might be a variation of what's done on any other network. But it's not.

Without using scripting languages such as JavaScript or VBScript, browsers don't act like regular application clients because they can't be directly programmed, they don't have application logic capabilities, and they have a limited set of presentation tools. Then, too, HTML pages are a rather specialized type of form that don't behave like the sophisticated forms of most client/server applications. Nor are Web servers the same as LAN servers because specialized software is required -- in addition to the network operating system -- to provide services for the HTML pages (and other aspects of Web communication). Most data-management services are not part of the Web server and are usually provided by additional software with connections to external database systems.

Because of the somewhat limited features of the "basic" Web, we've witnessed an all-out creative (and competitive) assault on browser enhancements, Web application development, database connectivity, and (perhaps most important in the long run) object management. The results include the Java language, Java applets, JavaBeans, ActiveX components, Visual Café and InterDev programming environments, IIOP, CORBA, and DCOM. The last three are specifications for how objects can be passed around a network as components of applications.

That these are all object-oriented elements is no accident. You've probably heard the siren song of distributed objects and electronic commerce. It's sung by most of the heavyweights of the computer industry, and the baseline is object technology. In this environment, most applications -- big and small -- are going to be created from many components, more or less on the fly. This presents a very different paradigm from LAN-based applications. Even the data will be different -- everyone expects it to be loaded with multimedia datatypes and include streaming data (such as video and audio).

True Web applications will have some stiff requirements: They must cooperate with ORBs and browsers, which means adapting to standards (or sometimes the lack thereof). They must run with many different operating systems, user interfaces, and databases while the configurations used are changing unpredictably. Because the current Internet protocols are "stateless" (lacking essentials such as events and execution states), application partitioning will need to be dynamic while at the same time providing structure for coordinating objects.

In this environment of wide-traveling objects and their dense web of messaging, the concept of "tiers" makes little sense. Almost by definition, Web applications will be multitiered and partitioned. This doesn't mean that there is no role for traditional application partitioning. Most services, such as business-rule management, transaction monitoring, and fault tolerance, will be just as needed -- if not more so -- on the Web. But other services, especially application management, are going to play in a world controlled by ORB software, and the rules are going to be quite different.

Much of the Web approach (such as browsers and HTML servers) will even be carried over to Intranets, the close cousin of the corporate LAN. Consequently, here too partitioning will often be different: more distributed and more difficult to coordinate.

Eventually, all application design will change, if for no other reason than to keep up with the innovation and momentum of the Internet. For now, however, you can develop a traditional application that uses a gateway into the Internet, in effect adding another tier or two, or you can design the entire application to use Web browsers for the client partition and Web servers as the primary service of the network server. Most of the client/server and partitioning products are beginning to recognize the Internet, Java, and CORBA, but only a few such as Passport Corp.'s (Paramus, N.J.) IntRprise are able to handle traditional applications and Internet/Intranet applications with the same tools.

Simplicity Isn't Always Easy

A new definition of partitioning is evolving. Partitioning will be about application services of many kinds, no doubt many more than we have now. The goals of partitioning were, and remain, to improve the performance of distributed applications and to ensure security, data integrity, and maintainability. To accomplish these goals, applications will be organized as objects and linked with specialized partitioning software that will provide the services. How all this plays together will be a matter of designing partitioning architectures -- browser to Web server, Web server to database server, Web server to a CORBA ORB, and so on -- an almost infinite variety of combinations. The application designer will be free to pick and choose.

This is all well and good, but you can't assume that application components will fit like Legos into full-scale business applications. In principle, standards such as CORBA or DCOM should let you pluck components from all over that can interoperate as objects. But the objects must still be designed to work together or at least follow similar guidelines. They must also operate together in an extremely diverse and rapidly changing environment. Achieving such cooperation among objects will be difficult. It recalls what has been said about the reasons for slow acceptance of the client/server model: incompatibility, complexity, and lack of tools. Application-partitioning schemes could well be part of the problem as well as part of a solution. At the moment, with most of the grand vision for distributed objects still on paper, the situation can be summed up rather briefly: It's all new, exciting, and very unproven.


Nelson King has been a database application developer for over 15 years and has written eight books on the subject. You can email Nelson at nhking@winternet.com.


* Antares Alliance Group, Dallas, TX; 800-416-2888, 972-447-5500, or fax 972-447-5783; www.antaresalliance.com.
* BEA Systems Inc., Sunnyvale, CA; 800-817-4232, 408-743-4000, or fax 408-734-9234; www.beasys.com.
* BMC Software Inc., Houston, TX; 800-841-2031, 713-918-8800, or fax 713-918-8000; www.bmc.com.
* Dynasty Technologies Inc., Lisle, IL; 630-769-8500 or fax 630-769-9903; www.dynasty.com.
* Forté Software Inc., Oakland, CA; 510-869-3400 or fax 510-869-3480; www.forte.com.
* Four Seasons Software Inc., Edison, NJ; 800-949-0110, 908-248-6667, or fax 908-248-6675; www.4seasons.com.
* Passport Corp., Paramus, NJ; 201-634-1100 or fax 201-634-0406; www.passport4gl.com.
* Sapiens USA Inc., Durham, NC; 800-416-2888, 972-447-5500, or fax 972-447-5783; www.antaresalliance.com.
* Seer Technologies Inc., Cary, NC; 919-380-5000 or fax 919-469-1910; www.seer.com.
* Tivoli Systems Inc. (a subsidiary of IBM Corp.), Austin, TX; 512-436-8000 or 512-794-0623; www.tivoli.com.
* Unify Corp., Sacramento, CA; 800-455-2405, 916-928-6400, or fax 916-928-6406; www.unify.com.
* USoft, Brisbane, CA; 415-875-3300 or fax 415-875-3333; www.usoft.com.



Figure 1.


--An example of n-tier partitioning.

Subscribe to DBMS and Internet Systems -- It's free for qualified readers in the United States
May 1997 Table of Contents | Other Contents | Article Index | Search | Site Index | Home

DBMS and Internet Systems (http://www.dbmsmag.com)
Copyright © 1997 Miller Freeman, Inc. ALL RIGHTS RESERVED
Redistribution without permission is prohibited.
Please send questions or comments to dbms@mfi.com
Updated Monday, April 14, 1997