Skip to main content

Choose an Appropriate Location for Deployment

  • 7 minutes to read

This lesson explains how to choose the best location for deploying your application in a production environment: Windows Forms or ASP.NET Web Forms.

Note

The XAF Blazor server application can also be deployed to non-Windows platforms (Linux, Docker, etc.). See topics from the Deployment - ASP.NET Core Blazor help section for details.

There are two approaches to providing network users with access to a Windows Forms application:

  • Deploy the application to each End-User Workstation.
  • Deploy the application to a Terminal Server.

Each approach has its advantages and disadvantages.

Deploy a Windows Forms Application to Each End-User Workstation

The most common way to deploy a Windows Forms application is to install it on each End-User Workstation. The application files are placed in a folder at each End-User Workstation. For instance, it can be the C:\Program Files\MySolution folder. The following image illustrates the MySolution application installed and running at an End-User Workstation.

Deployment_Tutorial_0001

This approach requires the application to be deployed to each End-User Workstation. If a workstation goes out of order and an end-user has to use another PC, the application must be redeployed. Each workstation must satisfy the hardware requirements and have Microsoft Windows with an appropriate .NET Framework version installed.

Deploy a Windows Forms Application to a Terminal Server

If the end-user network has a Terminal Server, you can install your Windows Forms application on it. For instance, it can be a server running Microsoft Windows Server 2008. The server should have the Terminal Services role installed. The following image illustrates the MySolution application running in a remote desktop session.

Deployment_Tutorial_0002

This method does not require you to deploy the application to each End-User Workstation. End-users can use the application from any workstation. The only two requirements are the capability to run a remote desktop client and network access to the Terminal Server where the application is deployed. Hardware requirements for End-User Workstations are very low - so-called “thin clients” (diskless workstations which boot from the network), inexpensive netbooks or nettops can be used. End-users can use the application remotely via the Internet - just like the ASP.NET Web Forms version of the application. Software requirements are also more liberal - every operating system (OS) which has a remote desktop client can be used - GNU/Linux, MacOS, etc. The following image illustrates the MySolution application running in a remote desktop session launched at a non-Windows workstation.

Deployment_Tutorial_0003

However, there are certain drawbacks associated with this method. First, if the Terminal Server fails, all users will lose access to the application. Second, the Terminal Server hardware requirements are also significant. Additionally, the Terminal Server must have a sufficient number of terminal server client licenses.

Note

It is unsafe to expose the Terminal Server to a public network directly - use Virtual Private Network (VPN) technology to secure remote desktop connections. To reduce network load, the Terminal and Database Servers can be located on the same server.

There are three common approaches of providing end-users with access to an ASP.NET Web Forms application, whether from a local network, or from a remote computer:

  • Deploy the ASP.NET Web Forms application to a local Web Server.
  • Deploy the ASP.NET Web Forms application to remote hosting.
  • Deploy the ASP.NET Web Forms application to a remote dedicated Web Server (whether virtual or physical)

Each method has its advantages and disadvantages.

Deploy an ASP.NET Web Forms Application to a Local Web Server

In the simplest case, only local network end-users are provided with access to the application. In this instance, the application should be deployed to a local Web Server which has Microsoft Internet Services (IIS) installed. The Web Server must have network access to the Database Server, or be located on the same physical server.

You may also be required to provide end-users with access to the Windows Forms and ASP.NET Web Forms versions of the application connected to a single database. In this instance, typically, local end-users use a Windows Forms application and remote users use an ASP.NET Web Forms application. The Web Server must have fast network access to the Database Server, or be located on the same server physically. At the same time, the Web Server should be accessible from the Internet. Network router (firewall) adjustments may be required.

Note

Installing and supporting a secure public web server requires special skills. It is recommended that this be performed by a qualified system administrator.

Deploy an ASP.NET Web Forms Application to Remote Hosting

This method is suitable when all the end-users are going to use the application remotely and the Windows Forms version of the application will not be used. You can choose any Windows hosting which suits your requirements. Ensure that the remote hosting provides sufficient resources for the application.

Deploy an ASP.NET Web Forms Application to a Remote Dedicated Server

This method is similar to the previous one - it is suitable when all the end-users are going to use the application remotely. You will need to rent a dedicated Windows server, whether physical or virtual, which suits your requirements. A dedicated server is a good choice if the application requirements are significant. You will be able to deploy the Windows Forms version of your application to the same server and provide certain end-users with access to it, via Terminal Services.

Note

Installing and supporting a secure public web server requires special skills. It is recommended that this be performed by a qualified system administrator.

Summary

  • end users have no Terminal Server;
  • it is not required to access the Windows Forms Application remotely;
  • end-users work in a homogeneous network - every End-User Workstation has Microsoft Windows installed.
  • end-users have workstations with sufficient performance.
  • end-users have a fast and reliable Terminal Server;
  • it is required to access the Windows Forms Application remotely and ASP.NET Web Forms application capabilities are not sufficient for remote users;
  • end-users work in a heterogeneous network - various platforms are used (Microsoft Windows, GNU/Linux, Apple MacOS, etc.);
  • end-users have low-performance or even diskless workstations (thin clients, netbooks, nettops etc.).
  • the application is not intended for remote users;
  • the application hardware requirements are higher than a hosting can provide;
  • local and remote end users require accessing the Windows Forms and ASP.NET Web Forms versions of the application connected to a single database.
  • the application is intended for remote end-users;
  • the application hardware resources requirements are moderate;
  • the application is intended for remote end-users;
  • the application hardware requirements are higher than hosting can provide;

You can combine the deployment approaches described in this topic. The following diagram illustrates one of the possible scenarios.

Deployment_Tutorial_0000

Here, a Windows Forms application is deployed to the Terminal Server as well as to a group of End-User Workstations. The Terminal Server is accessible from the local network and via Internet. An ASP.NET Web Forms application is deployed to the local Web Server. The Web Server is accessible from the local network and via the Internet. Remote connections are protected by the firewall. The application database is located at the Database Server.

The following step-by-step lessons demonstrate how to deploy an XAF application using different methods. Choose the most suitable method, and apply it.

See Also