pub enum Event<PullError, PushError> {
Pulling(WorkerId),
PullError(WorkerId, PullError),
PullTimeout(WorkerId),
PullProgress(WorkerId, ProgressEntry),
Pushing(WorkerId, ProgressEntry),
PushError(WorkerId, ProgressEntry, PushError),
PushProgress(ProgressEntry),
Flushing,
FlushError(PushError),
Finished(WorkerId),
}Expand description
Events emitted during a download session, received via DownloadResult::event_chain.
Each variant records a state change: pulling, pushing, progress, errors, or completion.
Deliberately not #[non_exhaustive]: fast-down’s forwarding layer
matches it exhaustively, so a new variant forces that layer to be updated
rather than letting the event be dropped silently.
Variants§
Pulling(WorkerId)
A worker started fetching its assigned range (carries its id).
PullError(WorkerId, PullError)
A worker failed to fetch its range.
PullTimeout(WorkerId)
A worker’s fetch exceeded its time budget and was aborted.
PullProgress(WorkerId, ProgressEntry)
A worker pulled a range into memory (not yet written).
Pushing(WorkerId, ProgressEntry)
A worker is handing a pulled range to the sink.
PushError(WorkerId, ProgressEntry, PushError)
A worker failed to write a range to the sink.
PushProgress(ProgressEntry)
A range was successfully written to the sink.
Flushing
The sink is being flushed.
FlushError(PushError)
Flushing the sink failed.
Finished(WorkerId)
A worker completed its assigned range and exited.