This is an automated email from the ASF dual-hosted git repository.

rombert pushed a commit to branch master
in repository 
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-dynamic-include.git


The following commit(s) were added to refs/heads/master by this push:
     new d6dd9f2  SLING-7695 - Introduce a name hint for SDI OSGi config entries
d6dd9f2 is described below

commit d6dd9f29faa24686a9dbdcd12ecfa15592570381
Author: Tomasz Niedzwiedz <[email protected]>
AuthorDate: Tue May 29 09:46:00 2018 +0200

    SLING-7695 - Introduce a name hint for SDI OSGi config entries
    
    Add an extra name hint property to the Configuration class to make it
    easier to find a specific configuration in the OSGi console.
    
    Instead of the class name and a hash, the include type, the resoruce
    types and the path are displayed.
---
 src/main/java/org/apache/sling/dynamicinclude/Configuration.java | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/sling/dynamicinclude/Configuration.java 
b/src/main/java/org/apache/sling/dynamicinclude/Configuration.java
index f3b80a9..9cb6695 100755
--- a/src/main/java/org/apache/sling/dynamicinclude/Configuration.java
+++ b/src/main/java/org/apache/sling/dynamicinclude/Configuration.java
@@ -60,7 +60,8 @@ import org.slf4j.LoggerFactory;
     @Property(name = Configuration.PROPERTY_COMPONENT_TTL, label = "Component 
TTL", description = "\"Time to live\" cache header for rendered component (in 
seconds)"),
     @Property(name = Configuration.PROPERTY_REQUIRED_HEADER, value = 
Configuration.DEFAULT_REQUIRED_HEADER, label = "Required header", description = 
"SDI will work only for requests with given header"),
     @Property(name = Configuration.PROPERTY_IGNORE_URL_PARAMS, cardinality = 
Integer.MAX_VALUE, label = "Ignore URL params", description = "SDI will process 
the request even if it contains configured GET parameters"),
-    @Property(name = Configuration.PROPERTY_REWRITE_PATH, boolValue = 
Configuration.DEFAULT_REWRITE_DISABLED, label = "Include path rewriting", 
description = "Check to enable include path rewriting")})
+    @Property(name = Configuration.PROPERTY_REWRITE_PATH, boolValue = 
Configuration.DEFAULT_REWRITE_DISABLED, label = "Include path rewriting", 
description = "Check to enable include path rewriting"),
+    @Property(name= Configuration.NAME_HINT_PROPERTY_NAME, 
value=Configuration.NAME_HINT_VALUE)})
 public class Configuration {
 
   private static final Logger LOG = 
LoggerFactory.getLogger(Configuration.class);
@@ -97,6 +98,11 @@ public class Configuration {
 
   static final String PROPERTY_REWRITE_PATH = "include-filter.config.rewrite";
 
+  static final String NAME_HINT_PROPERTY_NAME = 
"webconsole.configurationFactory.nameHint";
+
+  static final String NAME_HINT_VALUE = "{" + PROPERTY_INCLUDE_TYPE + "} for 
[{"
+            + PROPERTY_FILTER_RESOURCE_TYPES + "}] at path: {" + 
PROPERTY_FILTER_PATH + "}";
+
   static final boolean DEFAULT_REWRITE_DISABLED = false;
 
   private PathMatcher pathMatcher;

-- 
To stop receiving notification emails like this one, please contact
[email protected].

Reply via email to