sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From romb...@apache.org
Subject [sling-org-apache-sling-testing-paxexam] 08/48: SLING-5893 Provide a default Launchpad Oak Tar configuration as Option for Pax Exam
Date Tue, 07 Nov 2017 10:19:48 GMT
This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to annotated tag org.apache.sling.testing.paxexam-0.0.2
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-testing-paxexam.git

commit dbee5a3f67f1ec1d5e65d44ff1964ac50c42aa48
Author: Oliver Lietz <olli@apache.org>
AuthorDate: Fri Jul 22 17:19:36 2016 +0000

    SLING-5893 Provide a default Launchpad Oak Tar configuration as Option for Pax Exam
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/testing/org.apache.sling.testing.paxexam@1753814
13f79535-47bb-0310-9956-ffa450edef68
---
 .../apache/sling/testing/paxexam/SlingOptions.java   | 18 ++++++++++++++++++
 src/main/resources/templates/SlingOptions.txt        | 20 +++++++++++++++++++-
 2 files changed, 37 insertions(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/sling/testing/paxexam/SlingOptions.java b/src/main/java/org/apache/sling/testing/paxexam/SlingOptions.java
index 6af30ff..972966b 100644
--- a/src/main/java/org/apache/sling/testing/paxexam/SlingOptions.java
+++ b/src/main/java/org/apache/sling/testing/paxexam/SlingOptions.java
@@ -781,4 +781,22 @@ public class SlingOptions {
         );
     }
 
+    public static Option slingLaunchpadOakTarConfiguration(final String workingDirectory,
final int httpPort) {
+        final String slingHome = String.format("%s/sling", workingDirectory);
+        final String repositoryHome = String.format("%s/repository", slingHome);
+        final String localIndexDir = String.format("%s/index", repositoryHome);
+        return composite(
+            newConfiguration("org.apache.felix.http")
+                .put("org.osgi.service.http.port", httpPort)
+                .asOption(),
+            newConfiguration("org.apache.jackrabbit.oak.plugins.segment.SegmentNodeStoreService")
+                .put("repository.home", repositoryHome)
+                .put("name", "Default NodeStore")
+                .asOption(),
+            newConfiguration("org.apache.jackrabbit.oak.plugins.index.lucene.LuceneIndexProviderService")
+                .put("localIndexDir", localIndexDir)
+                .asOption()
+        );
+    }
+
 }
diff --git a/src/main/resources/templates/SlingOptions.txt b/src/main/resources/templates/SlingOptions.txt
index 8dcaf11..6acb9dc 100644
--- a/src/main/resources/templates/SlingOptions.txt
+++ b/src/main/resources/templates/SlingOptions.txt
@@ -85,4 +85,22 @@ public class SlingOptions {
         );
     }
 
-[/]}
+[/]    public static Option slingLaunchpadOakTarConfiguration(final String workingDirectory,
final int httpPort) {
+        final String slingHome = String.format("%s/sling", workingDirectory);
+        final String repositoryHome = String.format("%s/repository", slingHome);
+        final String localIndexDir = String.format("%s/index", repositoryHome);
+        return composite(
+            newConfiguration("org.apache.felix.http")
+                .put("org.osgi.service.http.port", httpPort)
+                .asOption(),
+            newConfiguration("org.apache.jackrabbit.oak.plugins.segment.SegmentNodeStoreService")
+                .put("repository.home", repositoryHome)
+                .put("name", "Default NodeStore")
+                .asOption(),
+            newConfiguration("org.apache.jackrabbit.oak.plugins.index.lucene.LuceneIndexProviderService")
+                .put("localIndexDir", localIndexDir)
+                .asOption()
+        );
+    }
+
+}

-- 
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <commits@sling.apache.org>.

Mime
View raw message