Composite Web Application Block
Many line-of-business Web sites consist of different systems built by collaborating teams that provide rich user experiences. The Web Client Software Factory helps architects and developers create such composite Web applications. A composite Web application is composed of a number of discrete, independent, yet functionally complete, pieces. These pieces are integrated together within a Web site.
Not all Web applications are composite, and developers successfully use Visual Studio to create Web applications today. The Web Client Software Factory optimizes the development of composite applications. The Composite Web Application Block included in the Web Client Software Factory implements proven design patterns to help you build composite Web applications.
The Web Client Software Factory is designed to address requests from architects and developers who create Web client applications and need to accomplish the following:
- Build clients composed of independent, yet cooperating, modules.
- Separate the concerns of module builders from the concerns of the Web site developer, allowing business units to concentrate on development of domain-specific modules instead of the Web architecture.
- Use an architectural framework for producing a consistent and high quality integrated development.
- Increase productivity and reduce overall development time through consolidating architect and developer efforts.
Because the Composite Web Application Block is designed to address these application needs, the applications you create with the Web Client Software Factory use the Composite Web Application Block. To fully understand the guidance in the Web Client Software Factory, you must be familiar with this application block.
The Composite Web Application Block is designed to help architects and developers achieve the following objectives:
- Decompose a complex Web site into independent visual and non-visual parts that can be built, assembled, and deployed by independent teams.
- Minimize cross-team dependencies that allows team specialization for areas such as UI design, business logic implementation (business logic development may occur across multiple teams), and infrastructure code development.
- Utilize an architecture that promotes reusability across independent teams.
- Increase the quality of applications by abstracting common services that are available for the independent teams to use.
- Promote proven practices for security without requiring everyone to be a security expert.
- Incrementally deploy new capabilities while minimizing downtime.
- Maximize the coverage of automated tests in the code base.
The following sections describe how the Composite Web Application Block benefits both architects and developers.
Separation of Concerns
Developers can use the Composite Web Application Block to develop Web applications composed of independent, but collaborating, modules. Productivity increases because each developer (or team) is able to concentrate on a specific task. For example, developers of service components work with only the business logic in the component; they do not have to be concerned with background issues, such as security or the appearance and behavior of the application.
Applications built with the Composite Web Application Block have a design that delineates the difference between writing common UI elements, such as menu items or toolbars, infrastructure components, such as logging, exception handling, authentication, or authorization (built only once per application or re-used from other applications), and business logic, such as the user interfaces, logic, entities, and service agents of the specific application. This means that the application architecture supports developers and teams that have different concerns during the creation of an application. Figure 1 illustrates an example of a Web application built using the Composite Web Application Block that supports concerns of different teams and individuals with different expertise within a team.
Separation of concerns with a Composite Web Application Block application
The Composite Web Application Block promotes modularity by allowing you to implement business logic, visual components, infrastructure components, presenter or controller components, and any other objects the application requires, in separate modules. Developers can easily create visual parts and implement business logic independently of each other and of the Web site. The Composite Web Application Block design separates the concerns of the following developers participating in a Web solution:
- Web site and common UI elements developers who are responsible for implementing the Web site user interface design and theme
- Business logic developers who are responsible for implementing use case logic
- Infrastructure developers who are responsible for providing common services such as logging, security, and so on
The following are examples of modules:
- A module that contains a specific application feature area such as reports
- A module that contains use cases around a specific back-end system such as loan processing
- A module that contains infrastructure services such as logging and authorization services
The Composite Web Application Block provides the foundation for building Web application; its design promotes extensibility in many different ways. With it, you can do the following:
- Replace the behaviors and strategies provided as defaults (such as the way in which modules are loaded and the way that state is saved) with your own implementations.
- Add custom services and behaviors as required by your applications.