sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dav...@apache.org
Subject [sling-org-apache-sling-installer-factory-feature] 15/32: Correctly configure caching directory
Date Tue, 01 Sep 2020 16:33:06 GMT
This is an automated email from the ASF dual-hosted git repository.

davidb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-installer-factory-feature.git

commit 542240c4b230d78d27926119db053b288186f20e
Author: Carsten Ziegeler <cziegeler@apache.org>
AuthorDate: Wed Apr 29 17:41:32 2020 +0200

    Correctly configure caching directory
---
 .../installer/factory/model/impl/FeatureModelInstallerPlugin.java     | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/main/java/org/apache/sling/installer/factory/model/impl/FeatureModelInstallerPlugin.java
b/src/main/java/org/apache/sling/installer/factory/model/impl/FeatureModelInstallerPlugin.java
index 3c1b870..cc86f97 100644
--- a/src/main/java/org/apache/sling/installer/factory/model/impl/FeatureModelInstallerPlugin.java
+++ b/src/main/java/org/apache/sling/installer/factory/model/impl/FeatureModelInstallerPlugin.java
@@ -108,10 +108,10 @@ public class FeatureModelInstallerPlugin implements InstallTaskFactory,
Resource
         this.storageDirectory = this.bundleContext.getDataFile("repository");
         final ArtifactManagerConfig amCfg = new ArtifactManagerConfig();
         amCfg.setUseMvn(config.useMvn());
-        final List<String> repos = new ArrayList<>(Arrays.asList(amCfg.getRepositoryUrls()));
         if (this.storageDirectory != null) {
-            repos.add(this.storageDirectory.toURI().toURL().toExternalForm());
+            amCfg.setCacheDirectory(storageDirectory);
         }
+        final List<String> repos = new ArrayList<>(Arrays.asList(amCfg.getRepositoryUrls()));
         if (config.repositories() != null && config.repositories().length > 0)
{
             for (final String r : config.repositories()) {
                 if (!r.trim().isEmpty()) {


Mime
View raw message