A web scraper is reliable when its failure rate stays visible, its retries are bounded and polite, and its broken sources surface as alerts rather than quiet gaps in the data. Buyers too often judge reliability by whether the bot runs day to day, but the real questions are: which failures the system treats as temporary, which it treats as permanent, how often it retries each class, and what quality failures such as weak ocr extraction do to the record count. This article opens with a specification table that assigns a treatment to each failure class, then works through the two specs that decide whether a scraper will hold up over months of operation: the health-check and detection spec, and the bounded retry spec. All failure-rate figures below are planning assumptions for a commercial project, to be measured on the buyer’s own sources during the pilot rather than treated as industry benchmarks.
The failure-class table a vendor should specify
Every request can end in one of several outcomes, and the scraper should label each one instead of lumping all errors into a generic “failed” bucket. The table below shows the classes, the typical signals, the recommended retry logic, and the follow-up action after retries are exhausted.
| Failure class | Typical signal | Retry treatment | After exhaustion |
|---|---|---|---|
| Network or connection drop | Timeout, connection reset, partial response | Up to 3 attempts with growing backoff | Queued for next cycle; alert if source keeps dropping |
| Source overload or temporary error | 503, 429, slow response above threshold | Backoff scaled to the source’s own pacing; respect any delay signaled | Pause source briefly; record failure rate per source |
| Permanent missing item | 404, expired listing, removed page | No retry; record as missing | Move record to closed or expired state |
| Access refusal | 401, 403, login-gated page | No automatic retry; flag for review | Confirm whether source terms or login scope changed |
| Parser breakage | Page fetched but required fields empty or malformed | One re-fetch to rule out a truncated page | Alert with sample URL; mark source for selector repair |
| Quality failure in OCR | Scanned document returned with low-confidence fields | Re-run OCR once with adjusted settings | Route to human review; do not write a low-confidence record into production data |
| Duplicate or partial record | Repeated key, truncated fields, split across pages | Deduplicate against existing key | Keep one canonical record; log the merge |
Separating these classes matters because retries behave differently for each. Retrying a dropped connection is usually worthwhile; retrying a 404 or a logged refusal repeats a request that will not succeed and adds unnecessary load on the source. Retrying a parser breakage rarely helps unless the first fetch was truncated, so the system should detect the breakage and raise an alert rather than loop. A vendor whose retry code treats every non-success the same way has not built this classification, and the buyer will see it as either excessive repeated traffic or missed recovery.
Spec one: per-source health detection before retries mean anything
Retries cannot be judged without a baseline showing what a healthy source looks like. The detection spec should record, per source, the expected pages per cycle, the expected fill rate on required fields, the typical response time, and the share of records that pass validation. Each cycle then compares the current run against that baseline: a source that suddenly delivers half the expected pages, or that returns pages with most required fields empty, has broken even if every HTTP response looks acceptable. Health signals should be stored per source and per day, so that a slow degradation over weeks can be spotted instead of attributed to a one-off bad run.
A dead-man’s-switch check belongs in this spec: an independent alert that fires when the scheduler stops producing records at all, not only when a source returns an error. A stopped scheduler looks quiet from inside the system, and without this check the buyer may discover the gap days later through a missing report. The spec should define how alerts are routed, what information each alert carries—source, cycle, failure count, sample URL—and how long a source must be unhealthy before it is paused rather than watched. Validation rules that accept a record into production are part of the same detection layer; the pipeline covered in validation pipelines for extracted data describes how field checks, type rules, and cross-field consistency sit between raw fetch and the stored record.
For scanned and document sources, detection has an extra layer: ocr extraction confidence. Each recognized field should carry a confidence score, and the spec should set a threshold below which the record is held for review rather than accepted. The threshold should be measured on a real document sample—50 pages from the buyer’s own corpus—so the number reflects the actual document quality instead of a generic setting. The document-side reliability details are worked through in PDF and scanned-document extraction bots, and the confidence threshold agreed there should match the threshold used in the scraper’s health report.
Spec two: bounded, paced retries with a failure budget
The retry spec answers four questions per source: how many attempts are allowed, how long the waits between attempts are, what happens while the source is failing, and how failure budget resets. A common planning default for public-page collection is three attempts maximum, with waits of roughly one, two, and four minutes between them, and backoff that grows instead of repeating at a fixed interval. The numbers should be adjusted to the source’s behavior: a slow-responding source may need longer waits; a source that signals a preferred delay should have that delay honored. No retry should run indefinitely, and no retry schedule should keep a failed source looping through the whole cycle.
The failure budget complements the retry count. For each source, define a share of failed pages above which the source is paused for the cycle, and a consecutive-failure count above which an engineer is alerted. For example, if more than 20 percent of a source’s expected pages fail in one cycle, or the source fails three cycles in a row, the system pauses collection and raises an alert rather than continuing to retry through the budget. The budget prevents a broken source from consuming worker capacity and degrading the other sources sharing the queue. After the source is repaired and a test run passes, the budget resets; the repair history should be logged so the buyer can see how often each source actually breaks.
State must survive a restart. Retry queues, processed keys, and in-flight records should be stored so that a redeploy, a machine reboot, or a database restart does not cause the pipeline to re-fetch everything or drop pending retries. Buyers should ask to see the restart behavior in a test: stop the scheduler mid-cycle, restart it, and confirm pending work resumes without duplicates and without lost records. Session and cookie handling that supports polite access is another reliability factor; the security and state questions around it are covered in scraper bot security for cookies and sessions, and the two specs should be reviewed together so that retries do not reuse expired or mishandled session state.
How failure rates should be reported after the pilot
Reliability reporting should break the numbers down by source and by failure class, not as one overall percentage. A useful weekly report lists pages attempted, records accepted, records held for review, parser failures, OCR low-confidence share, access refusals, and missing items, per source. The acceptance rate for required fields should be shown separately from the fetch success rate, because a page can download cleanly and still extract badly. A target such as a 95 percent required-field fill rate on a sample of 50 records per source is a planning acceptance bar, not a universal standard; the buyer should set it against the quality the downstream system actually needs.
Trends matter more than a single good week. A source whose parser failure rate climbs from 2 percent to 8 percent over six weeks is approaching a redesign even before it fully breaks, and early repair costs a fraction of a full selector rebuild. The report should also show retry effectiveness: how many failures recovered on the second or third attempt, and how many exhausted the budget. If retries rarely recover anything, the initial retry configuration is probably aimed at the wrong failure class; if retries recover a large share, the source’s main problem is transient overload, which pacing may solve more cheaply than more retries.
Records held for review need their own metrics too. A rising review queue means the extraction quality threshold is doing its job, but it also signals that the manual backlog is becoming a recurring cost that belongs in the maintenance budget. The weekly report should list how many review items aged past a defined window, so that a growing backlog becomes visible before it delays the downstream reports that depend on the cleaned data.
What to check in the vendor’s proposal before build
Ask the vendor to provide the failure-class table above for the buyer’s actual sources, with the retry count, backoff waits, pause threshold, and alert route filled in per source. Request the per-source health baseline the system will compare against, the OCR confidence threshold and the sample it was measured on, and the restart test that proves state survives. Ask what the weekly reliability report contains and who receives it, and what the retainer response time is when a source breaks past its budget. A team that can produce these specifics has thought about reliability as an operating problem; a team that promises “high availability” without per-source failure numbers has not, and the first long outage will show which version was actually built.
Leave a Reply