Package io.jenkins.plugins.finitestate
Class FiniteStateExecutionFramework
java.lang.Object
io.jenkins.plugins.finitestate.FiniteStateExecutionFramework
Execution framework for Finite State analysis operations.
Dispatches to one of two transports based on BaseFiniteStateRecorder.isRestApi():
- 2026 platform release — the public v0 REST API flow (
executeViaApi(io.jenkins.plugins.finitestate.BaseFiniteStateRecorder, hudson.model.Run<?, ?>, hudson.FilePath, hudson.model.TaskListener, java.lang.String, java.lang.String)): resolve token, compute the target version, locate the workspace file, run the scan on the agent (FiniteStateScanCallable) and translate theScanResultinto a build outcome. - Legacy platform (default) — the Java CLT flow (
executeViaClt(io.jenkins.plugins.finitestate.BaseFiniteStateRecorder, hudson.model.Run<?, ?>, hudson.FilePath, hudson.Launcher, hudson.model.TaskListener, java.lang.String)): download the CLT jar and exec it on the agent, mapping the process exit code onto the build outcome.
Keeping both paths lets a single published plugin serve existing legacy-platform jobs unchanged and 2026-platform jobs by flipping the platform selector. See HELIX-422.
-
Method Summary
Modifier and TypeMethodDescriptionstatic booleanexecuteAnalysis(BaseFiniteStateRecorder recorder, AbstractBuild<?, ?> build, Launcher launcher, BuildListener listener) Backward-compatible shim for freestyle builds usingAbstractBuildAPI.static booleanexecuteAnalysis(BaseFiniteStateRecorder recorder, Run<?, ?> run, FilePath workspace, Launcher launcher, TaskListener listener) Execute a Finite State analysis with common error handling and logging, routing to the 2026 platform (v0 API) or legacy platform (CLT) transport based on the recorder's selected platform.
-
Method Details
-
executeAnalysis
public static boolean executeAnalysis(BaseFiniteStateRecorder recorder, Run<?, ?> run, FilePath workspace, Launcher launcher, TaskListener listener) throws InterruptedException, IOExceptionExecute a Finite State analysis with common error handling and logging, routing to the 2026 platform (v0 API) or legacy platform (CLT) transport based on the recorder's selected platform.- Parameters:
recorder- Recorder that encapsulates analysis configuration and helpersrun- Jenkins run/build context used for environment and loggingworkspace- Workspace directory where files (and, for the legacy platform, the CLT) are accessedlauncher- Jenkins launcher (used by the legacy CLT transport to exec the CLT)listener- Build/task listener for console logging- Returns:
- true when the analysis succeeded (or was accepted, when not waiting); false on failure
- Throws:
InterruptedException- if execution is interruptedIOException- if file I/O (or CLT download) fails
-
executeAnalysis
public static boolean executeAnalysis(BaseFiniteStateRecorder recorder, AbstractBuild<?, ?> build, Launcher launcher, BuildListener listener) throws InterruptedException, IOExceptionBackward-compatible shim for freestyle builds usingAbstractBuildAPI.- Throws:
InterruptedExceptionIOException
-