MACROMEDIA COLDFUSION 4.5-ADMINISTRING COLDFUSION SERVER Manual page 157

Table of Contents

Advertisement

Chapter 6: Creating Scalable and Highly Available Web Sites
how an application manages multiple concurrent user requests when accessing the
same database records. If an application does not impose any database locking
mechanism on multiple requests to update the same record, data integrity can be
compromised in the database. In such a scenario, two users could make simultaneous
modifications to a record, but only the last change would take effect.
For example, consider a Human Resources Web application on a company intranet.
The HR Generalist adds two new employee records to the HR database by filling out a
Web form because two new employees have just been hired. The Generalist enters
most of the vital information into the records but doesn't yet have the new employees'
phone extensions or HMO selections, and therefore leaves those fields blank. Later in
the day, the HR Generalist's boss, the HR Director, obtains this information from both
new hires and decides to enter it in the database herself. However, one of the new
employees, after speaking with her husband, decides to change her HMO selection
from the basic selection to the PPO choice, which allows greater flexibility in choosing
physicians. The employee calls the HR Generalist to tell him of the change, and the
Generalist says he will take care of it immediately. Unbeknownst to the HR Director,
the HR Generalist adds the information into the employee records at the same time
that the HR Director is attempting to add the outdated information.
In this scenario, if the application uses an appropriate database concurrency
validation mechanism, such as a SQL
a message informing her that she could not access the employee record because it was
in use, thereby alerting her that the HR Generalist is trying to change the record.
However, if the application did not use such a validation mechanism, the HR Director
would overwrite the new data that the Generalist had just entered, resulting in data
integrity problems. This simple example illustrates how important it is that your
dynamic Web applications handle database concurrency issues well.
Application partitioning
The way an application has been partitioned and deployed dramatically affects its
ability to scale. Therefore, a key development objective must be to ensure that each
partition scales independently of the others, thereby eliminating application
bottlenecks.
Application partitioning refers to the logical and physical deployment of an
application's three core types of logic, or services — presentation, business, and data
access. If you are familiar with the concept of tiered client/server application
development, you already understand the rationale for developing applications in this
way. However, if you're not, we'll run through a short review to shed some light on this
methodology's benefits.
An application, regardless of whether it is a Web application or a more traditional
client/server application, has three main categories of logic, or services.
Presentation services — Refer to the application's user interface by which users
interact with the application's features. In a traditional client/server
application, this logic sits on a client's PC, typically as a proprietary executable
file. In a Web paradigm, there is no specific proprietary client software required,
other than a browser. Emerging Web technologies can help you leverage
clause, then the HR Director would receive
WHERE
135

Advertisement

Table of Contents
loading

This manual is also suitable for:

Coldfusion 4.5

Table of Contents