Class EnrichStage

java.lang.Object
com.tnsai.quality.security.harness.EnrichStage
All Implemented Interfaces:
PipelineStage

public final class EnrichStage extends Object implements PipelineStage
The enrich stage (TNS-291). Walks every ReviewFinding and adds CWE-catalog metadata: human-readable name + the https://cwe.mitre.org/data/definitions/<n>.html reference URL.

Idempotent and side-effect-free except for the metadata mutation — already-enriched findings are skipped.

Since:
0.10.0 (TNS-291)
  • Constructor Details

    • EnrichStage

      public EnrichStage()
  • Method Details

    • id

      public String id()
      Description copied from interface: PipelineStage
      Stable id, e.g. "scan", "process".
      Specified by:
      id in interface PipelineStage
    • execute

      public StageResult execute(PipelineContext ctx)
      Description copied from interface: PipelineStage
      Execute the stage. Reads from / writes to ctx.stateStore().

      Stages SHOULD respect Thread.interrupted() — long-running stages (process, revalidate) check periodically so the pipeline can be cancelled cleanly.

      Specified by:
      execute in interface PipelineStage