@Override public boolean endBuild() throws InterruptedException, IOException { perform(build, launcher, listener); return super.endBuild(); } };
@Override public void buildEnvironmentFor(@Nonnull Run r, @Nonnull EnvVars envs, @Nonnull TaskListener listener) throws IOException, InterruptedException { GitLabWebHookCause cause = null; if (r instanceof MatrixRun) { MatrixBuild parent = ((MatrixRun)r).getParentBuild(); if (parent != null) { cause = (GitLabWebHookCause) parent.getCause(GitLabWebHookCause.class); } } else { cause = (GitLabWebHookCause) r.getCause(GitLabWebHookCause.class); } if (cause != null) { envs.overrideAll(cause.getData().getBuildVariables()); } } }
/** * True if this build didn't do a full build and it is depending on the result of the previous build. */ public boolean isPartial() { for(MatrixConfiguration c : getParent().getActiveConfigurations()) { MatrixRun b = c.getNearestOldBuild(getNumber()); if (b != null && b.getNumber()!=getNumber()) return true; } return false; }
/** * Gets the {@link MatrixBuild} that has the same build number. * * @return * null if no such build exists, which happens when the module build * is manually triggered. */ public MatrixBuild getParentBuild() { return getParent().getParent().getBuildByNumber(getNumber()); }
/** * Like {@link #getRun(Combination)}, but do not approximate the result by earlier execution * of the given combination (which is done for partial rebuild of the matrix.) */ public MatrixRun getExactRun(Combination c) { MatrixConfiguration config = getParent().getItem(c); if(config==null) return null; return config.getBuildByNumber(getNumber()); }
@Override public AbstractBuild<?,?> resolveChild(Child child) { MatrixBuild b = (MatrixBuild)owner; return b.getProject().getItem(Combination.fromString(child.name)).getBuildByNumber(child.build); }
/** * @since 2.1.0 */ @Override public DescribableList<BuildWrapper, Descriptor<BuildWrapper>> getBuildWrappersList() { return getParent().getBuildWrappersList(); }
/** * Gets the {@link MatrixRun} in this build that corresponds * to the given combination. */ public MatrixRun getRun(Combination c) { MatrixConfiguration config = getParent().getItem(c); if(config==null) return null; return getRunForConfiguration(config); }
/** * Inherit the value from the parent. */ @Override public SCMCheckoutStrategy getScmCheckoutStrategy() { return getParent().getScmCheckoutStrategy(); }
/** * Applies the filter to the specified combination in the context of {@code context}. */ public final boolean apply(MatrixBuildExecution context, Combination combination) { return apply(context.getProject().getAxes(), combination, getConfiguredBinding(context)); }
/** * Gets the {@link MatrixBuild} that has the same build number. * * @return * null if no such build exists, which happens when the module build * is manually triggered. */ public MatrixBuild getParentBuild() { return getParent().getParent().getBuildByNumber(getNumber()); }
/** * Gets the {@link MatrixRun} in this build that corresponds * to the given combination. */ public MatrixRun getRun(Combination c) { MatrixConfiguration config = getParent().getItem(c); if (config == null) { return null; } return config.getBuildByNumber(getNumber()); }
@Override public boolean endBuild() throws InterruptedException, IOException { perform(build, launcher, listener); return super.endBuild(); } };
/** * Gets the {@link MatrixBuild} that has the same build number. * * @return null if no such build exists, which happens when the module build * is manually triggered. */ public MatrixBuild getParentBuild() { return getParent().getParent().getBuildByNumber(getNumber()); }
/** * Gets the {@link MatrixRun} in this build that corresponds * to the given combination. */ public MatrixRun getRun(Combination c) { MatrixConfiguration config = getParent().getItem(c); if (config == null) { return null; } return config.getBuildByNumber(getNumber()); }
/** * Gets the {@link MatrixBuild} that has the same build number. * * @return * null if no such build exists, which happens when the module build * is manually triggered. */ public MatrixBuild getParentBuild() { return getParent().getParent().getBuildByNumber(getNumber()); }
/** * Gets the {@link MatrixRun} in this build that corresponds to the given * combination. */ public MatrixRun getRun(Combination c) { MatrixConfiguration config = getParent().getItem(c); if (config == null) { return null; } return config.getBuildByNumber(getNumber()); }
/** * Gets the {@link MatrixBuild} that has the same build number. * * @return * null if no such build exists, which happens when the module build * is manually triggered. */ public MatrixBuild getParentBuild() { return getParent().getParent().getBuildByNumber(getNumber()); }
/** * Gets the {@link MatrixRun} in this build that corresponds * to the given combination. */ public MatrixRun getRun(Combination c) { MatrixConfiguration config = getParent().getItem(c); if (config == null) { return null; } return config.getBuildByNumber(getNumber()); }