You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by ro...@apache.org on 2017/11/07 09:49:51 UTC
[sling-org-apache-sling-jcr-repoinit] 06/29: SLING-6179 Remove
default value for property references from RepositoryInitializer
This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to annotated tag org.apache.sling.jcr.repoinit-1.1.0
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-jcr-repoinit.git
commit 9a17a98a3a90a248d6d891aaba51ac2db5fee0f4
Author: Oliver Lietz <ol...@apache.org>
AuthorDate: Fri Oct 28 08:10:12 2016 +0000
SLING-6179 Remove default value for property references from RepositoryInitializer
git-svn-id: https://svn.apache.org/repos/asf/sling/trunk/bundles/jcr/repoinit@1766960 13f79535-47bb-0310-9956-ffa450edef68
---
.../jcr/repoinit/impl/RepositoryInitializer.java | 24 ++++++++++------------
1 file changed, 11 insertions(+), 13 deletions(-)
diff --git a/src/main/java/org/apache/sling/jcr/repoinit/impl/RepositoryInitializer.java b/src/main/java/org/apache/sling/jcr/repoinit/impl/RepositoryInitializer.java
index 9dbab2c..c73f784 100644
--- a/src/main/java/org/apache/sling/jcr/repoinit/impl/RepositoryInitializer.java
+++ b/src/main/java/org/apache/sling/jcr/repoinit/impl/RepositoryInitializer.java
@@ -55,33 +55,31 @@ import org.slf4j.LoggerFactory;
public class RepositoryInitializer implements SlingRepositoryInitializer {
private final Logger log = LoggerFactory.getLogger(getClass());
- public static final String DEFAULT_REFERENCE = "model@repoinit:context:/resources/provisioning/model.txt";
-
@Property(
- label="Repoinit references",
+ label="Repoinit references",
description=
"References to the source text that provides repoinit statements."
+ " format is either model@repoinit:<provisioning model URL> or raw:<raw URL>"
,
cardinality=Integer.MAX_VALUE,
- value={ DEFAULT_REFERENCE })
+ value={})
public static final String PROP_REFERENCES = "references";
private String [] references;
-
+
@Reference
private RepoInitParser parser;
-
+
@Reference
private JcrRepoInitOpsProcessor processor;
-
+
@Activate
public void activate(Map<String, Object> config) {
warnForOldConfigParameters(config);
- references = PropertiesUtil.toStringArray(config.get(PROP_REFERENCES));
+ references = PropertiesUtil.toStringArray(config.get(PROP_REFERENCES), new String[]{});
log.debug("Activated: {}", this.toString());
}
-
- /** Some config parameters are not used anymore as of V1.0.2, this logs
+
+ /** Some config parameters are not used anymore as of V1.0.2, this logs
* warnings if they are still used.
*/
private void warnForOldConfigParameters(Map<String, Object> config) {
@@ -96,7 +94,7 @@ public class RepositoryInitializer implements SlingRepositoryInitializer {
}
}
}
-
+
@Override
public String toString() {
return getClass().getSimpleName() + ", references=" + Arrays.asList(references);
@@ -118,5 +116,5 @@ public class RepositoryInitializer implements SlingRepositoryInitializer {
} finally {
s.logout();
}
- }
-}
\ No newline at end of file
+ }
+}
--
To stop receiving notification emails like this one, please contact
"commits@sling.apache.org" <co...@sling.apache.org>.