Composite Smart Client Applications
A composite smart client application is a client solution that is composed of a number of discrete, independent, yet functional pieces. These pieces are integrated within a host environment to form a fully coherent smart client solution. The composite pattern is a popular and recurring theme because it provides a flexible and scalable architecture with a number of key benefits:
- It allows a higher degree of separation between application infrastructure and business logic.
- It allows more independent development of the individual business logic components themselves.
- It provides solution agility because business logic components can be flexibly combined to quickly yield a specific solution.
- It promotes code re-use because it allows business logic components and the application infrastructure to be re-used across multiple solutions.
- It provides an excellent architecture for the front-end integration of line-of-business or service-oriented systems into a task-oriented user experience.
A composite smart client application consists of functionality from several different sources. These sources include Web services, other applications, or entire systems (often, it interacts with multiple back-end systems). Figure 1 illustrates a composite smart client application that presents an integrated view of multiple services to the user.
A composite smart client application presents the functionality to the user as a single, composite application. The presentation often consists of a rich user interface, such as those shown in Figure 2.
Shell and Modules
A smart client that follows the composite pattern generally involves a shell, which provides the overall user interface structure. Modules contain functionally discrete pieces, but they integrate with the user interface, communicate with the shell, and communicate with each other. The shell provides access to smart client services required by modules throughout the application.
In addition to the overall UI structure, the shell provides key smart client capabilities, such as deployment, update, data caching, and offline support. These are capabilities that all smart client solutions need. This means that the modules can use these built-in capabilities instead of having to implement them themselves. This allows a solution to be developed much more quickly because the smart client infrastructure is already in place—the modules can focus on the business logic and their piece of the overall solution, instead of focusing on the basic foundation required to provide the necessary smart client capabilities.
This pattern provides a number of advantages in terms of a separation of roles between the developers of the modules and the solution designer/builder. Module developers are typically focused on implementing the business logic required to provide specific business focused functionality (for example, providing access to the inventory, CRM, ERP, and HR systems). The solution designers are able to define a solution to a business problem at a higher and more broadly focused level of abstraction (for example, providing a call center solution, a bank teller solution, or a document collaboration solution).
An architecture that follows the composite pattern fits extremely well into a service-oriented architecture. Very often, an organization will define their Web service granularity based on business functions (which, in turn, is typically how the IT infrastructure itself is structured). This means that there will be a family of Web services for the ERP system, the CRM system, the inventory system, and so on. This is a natural way for a service-oriented architecture to be developed and to evolve. Solutions are then built on top of these services, or on composites of these services, eventually forming composite solutions. Typically, each service needs the client to have a certain amount of knowledge so that the service can be used properly; for example, so that the client can gather the right security credentials, perform appropriate data caching, handle the semantics of dealing with the service in terms of tentative and cancelable operations, and so on. Typically, the client-side piece of logic that handles these issues for a service is known as a service agent.
|Of course, not all services will be integrated and coordinated on the client (for transactional reasons, availability reasons, and reliability reasons). However, services that cannot be coordinated on the client, can be placed behind a façade service that coordinates these services on behalf of the client (for example, by using a server-side orchestration engine such as BizTalk) service agents. In this way, the composite client continues to present an integrated view of the disparate services.|
There is a natural correspondence between the service agents and the modules that comprise a composite smart client solution. With this architecture, developers of the business capabilities, and the Web services that expose them, can develop the user interface and client-side logic to take maximum advantage of those services. This means that in addition to a menu of business capabilities and Web services, you can also have a menu of client-side service agents that allow you to quickly and easily construct a composite client solution.
With smart client technology, users can work with data even when they are not connected to the Internet or the network that hosts the Web service. Because all or part of the application logic sits on the local computer, smart clients can deliver useful functionality even while offline. This capability sets smart clients apart from browser-based applications, and for many mobile sales forces or remote offices, this is a key requirement.
Updates and Deployment
Because the modules that comprise the client-side solution are loosely coupled (that is, there is no hard dependency between them because the shell provides a standard but simple mechanism for them to interact with each other), these modules can be independently updated, developed, and deployed. This extends the benefits of loose coupling to the client.
Like a browser-based application, smart client software can be deployed from a centralized Web server. (Smart clients can also be deployed by CD, DVD, floppy disk, or by using an application deployment infrastructure, such as Microsoft Systems Management Server.)
After smart client applications are deployed, they can automatically update themselves to the latest version of software that resides on the centralized server. This simplified deployment helps to ensure that users have the latest version of the application and also helps IT departments reduce deployment complexity and costs.