Class TerminalDocCapture
java.lang.Object
ai.pipestream.module.pipelineprobe.pipelinecrawl.TerminalDocCapture
Captures the most recent
PipeDoc that reached the terminal sidecar
node, keyed by account. The terminal's input IS the pipeline's final output,
so this is the processed doc after the last step ran.
Used by the single-doc crawl flow to surface the resulting document in the UI ("see the output"). Bounded to one doc per account — fine for the 1000-doc runs too (just the last one), cheap for the single-doc case it's built for.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidRecord the terminal doc foraccountId(overwrites the previous).voidDrop the captured doc foraccountId(called on run cleanup).ai.pipestream.data.v1.PipeDocThe last terminal doc foraccountId, ornullif none.
-
Constructor Details
-
TerminalDocCapture
public TerminalDocCapture()CDI.
-
-
Method Details
-
capture
Record the terminal doc foraccountId(overwrites the previous). No-op ifaccountIdis null/blank ordocis null.- Parameters:
accountId- the account to key the captured doc underdoc- the terminalPipeDocto store for that account
-
last
The last terminal doc foraccountId, ornullif none.- Parameters:
accountId- the account whose captured doc to return- Returns:
- the last captured
PipeDocfor that account, ornullif none was captured (oraccountIdis null)
-
clear
Drop the captured doc foraccountId(called on run cleanup). No-op ifaccountIdis null.- Parameters:
accountId- the account whose captured doc to remove
-