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

rombert pushed a commit to annotated tag org.apache.sling.hc.annotations-1.0.4
in repository 
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-hc-annotations.git

commit 23176cdf05dd0cde45896eda129535ce9858387b
Author: Konrad Windszus <[email protected]>
AuthorDate: Thu Feb 25 08:31:55 2016 +0000

    SLING-4417 allow to configure immediate flag in the healthcheck annotation 
and use that in some examples
    
    git-svn-id: 
https://svn.apache.org/repos/asf/sling/trunk/bundles/extensions/healthcheck/annotations@1732260
 13f79535-47bb-0310-9956-ffa450edef68
---
 src/main/java/org/apache/sling/hc/annotations/SlingHealthCheck.java    | 3 +++
 .../org/apache/sling/hc/annotations/SlingHealthCheckProcessor.java     | 2 ++
 2 files changed, 5 insertions(+)

diff --git 
a/src/main/java/org/apache/sling/hc/annotations/SlingHealthCheck.java 
b/src/main/java/org/apache/sling/hc/annotations/SlingHealthCheck.java
index 9c7abd5..f5619f4 100644
--- a/src/main/java/org/apache/sling/hc/annotations/SlingHealthCheck.java
+++ b/src/main/java/org/apache/sling/hc/annotations/SlingHealthCheck.java
@@ -64,6 +64,9 @@ public @interface SlingHealthCheck {
      * file for this component. Otherwise no Metatype Service data is 
generated for this component. */
     boolean metatype() default true;
 
+    /** Whether immediate is set on the SCR component.  */
+    boolean immediate() default false;
+
     /** Set the metatype factory pid property (only for non factory 
components). */
     boolean configurationFactory() default false;
 
diff --git 
a/src/main/java/org/apache/sling/hc/annotations/SlingHealthCheckProcessor.java 
b/src/main/java/org/apache/sling/hc/annotations/SlingHealthCheckProcessor.java
index fe388ba..f9caaf4 100644
--- 
a/src/main/java/org/apache/sling/hc/annotations/SlingHealthCheckProcessor.java
+++ 
b/src/main/java/org/apache/sling/hc/annotations/SlingHealthCheckProcessor.java
@@ -54,6 +54,7 @@ public class SlingHealthCheckProcessor implements 
AnnotationProcessor {
 
         final boolean generateComponent = 
cad.getBooleanValue("generateComponent", true);
         final boolean metatype = cad.getBooleanValue("metatype", true);
+        final boolean immediate = cad.getBooleanValue("immediate", false);
 
         // generate ComponentDescription if required
         if (generateComponent) {
@@ -71,6 +72,7 @@ public class SlingHealthCheckProcessor implements 
AnnotationProcessor {
             cd.setDescription(cad.getStringValue("description", "Health Check 
Configuration"));
 
             cd.setCreateMetatype(metatype);
+            cd.setImmediate(immediate);
 
             classDescription.add(cd);
         }

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

Reply via email to