In Phase 3, we break out the business logic layer to create a logical three-tier application. (Phase 3.5 implements a physical three-tier architecture, distributing the components with Microsoft Transaction Server.) The fictional Duwamish Books chain is preparing for further growth. It needs to revise its store system to be more scalable and support rapid changes in business rules. The best way to do this is move to a more component-based system and move the database to SQL Server.
As in Phases 1 and 2, we provide both the compiled application and the source code. To download these, go to the Phase 3 download page.
In order to compile Phase 3, you'll need Visual Studio 6.0.
For an introduction to the migration scenario and an overview of tiered architectures, see "An Introduction to the Duwamish Books Sample."
In "Abstracting Business Transactions," Steve Kirk explains how the developers designed the COM component that contains the business logic. The article discusses the business logic layer semantics and transaction model. It also talks about problems that Steve encountered during development, and the workarounds that he used. Steve also assembled the API reference for the component.
We've also provided a Visual C++ version of the Business Logic Layer. Michael Zonczyk' explains the development of this version of the component in "Implementing the Duwamish Books Business Logic Layer in Visual C++."
For the mechanics of separating the business logic code from the client code, read Dale Smith's article on "Breaking out the Business Logic."
The developers also upgraded the data access component created in Phase 3, making it more scalable by preventing caching and adding statelessness. Why and how did they do this? Read Robert Coleridge's article on "Duwamish Data Access Layer Shifts into Phase 3."
Finally, read how Steve Kirk upsized the original Duwamish Books Access database in "Migrating the Duwamish Books Database to SQL Server."