|
|
0f5e1f |
--- rt.equinox.p2/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/SimpleProfileRegistry.java.orig 2014-03-24 10:49:00.000000000 +0000
|
|
|
0f5e1f |
+++ rt.equinox.p2/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/SimpleProfileRegistry.java 2014-03-24 15:39:32.122246214 +0000
|
|
|
0f5e1f |
@@ -44,6 +44,7 @@
|
|
|
0f5e1f |
|
|
|
0f5e1f |
public class SimpleProfileRegistry implements IProfileRegistry, IAgentService {
|
|
|
0f5e1f |
|
|
|
0f5e1f |
+ private static final String PROP_IGNORE_USER_CONFIGURATION = "eclipse.ignoreUserConfiguration"; //$NON-NLS-1$
|
|
|
0f5e1f |
private static final String SIMPLE_PROFILE_REGISTRY_INTERNAL = "_simpleProfileRegistry_internal_"; //$NON-NLS-1$
|
|
|
0f5e1f |
private static final String PROFILE_REGISTRY = "profile registry"; //$NON-NLS-1$
|
|
|
0f5e1f |
private static final String PROFILE_PROPERTIES_FILE = "state.properties"; //$NON-NLS-1$
|
|
|
0f5e1f |
@@ -274,6 +275,14 @@
|
|
|
0f5e1f |
//fragments support - remeber the property
|
|
|
0f5e1f |
internalSetProfileStateProperty(profile, profile.getTimestamp(), SIMPLE_PROFILE_REGISTRY_INTERNAL + getExtTimeStamp(), getExtTimeStamp());
|
|
|
0f5e1f |
agent.registerService(SERVICE_SHARED_INSTALL_NEW_TIMESTAMP, Long.toString(profile.getTimestamp()));
|
|
|
0f5e1f |
+
|
|
|
0f5e1f |
+ // this looks like a hack, but:
|
|
|
0f5e1f |
+ // (1) SimpleConfigurationImpl keeps returning master configuration as long as the property is set
|
|
|
0f5e1f |
+ // (2) SimpleConfigurationImpl sets the propery after it drops user configuration
|
|
|
0f5e1f |
+ // therefore dropins reconciliation can't load dropins plugins installed into user configuration
|
|
|
0f5e1f |
+ // after the user configuration has been dropped.
|
|
|
0f5e1f |
+ // It is necessary to unset this property.
|
|
|
0f5e1f |
+ //System.setProperty(PROP_IGNORE_USER_CONFIGURATION, "processed_and_unset"); //$NON-NLS-1$ //$NON-NLS-2$
|
|
|
0f5e1f |
} else {
|
|
|
0f5e1f |
//This is the first time we create the shared profile. Tag it as such and also remember the timestamp of the base
|
|
|
0f5e1f |
internalSetProfileStateProperty(profile, profile.getTimestamp(), IProfile.STATE_PROP_SHARED_INSTALL, IProfile.STATE_SHARED_INSTALL_VALUE_INITIAL);
|
|
|
0f5e1f |
@@ -307,6 +316,13 @@
|
|
|
0f5e1f |
if (agent.getService(SERVICE_SHARED_INSTALL_NEW_TIMESTAMP) != null)
|
|
|
0f5e1f |
return false;
|
|
|
0f5e1f |
|
|
|
0f5e1f |
+ // if the property is set by OSGI, and there is no new timestamp (because of the previous condition)
|
|
|
0f5e1f |
+ // ignore current profile. This will happen only once, because SERVICE_SHARED_INSTALL_NEW_TIMESTAMP
|
|
|
0f5e1f |
+ // is set during profile reset.
|
|
|
0f5e1f |
+ if ("true".equals(System.getProperty(PROP_IGNORE_USER_CONFIGURATION))) { //$NON-NLS-1$ //$NON-NLS-2$
|
|
|
0f5e1f |
+ System.setProperty(PROP_IGNORE_USER_CONFIGURATION, "processed_and_unset"); //$NON-NLS-1$ //$NON-NLS-2$
|
|
|
0f5e1f |
+ return true;
|
|
|
0f5e1f |
+ }
|
|
|
0f5e1f |
String baseTimestamp = getBaseTimestamp(profile.getProfileId());
|
|
|
0f5e1f |
String extTimestamp = getExtTimeStamp();
|
|
|
0f5e1f |
if (baseTimestamp == null) {
|
|
|
0f5e1f |
--- rt.equinox.p2/bundles/org.eclipse.equinox.p2.reconciler.dropins/src/org/eclipse/equinox/internal/p2/reconciler/dropins/ProfileSynchronizer.java.orig 2019-09-13 14:45:20.806922186 +0100
|
|
|
0f5e1f |
+++ rt.equinox.p2/bundles/org.eclipse.equinox.p2.reconciler.dropins/src/org/eclipse/equinox/internal/p2/reconciler/dropins/ProfileSynchronizer.java 2019-09-13 14:46:41.124689025 +0100
|
|
|
0f5e1f |
@@ -560,6 +560,7 @@
|
|
|
0f5e1f |
|
|
|
0f5e1f |
// get all IUs from all our repos
|
|
|
0f5e1f |
IQueryResult<IInstallableUnit> allIUs = getAllIUsFromRepos();
|
|
|
0f5e1f |
+ HashSet<IInstallableUnit> removedFromAllIUs = new HashSet<IInstallableUnit>();
|
|
|
0f5e1f |
for (Iterator<IInstallableUnit> iter = allIUs.iterator(); iter.hasNext();) {
|
|
|
0f5e1f |
final IInstallableUnit iu = iter.next();
|
|
|
0f5e1f |
IInstallableUnit existing = profileIUs.get(iu);
|
|
|
0f5e1f |
@@ -573,6 +574,7 @@
|
|
|
0f5e1f |
// (and more expensive) way to find this out is to do an IU profile property query.
|
|
|
0f5e1f |
if (two == null) {
|
|
|
0f5e1f |
// the IU is already installed so don't mark it as a dropin now - see bug 404619.
|
|
|
0f5e1f |
+ removedFromAllIUs.add(iu);
|
|
|
0f5e1f |
iter.remove();
|
|
|
0f5e1f |
continue;
|
|
|
0f5e1f |
}
|
|
|
0f5e1f |
@@ -614,7 +616,7 @@
|
|
|
0f5e1f |
}
|
|
|
0f5e1f |
// if the IU from the profile is in the "all available" list, then it is already added
|
|
|
0f5e1f |
// otherwise if it isn't in the repo then we have to remove it from the profile.
|
|
|
0f5e1f |
- if (!all.contains(iu))
|
|
|
0f5e1f |
+ if (!all.contains(iu) && !removedFromAllIUs.contains(iu))
|
|
|
0f5e1f |
toRemove.add(iu);
|
|
|
0f5e1f |
}
|
|
|
0f5e1f |
|
|
|
0f5e1f |
@@ -787,7 +789,8 @@
|
|
|
0f5e1f |
if (!installerPlanStatus.isOK())
|
|
|
0f5e1f |
return installerPlanStatus;
|
|
|
0f5e1f |
|
|
|
0f5e1f |
- applyConfiguration(true);
|
|
|
0f5e1f |
+ if (isReconciliationApplicationRunning())
|
|
|
0f5e1f |
+ applyConfiguration(true);
|
|
|
0f5e1f |
}
|
|
|
0f5e1f |
return engine.perform(plan, phaseSet, monitor);
|
|
|
0f5e1f |
}
|
|
|
0f5e1f |
--- rt.equinox.p2/bundles/org.eclipse.equinox.p2.ui.sdk.scheduler/src/org/eclipse/equinox/internal/p2/ui/sdk/scheduler/migration/MigrationWizard.java.orig 2019-09-13 14:42:54.512346840 +0100
|
|
|
0f5e1f |
+++ rt.equinox.p2/bundles/org.eclipse.equinox.p2.ui.sdk.scheduler/src/org/eclipse/equinox/internal/p2/ui/sdk/scheduler/migration/MigrationWizard.java 2019-09-13 14:43:12.003296065 +0100
|
|
|
0f5e1f |
@@ -158,8 +158,7 @@
|
|
|
0f5e1f |
|
|
|
0f5e1f |
@Override
|
|
|
0f5e1f |
public boolean performCancel() {
|
|
|
0f5e1f |
- String[] buttons = new String[] { IDialogConstants.YES_LABEL, ProvUIMessages.MigrationPage_LATER_BUTTON,
|
|
|
0f5e1f |
- IDialogConstants.NO_LABEL };
|
|
|
0f5e1f |
+ String[] buttons = new String[] { IDialogConstants.YES_LABEL, IDialogConstants.NO_LABEL };
|
|
|
0f5e1f |
MessageDialog dialog = new MessageDialog(getShell(), ProvUIMessages.MigrationPage_CONFIRMATION_TITLE, null,
|
|
|
0f5e1f |
ProvUIMessages.MigrationPage_CONFIRMATION_DIALOG, MessageDialog.QUESTION, buttons, 2);
|
|
|
0f5e1f |
|