|
|
0f5e1f |
From edd5a395dd96699f91c463c0e0409a7488814775 Mon Sep 17 00:00:00 2001
|
|
|
0f5e1f |
From: Roland Grunberg <rgrunber@redhat.com>
|
|
|
0f5e1f |
Date: Tue, 16 Aug 2016 17:51:46 -0400
|
|
|
0f5e1f |
Subject: [PATCH] Skip loading droplets in the configuration during
|
|
|
0f5e1f |
reconciliation.
|
|
|
0f5e1f |
|
|
|
0f5e1f |
The reconciler attempts to load droplets as extended locations, which
|
|
|
0f5e1f |
seems to be an expensive operation. Avoid doing this for the sake of
|
|
|
0f5e1f |
efficiency.
|
|
|
0f5e1f |
|
|
|
0f5e1f |
Change-Id: Iaf07aacb2d7eaabf3730654e757e69d22f0bc4ab
|
|
|
0f5e1f |
---
|
|
|
0f5e1f |
.../internal/p2/reconciler/dropins/PlatformXmlListener.java | 13 +++++++++++++
|
|
|
0f5e1f |
1 file changed, 13 insertions(+)
|
|
|
0f5e1f |
|
|
|
0f5e1f |
diff --git rt.equinox.p2/bundles/org.eclipse.equinox.p2.reconciler.dropins/src/org/eclipse/equinox/internal/p2/reconciler/dropins/PlatformXmlListener.java rt.equinox.p2/bundles/org.eclipse.equinox.p2.reconciler.dropins/src/org/eclipse/equinox/internal/p2/reconciler/dropins/PlatformXmlListener.java
|
|
|
0f5e1f |
index 802ee1b..74023fe 100644
|
|
|
0f5e1f |
--- rt.equinox.p2/bundles/org.eclipse.equinox.p2.reconciler.dropins/src/org/eclipse/equinox/internal/p2/reconciler/dropins/PlatformXmlListener.java
|
|
|
0f5e1f |
+++ rt.equinox.p2/bundles/org.eclipse.equinox.p2.reconciler.dropins/src/org/eclipse/equinox/internal/p2/reconciler/dropins/PlatformXmlListener.java
|
|
|
0f5e1f |
@@ -172,11 +172,24 @@ public class PlatformXmlListener extends DirectoryChangeListener {
|
|
|
0f5e1f |
* Ensure that we have a repository for each site in the given configuration.
|
|
|
0f5e1f |
*/
|
|
|
0f5e1f |
protected void synchronizeConfiguration(Configuration config) {
|
|
|
0f5e1f |
+ String fragments = System.getProperty("p2.fragments");
|
|
|
0f5e1f |
List<Site> sites = config.getSites();
|
|
|
0f5e1f |
Set<IMetadataRepository> newRepos = new LinkedHashSet<>();
|
|
|
0f5e1f |
Set<Site> toBeRemoved = new HashSet<>();
|
|
|
0f5e1f |
for (Site site : sites) {
|
|
|
0f5e1f |
String siteURL = site.getUrl();
|
|
|
0f5e1f |
+ if (fragments != null) {
|
|
|
0f5e1f |
+ String[] rootPaths = fragments.split(",");
|
|
|
0f5e1f |
+ boolean skip = false;
|
|
|
0f5e1f |
+ for (String path : rootPaths) {
|
|
|
0f5e1f |
+ if (siteURL.startsWith("file:" + path)) {
|
|
|
0f5e1f |
+ skip = true;
|
|
|
0f5e1f |
+ }
|
|
|
0f5e1f |
+ }
|
|
|
0f5e1f |
+ if (skip) {
|
|
|
0f5e1f |
+ continue;
|
|
|
0f5e1f |
+ }
|
|
|
0f5e1f |
+ }
|
|
|
0f5e1f |
IMetadataRepository match = getMatchingRepo(Activator.getRepositories(), siteURL);
|
|
|
0f5e1f |
if (match == null) {
|
|
|
0f5e1f |
try {
|
|
|
0f5e1f |
--
|
|
|
0f5e1f |
2.7.4
|
|
|
0f5e1f |
|