Updating a Deployed Application

This topic describes how to update an application after it has been deployed to production. To do so, perform the following actions:

Stop the application to be updated

Before updating a running application, stop all incoming messages to the application. Do so on a stand-alone server by selecting the application in IIS Manager and clicking the Stop Application command, or using the Stop-ASApplication cmdlet.

If you are simultaneously updating all computers in a farm, and an incompatible version change has been applied to an application deployed in the farm, you must execute the Stop Application command on all computers in the farm together. With shared configuration, this would automatically be taken care of. With distributed configuration, you must connect IIS Manager to all machines and issue the Stop Application command, or execute the Stop-ASApplication cmdlet on all machines in parallel.

You can perform rolling updates to an application in a farm only if the changes are compatible and if the farm uses distributed configuration. Based on the type of network load balancing that is used, you may need to remove the computer before stopping the application.

Allow running instances to complete

All long-running durable instances are updatable at any time, because an update will recycle the application domain where the instances are running, and instances will pick up new settings after they resume with a message resend or instance restart.

You may want to allow the running instances to complete the current commands that they are executing. If all instances are in either the Blocked or Suspended state, no instances are in memory.

Back up the current application and state

It is recommended that you back up the code and date of an application in the case of an upgrade on a single computer or a simultaneous update to a farm. You should also back up all the content and configuration of the application to be updated in case the update fails and needs to be reverted. You can do so using MSDeploy.

Deploy the updated application and enabling client access

After deploying the updated application, you must enable client access on a standalone computer by using the Start Application command or the Start-ASApplication cmdlet. In the case of a simultaneous update of all computers in a farm, you can start the application on a shared configuration farm or with a parallel execution of the command on all computers in the farm. In the case of rolling updates, you can bring a computer back into the rotation after updating by configuring the network load balancing.

Finally, you should use a test client to ensure that the service runs properly.

  2012-09-12