Documentation
¶
Overview ¶
Package resultframe extracts one exact, integrity-bound runner result from an acceptance Pod's log. It reuses the production parser, so an acceptance row cannot accept a frame the controller would reject. Legacy acceptance Jobs use this parser; durable Jobs are read from result storage.
Index ¶
Constants ¶
const ( // MaxLogBytes bounds a log the parser reads: the largest frame the runner // writes, and a megabyte of output before it. MaxLogBytes = runner.DefaultMaxFrameBytes + 1<<20 )
Variables ¶
This section is empty.
Functions ¶
func Parse ¶
Parse reads the one frame the log must hold. It separates the two answers a caller that can read the log again has to decide between, because one sentence covering both is a refusal such a caller cannot act on.
Fewer markers than a closed frame carries is a log read while the runner's last write was still being copied into it: the frame may still be arriving, and reading again can produce it. Nothing is decided here for that case. runner.ParseResultWithOptions already separates a header that has not finished, a payload short of the length its header declares and a payload with no footer from a frame that is present and malformed, and it names each. Answering all of them with a sentence of this package's own is what hid them: the callers that read a transport again do so only for the parser's own incomplete reasons, so from #155 until this was split, a log that was still arriving was refused on its first read and the bounded wait never ran for the case it was written for.
More than one header or footer is the other answer. The log is all there and holds more than the one frame this package extracts -- the production parser returns the last valid frame it finds, so it would accept a log carrying two -- and no later read can reduce them. That refusal says so, in words no caller mistakes for a reason to wait.
func StillArriving ¶
StillArriving reports whether err is a refusal a later read of the same log can turn into a frame.
Types ¶
This section is empty.