AbstractProject j = Jenkins.getInstance().getItemByFullName(line, AbstractProject.class); if (j != null) j.scheduleBuild();
continue; boolean scheduled = p.scheduleBuild(p.getQuietPeriod(), new UpstreamCause((Run)build), buildActions.toArray(new Action[buildActions.size()])); if (Jenkins.getInstance().getItemByFullName(p.getFullName()) == p) { String name = ModelHyperlinkNote.encodeTo(p);
/** * @deprecated * You need to be using {@link #scheduleBuild(AbstractBuild)} */ @Deprecated public boolean scheduleBuild() { return super.scheduleBuild(); }
@Deprecated @Override public boolean scheduleBuild() { return super.scheduleBuild(); }
@Deprecated @Override public boolean scheduleBuild(int quietPeriod) { return super.scheduleBuild(quietPeriod); }
/** * @deprecated Use {@link #scheduleBuild(Cause)}. Since 1.283 */ public boolean scheduleBuild() { return scheduleBuild(new LegacyCodeCause()); }
/** * @deprecated * Use {@link #scheduleBuild(int, Cause)}. Since 1.283 */ public boolean scheduleBuild(int quietPeriod) { return scheduleBuild(quietPeriod, new LegacyCodeCause()); }
/** * @deprecated Use {@link #scheduleBuild(Cause)}. Since 1.283 */ public boolean scheduleBuild() { return scheduleBuild(new LegacyCodeCause()); }
/** * Schedules a build of this project. * * @return true if the project is actually added to the queue. false if the * queue contained it and therefore the add() was noop */ public boolean scheduleBuild(Cause c) { return scheduleBuild(getQuietPeriod(), c); }
/** * @deprecated * Use {@link #scheduleBuild(int, Cause)}. Since 1.283 */ public boolean scheduleBuild(int quietPeriod) { return scheduleBuild(quietPeriod, new LegacyCodeCause()); }
/** * Schedules a build of this project. * * @return true if the project is actually added to the queue. false if the * queue contained it and therefore the add() was noop */ public boolean scheduleBuild(Cause c) { return scheduleBuild(getQuietPeriod(), c); }
/** * Schedules a build of this project. * * @return * true if the project is actually added to the queue. * false if the queue contained it and therefore the add() * was noop */ public boolean scheduleBuild(Cause c) { return scheduleBuild(getQuietPeriod(), c); }
/** * @deprecated * Use {@link #scheduleBuild(Cause)}. Since 1.283 */ public boolean scheduleBuild() { return scheduleBuild(new LegacyCodeCause()); }
/** * Schedules a build of this project. * * @return * true if the project is actually added to the queue. * false if the queue contained it and therefore the add() * was noop */ public boolean scheduleBuild(Cause c) { return scheduleBuild(getQuietPeriod(), c); }
/** * @deprecated Use {@link #scheduleBuild(int, Cause)}. Since 1.283 */ public boolean scheduleBuild(int quietPeriod) { return scheduleBuild(quietPeriod, new LegacyCodeCause()); }
/** * @deprecated Use {@link #scheduleBuild(int, Cause)}. Since 1.283 */ public boolean scheduleBuild(int quietPeriod) { return scheduleBuild(quietPeriod, new LegacyCodeCause()); }
@Override public boolean scheduleBuild(Cause c) { if(c instanceof ParameterizedUpstreamCause) { ParameterizedUpstreamCause upc = (ParameterizedUpstreamCause) c; if(isUseUpstreamParameters()) { List<ParametersAction> upStreamParams = upc.getUpStreamParameters(); return scheduleBuild(getQuietPeriod(),c,upStreamParams.toArray(new ParametersAction[upStreamParams.size()])); } } return super.scheduleBuild(c); } }
@Override public boolean scheduleBuild(Cause c) { if(c instanceof ParameterizedUpstreamCause) { ParameterizedUpstreamCause upc = (ParameterizedUpstreamCause) c; if(isUseUpstreamParameters()) { List<ParametersAction> upStreamParams = upc.getUpStreamParameters(); return scheduleBuild(getQuietPeriod(),c,upStreamParams.toArray(new ParametersAction[upStreamParams.size()])); } } return super.scheduleBuild(c); } }
/** * @param triggerProjectName * the triggerProjectName * @return the number of re-tried build */ @JavaScriptMethod public int retryBuild(final String triggerProjectName) { LOGGER.fine("Retrying build again: " + triggerProjectName); //$NON-NLS-1$ final AbstractProject<?, ?> triggerProject = (AbstractProject<?, ?>) super.getJob(triggerProjectName); triggerProject.scheduleBuild(new MyUserIdCause()); return triggerProject.getNextBuildNumber(); }
private void saveAndSchedule(ItemLastModified itemLastModified, AbstractProject project) throws IOException { logger.fine("Updating " + job.getName()); project.save(); project.scheduleBuild(new ArtifactoryCause(itemLastModified.getUri())); }