@Extension @Symbol(value="pollSCM") public static class SCMTrigger.DescriptorImpl extends TriggerDescriptor implements PersistentDescriptor
Descriptor.FormException, Descriptor.PropertyType, Descriptor.Self
Modifier and Type | Field and Description |
---|---|
boolean |
synchronousPolling
Whether the projects should be polled all in one go in the order of dependencies.
|
clazz
Constructor and Description |
---|
DescriptorImpl() |
Modifier and Type | Method and Description |
---|---|
void |
clogCheck()
Checks if the queue is clogged, and if so,
activate
SCMTrigger.AdministrativeMonitorImpl . |
boolean |
configure(org.kohsuke.stapler.StaplerRequest req,
net.sf.json.JSONObject json)
Invoked when the global configuration page is submitted.
|
FormValidation |
doCheckPollingThreadCount(String value) |
FormValidation |
doCheckScmpoll_spec(String value,
boolean ignorePostCommitHooks,
Item item)
Performs syntax check.
|
String |
getDisplayName()
Human readable name of this kind of configurable object.
|
ExecutorService |
getExecutor() |
List<SCMTriggerItem> |
getItemsBeingPolled() |
int |
getPollingThreadCount()
Gets the number of concurrent threads used for polling.
|
List<SCMTrigger.Runner> |
getRunners()
Gets the snapshot of
SCMTrigger.Runner s that are performing polling. |
boolean |
isApplicable(Item item)
Returns true if this trigger is applicable to the
given
Item . |
boolean |
isClogged()
Returns true if the SCM polling thread queue has too many jobs
than it can handle.
|
boolean |
isPollingThreadCountOptionVisible() |
void |
setPollingThreadCount(int n)
Sets the number of concurrent threads used for SCM polling and resizes the thread pool accordingly
|
addHelpFileRedirect, bindJSON, calcAutoCompleteSettings, calcFillSettings, configure, doHelp, find, find, findByDescribableClassName, findById, getCategory, getCheckMethod, getCheckUrl, getConfigFile, getConfigPage, getCurrentDescriptorByNameUrl, getDescriptorFullUrl, getDescriptorUrl, getGlobalConfigPage, getGlobalPropertyType, getHelpFile, getHelpFile, getHelpFile, getId, getJsonSafeClassName, getKlass, getPlugin, getPossibleViewNames, getPropertyType, getPropertyType, getPropertyTypeOrDie, getRequiredGlobalConfigPagePermission, getT, getViewPage, isInstance, isSubTypeOf, load, newInstance, newInstance, newInstancesFromHeteroList, newInstancesFromHeteroList, save, self, toArray, toList, toMap
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
load
public boolean synchronousPolling
public boolean isApplicable(Item item)
TriggerDescriptor
Item
.isApplicable
in class TriggerDescriptor
public ExecutorService getExecutor()
public boolean isClogged()
public void clogCheck()
SCMTrigger.AdministrativeMonitorImpl
.public List<SCMTrigger.Runner> getRunners()
SCMTrigger.Runner
s that are performing polling.public List<SCMTriggerItem> getItemsBeingPolled()
@NonNull public String getDisplayName()
Descriptor
Class.getSimpleName()
on Descriptor.clazz
, so for example MyThing
from some.pkg.MyThing.DescriptorImpl
.
Historically some implementations returned null as a way of hiding the descriptor from the UI,
but this is generally managed by an explicit method such as isEnabled
or isApplicable
.getDisplayName
in class Descriptor<Trigger<?>>
public int getPollingThreadCount()
public void setPollingThreadCount(int n)
n
- number of concurrent threads in the range 5..100, outside values will set the to the nearest bound@Restricted(value=org.kohsuke.accmod.restrictions.NoExternalUse.class) public boolean isPollingThreadCountOptionVisible()
public boolean configure(org.kohsuke.stapler.StaplerRequest req, net.sf.json.JSONObject json) throws Descriptor.FormException
Descriptor
configure
in class Descriptor<Trigger<?>>
json
- The JSON object that captures the configuration data for this Descriptor
.
See https://www.jenkins.io/doc/developer/forms/structured-form-submission/Descriptor.FormException
public FormValidation doCheckPollingThreadCount(@QueryParameter String value)
public FormValidation doCheckScmpoll_spec(@QueryParameter String value, @QueryParameter boolean ignorePostCommitHooks, @AncestorInPath Item item)
Copyright © 2004–2022. All rights reserved.