Skip to main content

Crate rget

Crate rget 

Source
Expand description

rget — a resumable, parallel HTTP download manager.

The crate is split so that each concern can be tested on its own:

moduleresponsibility
cliargument parsing, command dispatch
configuser settings and the first-run download-folder prompt
httprequests, redirects, metadata probing, range requests
engineorchestration: probe → plan → transfer → verify
schedulerrange planning, worker assignment, dynamic splitting
workerone range transfer at a time
storageSQLite persistence
[file]random-access writes, preallocation
resumerecovery, reconciliation, remote validation
retryretry policy and backoff
integritychecksums
progresstelemetry model, speed and ETA maths
uiterminal rendering
mirrormirror equivalence and source selection
namingdestination filename selection and sanitisation
limitglobal bandwidth limiting

The one design document worth reading before changing anything: docs/CRASH_CONSISTENCY.md.

Modules§

cli
Argument parsing and command dispatch (PRD §37).
config
User settings, and the first-run download-folder prompt.
engine
Download orchestration.
error
Transfer-level errors, classified by whether retrying could possibly help.
file
Random-access destination file (PRD §9).
fmt
Human-facing formatting and the minimal ANSI styling we need.
http
HTTP client, metadata probing and range requests (PRD §6).
integrity
Checksum verification (PRD §16).
limit
Global bandwidth limiting (PRD §23).
mirror
Mirrors and source selection (PRD §15).
naming
Destination filename selection and sanitisation.
progress
Progress telemetry (PRD §17, §18).
resume
Resume: remote validation and state reconciliation (PRD §12, §13).
retry
Exponential backoff with jitter (PRD §14).
scheduler
Byte-range planning and worker assignment (PRD §7, §8).
shutdown
Cooperative cancellation (PRD §26).
storage
Central SQLite state store (PRD §10, §11).
ui
Terminal rendering (PRD §19).
worker
One worker transferring one range at a time.