Oct. 3, 2010, 5:48 a.m.
posted by fractal
Evolution of Component ServicesHistorically, enterprise applications were written as large monolithic programs that ran on powerful but expensive mainframe computers. Over time, with experience developing monolithic applications and with the modern advancements in the personal computer technology, system architects were able to make some observations:
These observations were the foundation of the component-based distributed application development systems that would evolve over the next several years on the Windows platforms. I'll briefly summarize this evolution in the next few sections. Component Object Model (COM)COM was one of the first technologies to address component-based development on the Windows platform. COM allows applications to be built from components supplied by different software vendors. In addition to this, COM also defines a binary standard for component interoperability. This ensures that the components written by one developer can interoperate with components written by other developers without requiring users to have any knowledge of the inner workings of a component. COM became immensely popular for developing enterprise applications. There was soon a large collection of libraries available from third-party software vendors to perform various common tasks. Programmers could now quickly design a large program by assembling various COM components that were readily available. Many enterprise application developers started developing software that is divided in discrete logical parts called tiers. Tiers enable an application to be developed and deployed in modular fashion. Applications that have multiple tiers are commonly known as n-tier applications. One of the common approaches to tiered development is the three-tier approach, in which the application is divided into three parts, as shown in Figure.
Programmers prefer to write business logic in COM components instead of ASP and SQL Server stored procedures because the COM components provide better performance and are easy to develop and debug. COM components that encapsulate business rules and logic to perform a specific task are also called business objects. In an enterprise application, several business objects interoperate with each other to perform a business transaction. In an online bookstore, for example, when a customer orders a book, a transaction needs to be performed. This transaction may involve several tasks, such as verifying and charging the customer's credit card, updating the inventory, and shipping the book to the customer. A business object may perform each of these tasks. Sometimes business objects may interoperate with each other while residing on different computers. However, there is more to enterprise development than just components. As an example, for a successful transaction, all its tasks should succeed. If even one of these tasks fails then it is important to undo all the changes made to the system in its attempt to perform this transaction (also referred to as rollback of the transaction). Rollback is important to maintain the integrity of a system. Maintaining the system's integrity becomes increasingly difficult when you have a distributed application where each of these tasks is performed on a different computer. With lack of any special support from the operating system, many efforts of enterprise developers were spent in writing code to coordinate transactions in each application that they developed. Microsoft realized the need to provide this infrastructure as part of Windows to position Windows as a platform for enterprise applications. The result came in the form of Microsoft Transaction Server (MTS). Microsoft Transaction Server (MTS)MTS represented a complete paradigm shift in how programmers looked at the application server. With MTS, the application server does not merely host the components but also provides useful services to them. One of the most important services provided by MTS is automatic transaction management. NOTE ACID Properties A well-designed transaction has ACID properties. ACID is an acronym that stands for the following:
To provide the automatic transaction service, MTS coordinates a set of business objects to perform an operation. Each of these objects then votes for the success or failure of the transaction based on the task that it individually performs. If all the business objects vote for the success of the transaction then the system changes are finalized or committed. On the other hand, if any of the business objects votes for a failure, any changes made to the system during the transaction are undone or rolled back and the system is restored to its original state as if nothing had happened. In addition to transactions, MTS also provides other services such as concurrency management and component-based security. With MTS providingall these services, the work of an enterprise application developer is simplified. The developer can now focus on writing the business logic instead of developing an application development framework on her own. The success of MTS encouraged Microsoft to consolidate other common services that an enterprise application developer may need and make them a part of the platform. The result of this initiative came with the launch of Windows 2000 in the form of COM+. COM+ 1.0 and COM+ 1.5Microsoft has positioned COM+ as a unified platform for developing component-oriented distributed applications. Although from its name the technology looks more like a new version of COM, COM+ is instead a new version of MTS. It is important to understand this distinction because COM+ is not a new standard for developing components but instead COM+ is a platform that provides application services to the COM components. The initial release of COM+ (that is, COM+ 1.0), which comes with Windows 2000, upgrades MTS and provides a new set of services in addition to automatic transaction processing. These services include the following:
NOTE Key Requirements for an Enterprise Application The following list describes some of the key requirements that any enterprise application must include:
Microsoft introduced an update of COM+—COM+ 1.5—with the release of Windows XP. COM+ 1.5 has several enhancements over the COM+ 1.0 features, including the following:
COM+ 2.0 (The .NET Framework)In fact, the .NET Framework, in the initial phase of its development, was known as COM+ 2.0. However, later Microsoft renamed it because the first release of the .NET Framework is actually more of an upgrade of COM than of COM+. The .NET Framework provides a new approach to creating components that replaces the need for COM. These components execute in a managed execution environment known as the Common Language Runtime (CLR), which provides low-level services such as memory management, versioning, and security to the components. In addition, the .NET Framework also provides a new set of object-oriented libraries that enables programmers to develop applications in a better and faster way. The task of developing the .NET Framework was so huge in itself that instead of developing a new platform for component services for the .NET Framework, Microsoft relies on COM+. The .NET Framework uses COM+ 1.0 for component services on Windows 2000 and uses COM+ 1.5 for Windows XP and Windows Server 2003. In the .NET Framework, the System.EnterpriseServices namespace contains the types that allow you to use COM+ services in the .NET Framework. These types are collectively known as enterprise services. |
- Comment