incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cziege...@apache.org
Subject svn commit: r1550899 - in /sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs: JobManagerConfiguration.java JobManagerImpl.java
Date Sat, 14 Dec 2013 08:15:24 GMT
Author: cziegeler
Date: Sat Dec 14 08:15:24 2013
New Revision: 1550899

URL: http://svn.apache.org/r1550899
Log:
SLING-3282 : No metatype generated for JobManagerImpl OSGi configuration

Modified:
    sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerConfiguration.java
    sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerImpl.java

Modified: sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerConfiguration.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerConfiguration.java?rev=1550899&r1=1550898&r2=1550899&view=diff
==============================================================================
--- sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerConfiguration.java
(original)
+++ sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerConfiguration.java
Sat Dec 14 08:15:24 2013
@@ -41,7 +41,7 @@ public class JobManagerConfiguration {
     public static final boolean DEFAULT_DISABLE_DISTRIBUTION = false;
 
     /** Default resource path for scheduled jobs. */
-    private static final String DEFAULT_SCHEDULED_JOBS_PATH = "/var/eventing/scheduled-jobs";
+    public static final String DEFAULT_SCHEDULED_JOBS_PATH = "/var/eventing/scheduled-jobs";
 
     /** The path where all jobs are stored. */
     public static final String PROPERTY_REPOSITORY_PATH = "repository.path";
@@ -53,7 +53,7 @@ public class JobManagerConfiguration {
     public static final String PROPERTY_DISABLE_DISTRIBUTION = "job.consumermanager.disableDistribution";
 
     /** Configuration property for the scheduled jobs path. */
-    private static final String PROPERTY_SCHEDULED_JOBS_PATH = "job.scheduled.jobs.path";
+    public static final String PROPERTY_SCHEDULED_JOBS_PATH = "job.scheduled.jobs.path";
 
     /** The jobs base path with a slash. */
     private String jobsBasePathWithSlash;

Modified: sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerImpl.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerImpl.java?rev=1550899&r1=1550898&r2=1550899&view=diff
==============================================================================
--- sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerImpl.java
(original)
+++ sling/trunk/bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/JobManagerImpl.java
Sat Dec 14 08:15:24 2013
@@ -94,14 +94,25 @@ import org.slf4j.LoggerFactory;
 /**
  * Implementation of the job manager.
  */
-@Component(immediate=true,
+@Component(immediate=true, metatype=true,
+           label="Apache Sling Job Manager",
+           description="This is the central service of the job handling.",
            name="org.apache.sling.event.impl.jobs.jcr.PersistenceHandler")
 @Service(value={JobManager.class, EventHandler.class, TopologyEventListener.class, Runnable.class})
 @Properties({
+    @Property(name=JobManagerConfiguration.PROPERTY_DISABLE_DISTRIBUTION,
+            boolValue=JobManagerConfiguration.DEFAULT_DISABLE_DISTRIBUTION,
+            label="Disable Distribution",
+            description="If the distribution is disabled, all jobs will be processed on the
leader only! Please use this switch " +
+                        "with care."),
     @Property(name=JobManagerConfiguration.PROPERTY_REPOSITORY_PATH,
-          value=JobManagerConfiguration.DEFAULT_REPOSITORY_PATH),
-    @Property(name="scheduler.period", longValue=60),
-    @Property(name="scheduler.concurrent", boolValue=false),
+             value=JobManagerConfiguration.DEFAULT_REPOSITORY_PATH, propertyPrivate=true),
+    @Property(name=JobManagerConfiguration.PROPERTY_SCHEDULED_JOBS_PATH,
+             value=JobManagerConfiguration.DEFAULT_SCHEDULED_JOBS_PATH, propertyPrivate=true),
+    @Property(name=JobManagerConfiguration.PROPERTY_BACKGROUND_LOAD_DELAY,
+             longValue=JobManagerConfiguration.DEFAULT_BACKGROUND_LOAD_DELAY, propertyPrivate=true),
+    @Property(name="scheduler.period", longValue=60, propertyPrivate=true),
+    @Property(name="scheduler.concurrent", boolValue=false, propertyPrivate=true),
     @Property(name=EventConstants.EVENT_TOPIC,
               value={SlingConstants.TOPIC_RESOURCE_ADDED,
                      SlingConstants.TOPIC_RESOURCE_CHANGED,
@@ -109,7 +120,7 @@ import org.slf4j.LoggerFactory;
                      "org/apache/sling/event/notification/job/*",
                      Utility.TOPIC_STOP,
                      ResourceHelper.BUNDLE_EVENT_STARTED,
-                     ResourceHelper.BUNDLE_EVENT_UPDATED})
+                     ResourceHelper.BUNDLE_EVENT_UPDATED}, propertyPrivate=true),
 })
 public class JobManagerImpl
     extends StatisticsImpl



Mime
View raw message