1
votes

I have a custom Bootstrapper, I am trying to upgrade my Bundle by just change the Version( all the MSI's version remain the same, which is not an Ideal scenario). Both the Bundles have same Upgrade code( which they should have).

Once the Upgrade is done, the old bundle is quietly uninstallation since it will be called with the argument /quit after installing the new one, but once the Un-install of the Old Bundle is completed, the process still remains and doesn't kill itself. Because of it my current state of the Custom Bootstrapper doesn't change.

Question: Can anyone please let me know what can be done here, in order to kill the old bundle process, so that the current bundle moves forward with it upgrade without getting stuck?

1

1 Answers

0
votes

I guess I have figured out the problem, as an additional process is created by the burn engine when a upgrade happens in order to delete the older bundle entry, so in order to return to the main thread after the uninstall had happened, I had done the below change in ApplyComplete event in my CustomBA.

if (CustomBootstrapperApplication.Model.PlannedAction == LaunchAction.Uninstall && isRelatedBundlePresent) // this will be called in case of Upgrade of the bundle
{
    CustomBootstrapperApplication.Dispatcher.InvokeShutdown();                 
}

isRelatedBundlePresent is a flag which I am setting in the DetectRelatedBundle when RelationType.Upgrade