public Version CheckUpdateInManifest(SubscriptionState subState, Uri updateCodebaseUri, AssemblyManifest deployment, Version currentVersion, ref bool bUpdateInPKTGroup) { SubscriptionStore.CheckOnlineShellVisibleConflict(subState, deployment); SubscriptionStore.CheckInstalledAndUpdateableConflict(subState, deployment); SubscriptionStore.CheckMinimumRequiredVersion(subState, deployment); SubscriptionState subscriptionState = this.GetSubscriptionState(deployment); if (!subscriptionState.SubscriptionId.Equals((object)subState.SubscriptionId)) { Logger.AddInternalState("Cross family update detected. Check if only PKT has changed between versions."); Logger.AddInternalState("updateCodebaseUri=" + (object)updateCodebaseUri + ", subState.DeploymentProviderUri=" + (object)subState.DeploymentProviderUri); Logger.AddInternalState("subState=" + (object)subState.SubscriptionId + ", manSubState.SubscriptionId=" + (object)subscriptionState.SubscriptionId); if (!updateCodebaseUri.Equals((object)subState.DeploymentProviderUri) || !subState.PKTGroupId.Equals((object)subscriptionState.PKTGroupId)) { throw new DeploymentException(ExceptionTypes.SubscriptionState, Resources.GetString("Ex_DeploymentIdentityNotInSubscription")); } Logger.AddInternalState("PKT has changed."); bUpdateInPKTGroup = true; } Version version = deployment.Identity.Version; if (version.CompareTo(currentVersion) == 0) { return((Version)null); } return(version); }
public void CheckDeploymentSubscriptionState(SubscriptionState subState, AssemblyManifest deployment) { if (!subState.IsInstalled) { return; } SubscriptionStore.CheckOnlineShellVisibleConflict(subState, deployment); SubscriptionStore.CheckInstalledAndUpdateableConflict(subState, deployment); SubscriptionStore.CheckMinimumRequiredVersion(subState, deployment); }