Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

How to: Apply Updates at a Future Time

Retired Content

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies.
This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

ClickOnce always applies an update the next time an application is launched after the update is downloaded. The download can be automatically triggered when launching the application if using ClickOnce automatic updating, or it can be done by your own code if using the on-demand API. It is difficult to determine when the update is actually available and applied on any particular client computer because it is affected by when the application runs, how big the update is, how busy the server is, and the amount of bandwidth that is available to download the update.

As a result, there may be times when you want to get the update "staged" to the client computer ahead of time and then control when the application starts using it to apply the update at a future time. For example, if you have a large update that you need to roll out to users, you need to make sure that all users start using the new version of the application at the same time when they arrive at work on a particular day and start the application. However, you do not want them to have to wait for a long time to start because everyone is trying to download the update at the same time (using the default update policy for ClickOnce).

If the updates that you are applying are new Composite UI Application Block modules, you can address this scenario through a combination of ClickOnce updating and by using the ProfileCatalogService Web service to determine when the deployed updates are actually put into use.

You could publish an update to the deployment server when the updated files become available. You would then wait a sufficient amount of time to ensure that all or most users have had a chance to download the application. If the usage pattern for your application is that users start the application at the start of the workday and leave it running all day, you would have to wait at least one day for the update to be downloaded and applied through ClickOnce. You would then add the new modules to the list of modules in the profile catalog the night before putting the new modules in operations. When the users start their application the next day, the application files will have already been staged to their computers through ClickOnce and will be loaded with no delay on startup after the call to the ProfileCatalogService has been made to determine what modules to load.

The basic approach to support this scenario consists of the following:

  • Publish the updated version that contains the new modules.
  • Allow clients to download the updates based on ClickOnce updates.
  • Have the updates automatically applied on the client computer side the next time the application starts for physically staging the files.
  • Have the client application wait to start using the new modules by not adding them to the profile catalog until sufficient time has elapsed for all users to get the updates.

For detailed information about how to use this approach, see Manual: Apply Updates at a Future Time.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
© 2014 Microsoft. All rights reserved.