pending updates

Topics: Updater Application Block
Apr 28, 2005 at 11:53 PM
originally posted by: Andrw

what should happen after invocation of ResumePendingUpdates() in a PendingUpdatesDetected event handler? It seems to me that nothing happens, at least DownloadProgres, DwonloadStarted events are never fired after this invocation.

But if I try to download updates from scratch - all seems to be all right.
Apr 29, 2005 at 2:46 AM
originally posted by: AnuragRastogi

hi,

let me tell you the complete understanding for handling the pending updates , so that you can have the clear idea about what should happened after invocation of ResumePendingUpdates() -

1. The PendingUpdatesDetected event contains a
PendingUpdatesDetectedEventArgs parameter. This
parameter is an array of pending Manifests corresponding to
UpdaterTasks. You can use the information in this parameter
to decide what action to take. The ApplicationUpdaterManager
provides two relevant methods to handle the
PendingUpdatesDetected event;

2. ResumePendingUpdates resumes the updates according to
their state, and CancelPendingUpdates removes the updates
from the task registry.
Apr 29, 2005 at 5:22 AM
originally posted by: Andrw

I haven't got a clear idea yet :)

My question is - why nothing happens after ResumePendingUpdates. I invoke ResumePendingUpdates in the PendingUpdatesDetected event handler and DwonloadProgress isn't fires.
May 6, 2005 at 12:39 AM
originally posted by: AnuragRastogi

hi ,

check whether PendingUpdatesDetected in OnPendingUpdatesDetected is not null . if it is then logic for completing the pending updates will not be invoked but in that case it will remove the pending task entry from registry and start the task from the scratch again.
May 6, 2005 at 11:31 AM
originally posted by: Andrw

The fact is ResumePendingUpdates is not an asynchronious method. And App. Updater doesn't provide an async one (I can't figure out why we have a BeginDownload method and haven't such one for resuming pending tasks). So, to avoid user interface sleeping during this action I ran it in a separate thread. The siginficant difference between an async method and a simple one - when we submit tasks with the simple one, DownloadProgress and other related events aren't fired.

I have to make some corrections to Updater source code.