GuidesSmart Clients - A Practitioner's Point of View

Smart Clients – A Practitioner’s Point of View content and product recommendations are editorially independent. We may make money when you click on links to our partners. Learn More.

Smart Client is the concept of architecting your application solution into a smart, flexible and convenient platform that utilizes web services for communication. This is accomplished in part by making a constant effort to separate an application into distinct, stand-alone components (tiers). This ideology is what separates Smart Clients from traditional client/server and web applications. Client/server solutions have been notorious for their problems with deployment and installation. These problems are a large reason why many companies decided to build web applications. This provided little or no necessary deployment to clients and made the application available on a simple web browser. Smart Clients is an evolution of these solutions that focuses on making an application extendable to any front-end environment that supports web services.

However, Smart Client technology is not the silver bullet for today’s application solutions that might be portrayed by some industry leaders. This concept is not right for every application. It is also not a pre-built set of plug-ins or templates that simply transform a system into a Smart Client.

What is a Smart Client?

A Smart Client is an application that uses local processing, consumes XML Web Services and can be deployed and updated from a centralized server. Many equate Smart Client to a set of Microsoft .NET technologies. While the .NET Framework (Windows Forms) and the .NET Compact Framework provide the ability to develop Smart Clients with ease, other technologies can provide smart client applications by utilizing the same architecture.

Advantages & Disadvantages of Smart Clients

There are two major factors to consider when determining whether a Smart Client application is the proper approach to take.

  1. Will users’ platforms vary or are they expected to change in the future?
  2. Does the functionality need to be accessible from any location, regardless of platform? In other words, is the functionality truly “public” in nature?

If the answer to either of these questions is yes, then a more conventional web application is probably a better suited solution. Otherwise, implementing a Smart Client application might be the way to go. There are many advantages to this approach as opposed to typical client/server or web applications.

  • Separating out core functionalities into their proper tiers generally will result in a well developed and architected code base that is easier to maintain and extend.
  • The application is available to any GUI that supports web services. Developers are instantly enabled with the power to write front-end applications for various devices in countless languages.
  • Limitations encountered with web application GUI environments are eliminated. Clients typically want and need more rich tools to interact with the application in a productive manner. Smart Clients are the answer.
  • If a proper architecture is used, Smart Client applications will make working in a disconnected state possible. The data store would need to be made locally when in a disconnected state. There are generally two options for working disconnected. If it is feasible, the business services components can be deployed with the client application. This will allow for a fairly seamless synchronization of data when connected. Another option would be creating a truly “dumb” presentation tier that essentially performs little or no business logic or verification on data entry. This data will then be “cleansed” when synchronization occurs.
  • If the application is built using .NET, the deployment and installation is made easier. The application will be built with self-contained assemblies. These assemblies can be installed side-by-side without conflicts. The deployment of these assemblies is accomplished with XCOPY deployment. This removes a lot of headaches that exist with applications in the past.

Tiered Technology

Almost every application is composed of three general elements: data, rules for the application to manipulate that data, and some way for the users to manipulate the data. These elements are generally thought of as separate tiers; hence the tem “multi-tiered” application. This next section describes the major tiers (we call them services) of a Smart client application and how they stack up against traditional client/server and browser-based applications

Data Storage Services

Almost every application built today requires data. Databases are used to store and organize this data so that it can be persisted over time. Today, most databases are relational. This includes databases ranging from MySQL, FoxPro, and Paradox to Oracle and SQL Server.

When comparing a Smart Client application to a client/server or web application, the database structure (the table design) will not be any different. However, differences will exist in the way that data is accessed. One of the things that make a Smart Client application “smart” is its ability to work in disconnected state. When one designs a client/server application, a common assumption is that there will always be a connection to the database and the same is true for web-based applications.

When designing your data services, you will have to think about how your application will initially get data, how to sense if the connection is lost, how to access data on the local client, and finally synchronization strategies when a lost connection is re-established.

Business Services

The most glaring difference between Smart Client applications and other types can be found in the Business Services. A Smart Client will use web services to provide the core business logic to the rest of the application. The reasons for using web services include:

  • Ability to access Business Services anywhere one can get an Internet connection.
  • Web services are truly platform independent pieces of code so that clients of varying technologies can access the same Business Service (as opposed to COM+ or CORBA based applications).

When comparing to both client/server and web-based applications a fair number of implementations integrate the business rules directly into the user interface. This may not be viable for smart clients because they must be able to work in a disconnected fashion. As a practical matter, user interface elements should provide basic validation (presence of required values, etc.) but not much more. To truly leverage the smart client architecture your core business logic should be centralized into the application’s web services. This also serves to reduce the amount of code on the client for it to function in a disconnected state.

Presentation Services

Users need a way to manipulate an application’s data and that where the presentation services come into play. Smart Client applications may (more times than not) have more than one method of communicating with Business Services.

Currently, the most common Presentation Service implementations are rich-client and browser-based. However, PDA’s and web-enabled phones and making strides in becoming a viable interface. Typical client/server and web-based applications have only one presentation services implementation, which limits the users in terms of flexibility and mobility.

To Wrap Up

Smart Client is certainly a better solution than many others being implemented today and should be considered in almost all new application projects. It breaks through many boundaries that have been unleashed with web applications. It provides much improved functionality when dealing with deployment and installation as well as working disconnected that have not been easy to accomplish in the past. All this is made possible by taking great care in construction your solution and by utilizing the future of computing, web services.

About the Authors

Jonathon Walsh has 10 years of experience focusing on enterprise architecture and development. He has been a contributing author for two books about the .NET development and currently works as a consultant for Quest Information Systems, Inc.

Joe Misner is a Senior Developer at Quest Information Systems. He has had vast experience with Internet and Desktop Application Development in the commercial and government sectors. His primary focus has been with Microsoft .NET technology solutions where he has achieved an MCSD.NET certification. He was a 2003 Million Dollar Award recipient as a Key Technical Contributor for his role in a major government application solution.

# # #

Get the Free Newsletter!

Subscribe to Developer Insider for top news, trends & analysis

Latest Posts

Related Stories