Package org.jenkinsci.plugins.saml
Class UpdateMetadataFromURLPeriodicWork
- java.lang.Object
-
- java.util.TimerTask
-
- hudson.triggers.SafeTimerTask
-
- hudson.model.AperiodicWork
-
- hudson.model.AsyncAperiodicWork
-
- org.jenkinsci.plugins.saml.UpdateMetadataFromURLPeriodicWork
-
- All Implemented Interfaces:
ExtensionPoint
,Runnable
@Extension public class UpdateMetadataFromURLPeriodicWork extends AsyncAperiodicWork
This periodic work update the IdP Metadata File, the periodicof the execution is defined on the SAML Plugin configuration.
If the Preriod is set to 0 the Periodic work is mostly disabled, it will check the changes on config every 10 minutes to see if it is enabled again, if the period change it is re-enabled again.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class hudson.triggers.SafeTimerTask
SafeTimerTask.ExceptionRunnable
-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Field Summary
Fields Modifier and Type Field Description static long
INITIAL_DELAY
static String
INITIAL_DELAY_PROPERTY
property to set the initial delay of the AsyncAperiodicWork.-
Fields inherited from class hudson.model.AsyncAperiodicWork
name
-
Fields inherited from class hudson.model.AperiodicWork
logger
-
-
Constructor Summary
Constructors Constructor Description UpdateMetadataFromURLPeriodicWork()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
execute(TaskListener listener)
long
getInitialDelay()
AperiodicWork
getNewInstance()
long
getRecurrencePeriod()
-
Methods inherited from class hudson.model.AsyncAperiodicWork
createListener, doAperiodicRun, getErrorLoggingLevel, getLogFile, getNormalLoggingLevel, getSlowLoggingLevel
-
Methods inherited from class hudson.model.AperiodicWork
all, doRun, init
-
Methods inherited from class hudson.triggers.SafeTimerTask
getLogsRoot, of, run
-
Methods inherited from class java.util.TimerTask
cancel, scheduledExecutionTime
-
-
-
-
Field Detail
-
INITIAL_DELAY_PROPERTY
public static final String INITIAL_DELAY_PROPERTY
property to set the initial delay of the AsyncAperiodicWork. -Dorg.jenkinsci.plugins.saml.UpdateMetadataFromURLPeriodicWork.initialDelay=MILLISECONDS
-
INITIAL_DELAY
public static final long INITIAL_DELAY
-
-
Method Detail
-
getRecurrencePeriod
public long getRecurrencePeriod()
- Specified by:
getRecurrencePeriod
in classAperiodicWork
- Returns:
- the configured period, if the configured period is 0 return 10 minutes, if we are starting the Jenkins instance schedule an execution after 10 seconds.
-
getInitialDelay
public long getInitialDelay()
- Overrides:
getInitialDelay
in classAperiodicWork
-
getNewInstance
public AperiodicWork getNewInstance()
- Specified by:
getNewInstance
in classAperiodicWork
-
execute
protected void execute(TaskListener listener)
Connect to the URL configured on the SAML configuration to get the IdP Metadata, then download it
if the period configured is 0 it returns directly, do nothing.
- Specified by:
execute
in classAsyncAperiodicWork
-
-