Class FileSystemPipelineStateStore

java.lang.Object
com.tnsai.quality.security.harness.FileSystemPipelineStateStore
All Implemented Interfaces:
PipelineStateStore

public final class FileSystemPipelineStateStore extends Object implements PipelineStateStore
Disk-backed PipelineStateStore (TNS-291 phase 2).

Lays out state as:

 <baseDir>/<projectId>/
 ├── project.json
 ├── files/<path-hash>.json     # one FileRecord per source file
 ├── runs/<run-id>.json         # one entry per stage execution
 └── reports/<name>             # exporter outputs
 

Idempotency / crash-safety:

  • Writes go to &lt;target&gt;.tmp then Files.move(ATOMIC_MOVE) — a partially written file never replaces a good one.
  • Per-path ReentrantLock serialises concurrent writers for the same FileRecord (run-log writes hold a single store-wide lock).
  • The file name is the SHA-256 of the relative path; same path = same file regardless of OS-specific encoding quirks.
Since:
0.10.0 (TNS-291)