Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Oberlies2012-09-28 13:41:24 -0400
committerTobias Oberlies2012-09-28 14:03:32 -0400
commit1c6723a02e376f32c75daada80b9acc46bd1cd01 (patch)
treedade709ca1cdbbbf80d688be3e322d72e67673aa /bundles/org.eclipse.equinox.p2.artifact.repository
parentd3f8376c143849bf553164fe053febd5cd602fbf (diff)
downloadrt.equinox.p2-1c6723a02e376f32c75daada80b9acc46bd1cd01.tar.gz
rt.equinox.p2-1c6723a02e376f32c75daada80b9acc46bd1cd01.tar.xz
rt.equinox.p2-1c6723a02e376f32c75daada80b9acc46bd1cd01.zip
356561 Require that all children of a composite repository can be loadedv20120928-180332
- Loading a composite repository now fails if any of its children cannot be loaded. So in case of transient network problems, a p2 operation now fails fast, instead of generating obscure (and possibly severe, yet unnoticed) follow-up problems. - p2 repository providers who rely on the old, lenient behaviour may re-enable it by adding the property 'p2.atomic.composite.loading' with value 'false' in their compositeContent.xml/ compositeArtifact.xml. - p2 clients who need to communicate with broken composite repositories which are out of maintenance can revert to the old behaviour by setting the system property eclipse.p2.atomic.composite.loading.default=false. Bug: 356561 Composite Repositories have non-deterministic content by default
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.artifact.repository')
-rw-r--r--bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/repository/CompositeArtifactRepository.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/repository/CompositeArtifactRepository.java b/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/repository/CompositeArtifactRepository.java
index c1cddeeeb..4a126c046 100644
--- a/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/repository/CompositeArtifactRepository.java
+++ b/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/repository/CompositeArtifactRepository.java
@@ -39,7 +39,9 @@ public class CompositeArtifactRepository extends AbstractArtifactRepository impl
static final public String CONTENT_FILENAME = "compositeArtifacts"; //$NON-NLS-1$
public static final String PI_REPOSITORY_TYPE = "compositeArtifactRepository"; //$NON-NLS-1$
static final public String PROP_ATOMIC_LOADING = "p2.atomic.composite.loading"; //$NON-NLS-1$
- static final public boolean ATOMIC_LOADING_DEFAULT = false;
+
+ // by default, require that all children of a composite can be loaded; default may be changed to enforce old behavior (see bug 356561)
+ static final public boolean ATOMIC_LOADING_DEFAULT = !"false".equals(Activator.getContext().getProperty("eclipse.p2.atomic.composite.loading.default")); //$NON-NLS-1$//$NON-NLS-2$;
// keep a list of the child URIs. they can be absolute or relative. they may or may not point
// to a valid reachable repo

Back to the top