Dr. Dobb's is part of the Informa Tech Division of Informa PLC

This site is operated by a business or businesses owned by Informa PLC and all copyright resides with them. Informa PLC's registered office is 5 Howick Place, London SW1P 1WG. Registered in England and Wales. Number 8860726.


Channels ▼
RSS

Application Deployment in ASP.NET 2.0



Application Deployment in ASP.NET 2.0

FTP? MSI? Copy Web Site? Wherever you deploy, there you are

The deployment of a web application is a task that can be accomplished in various ways depending on the context. As far as copy is concerned, you can use any of the following: FTP transfer, any server management tools providing forms of smart replication on a remote site, or an MSI installer application. In Visual Studio .NET 2005, you can even use the newest and loudly requested “Copy Web Site” function.

Each option has pros and cons, and the best fit can only be found once you know exactly the runtime host scenario and the purpose of the application is clearly delineated. Be aware that if you’re going to deploy the application on an ISP host, you might be forced to play by the rules (read, use the tools) that your host has set. If you’re going to deliver a front-end for an existing system to a variety of servers, you might perhaps find a setup project easier to create. On the other hand, FTP is great for general maintenance and for applying quick fixes. Ad hoc tools, instead, could give you automatic sync-up features. Guess what? Choosing the right technique is strictly application specific and is ultimately left to you.

FTP gives you much freedom and lets you modify and replace individual files. It doesn’t represent a solution that is automatic in nature, however: Whatever you need to do must be accomplished manually. Assuming that you have gained full access to the remote site, using FTP is not much different than using Windows Explorer in the local network.

Another common scenario involves using an out-of-the-box installer file. Deploying a web application this way is a two-step operation. First, you create and configure the virtual directory; next, you copy the needed files. Visual Studio .NET makes creating a Web setup application a snap. You just create a new type of project—Web Setup Project—select the files to copy, and build the project. What you get out of it is a brand new MSI installer file.

The new “Copy Web Site” function also provides synchronization capabilities. It is not like the set of features that a specifically designed server management tool would supply, but it can certainly work well through a number of realistic situations. At the end of the day, a site replication tool doesn’t do much more than merely transferring files from end to end. Its pluses are the user interface and the intelligence built around and atop this basic capability. So a replication tool maintains a database of files with timestamps, attributes, and properties and can sync up versions of the site in a rather automated way, minimizing the work on your end.

The Copy Web Site function is a sort of integrated FTP tool that enables you to easily move files around. You connect to the target destination, select the desired copy mode—overwrite source to target files, target to source files, sync up source and target projects—and then proceed with the physical files copy. The Copy Web Site function is ideal for deployment especially in hosting-environment scenarios when you need to manage live server files. In addition, the tool can operate as a synchronization mechanism, which is helpful to quickly test applications in different scenarios and configurations.


Dino Esposito is Wintellect's ADO.NET and XML expert, and a trainer and consultant based in Rome, Italy. Dino is a contributing editor to Windows Developer Network and MSDN Magazine, and the author of several books for Microsoft Press including Building Web Solutions with ASP.NET and ADO.NET and Applied XML Programming for .NET. Contact Dino at [email protected].



Related Reading


More Insights






Currently we allow the following HTML tags in comments:

Single tags

These tags can be used alone and don't need an ending tag.

<br> Defines a single line break

<hr> Defines a horizontal line

Matching tags

These require an ending tag - e.g. <i>italic text</i>

<a> Defines an anchor

<b> Defines bold text

<big> Defines big text

<blockquote> Defines a long quotation

<caption> Defines a table caption

<cite> Defines a citation

<code> Defines computer code text

<em> Defines emphasized text

<fieldset> Defines a border around elements in a form

<h1> This is heading 1

<h2> This is heading 2

<h3> This is heading 3

<h4> This is heading 4

<h5> This is heading 5

<h6> This is heading 6

<i> Defines italic text

<p> Defines a paragraph

<pre> Defines preformatted text

<q> Defines a short quotation

<samp> Defines sample computer code text

<small> Defines small text

<span> Defines a section in a document

<s> Defines strikethrough text

<strike> Defines strikethrough text

<strong> Defines strong text

<sub> Defines subscripted text

<sup> Defines superscripted text

<u> Defines underlined text

Dr. Dobb's encourages readers to engage in spirited, healthy debate, including taking us to task. However, Dr. Dobb's moderates all comments posted to our site, and reserves the right to modify or remove any content that it determines to be derogatory, offensive, inflammatory, vulgar, irrelevant/off-topic, racist or obvious marketing or spam. Dr. Dobb's further reserves the right to disable the profile of any commenter participating in said activities.

 
Disqus Tips To upload an avatar photo, first complete your Disqus profile. | View the list of supported HTML tags you can use to style comments. | Please read our commenting policy.