Class ProcessStage
java.lang.Object
com.tnsai.quality.security.harness.ProcessStage
- All Implemented Interfaces:
PipelineStage
The
process stage (TNS-291). Iterates over scanned
FileRecords and invokes the first registered
ReviewAgentSpi on each, persisting findings + an
AgentRun entry per invocation.
Idempotent: skips files where the most recent successful agent run
had the same (agentId, agentVersion, inputHash) tuple.
Re-running after the agent's version bumps invalidates cached runs;
re-running after the file content changes invalidates them too.
Cost containment (lightweight): process.maxFiles and
process.maxFindings config keys cap the work this stage does
in a single invocation. The deeper CostBudget integration is
a follow-up — see TNS-291 issue body.
- Since:
- 0.10.0 (TNS-291)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionexecute(PipelineContext ctx) Execute the stage.id()Stable id, e.g.
-
Constructor Details
-
ProcessStage
public ProcessStage()
-
-
Method Details
-
id
Description copied from interface:PipelineStageStable id, e.g."scan","process".- Specified by:
idin interfacePipelineStage
-
execute
Description copied from interface:PipelineStageExecute the stage. Reads from / writes toctx.stateStore().Stages SHOULD respect
Thread.interrupted()— long-running stages (process, revalidate) check periodically so the pipeline can be cancelled cleanly.- Specified by:
executein interfacePipelineStage
-