Worked Examples
Apply discovery error recovery — Unified Discovery
Recover gracefully from discovery provider errors while preserving source integrity, rights boundaries, transparent failure status, and reproducible query context.
Application: Unified Discovery
Classification: Practical Guides / Discovery Operations / Error Recovery
Cross-application area: Provider Discovery / Library / Research / Platform Operations
Audience: Researchers, research librarians, platform operators, support engineers, data stewards, and integration developers
Technical level: Intermediate to advanced
Reference environment: Python 3.10 or later, standard library only
Relevant specifications: RFC 9110, RFC 6585, RFC 9111, RFC 9457
Primary outputs: Provider failure classification, recovery decision, coverage report, validated results, preserved source provenance, and acceptance receipt
Estimated reading time: 15–19 minutes; approximately 35–45 minutes including exercises
1. Purpose and expected outcome
Unified Discovery may combine information from multiple research repositories, databases, catalogs, institutional services, and external providers. These sources do not always respond successfully or consistently.
Recovery must distinguish a temporary service problem from a source integrity or authorization problem.
The objective is to restore useful, authorized discovery while maintaining an accurate account of what was searched, which providers responded, which records were accepted, and which evidence remains unavailable.
Primary acceptance condition: Provider and record failures must be reported accurately. Incomplete search coverage must never be presented as a complete search.
Successful recovery should preserve source identity, provenance, rights, revisions, uncertainty, and previously accepted research artifacts.
2. Understand the main failure types
| Failure | Possible cause | Initial action |
|---|---|---|
| Provider unavailable | Outage, maintenance, DNS failure, or upstream error | Classify as unavailable; consider bounded retry |
| Rate limited | Provider request quota exceeded | Honor retry guidance and budget |
| Timeout | Slow provider or interrupted connection | Determine operation state; retry only when safe |
| Authentication failure | Missing or expired credentials | Restore authorized authentication |
| Authorization denied | Permission or licensing restriction | Stop; do not bypass restrictions |
| Invalid payload | Malformed JSON, schema drift, or missing required fields | Quarantine invalid record or response |
| Partial provider results | Incomplete pagination or provider failure | Disclose incomplete coverage |
| Stale cached data | Outdated result snapshot or index | Check freshness and reuse policy |
| Source identity mismatch | Incorrect provider mapping or unexpected revision | Reject affected record pending reconciliation |
| Dependent service failure | Library, graph, identity, or indexing dependency unavailable | Identify failing boundary; preserve accepted state |
Failures can occur simultaneously. For example, a provider may return an HTTP 200 response containing malformed records, while another provider times out.
A successful transport response is not sufficient evidence of complete, valid discovery.
3. Establish the discovery context
Before retrying, record the original research and authorization context.
- Authenticated principal and organization.
- Research project or workspace.
- Original search query and normalized query, if applicable.
- Selected and required providers.
- Filters, date ranges, language, and resource types.
- Requested pagination or result limits.
- Search and provider configuration revisions.
- Source and index revisions where available.
- Provider usage rights and authentication scope.
- Request identifier, trace identifier, and actual response state.
Preserve protected research queries and access tokens only in authorized diagnostic systems.
Do not place provider credentials, private search terms, or confidential source records in public support tickets.
4. Distinguish result coverage from successful transport
A federated discovery request may contact several independent providers.
For example:
Requested providers: 4
Provider A: Complete
Provider B: Complete
Provider C: Rate limited
Provider D: Unavailable
Two providers responded successfully, but the complete requested search was not performed.
A valid response may still return useful sources if partial results are permitted by the application.
However, the response must disclose the incomplete coverage.
| Classification | Meaning |
|---|---|
| Complete | All required providers completed the requested scope and their returned data met the applicable validation criteria |
| Partial | At least one provider contributed usable results, but required coverage or validation is incomplete |
| Unavailable | No usable results were obtained from the requested provider set |
| Blocked | Authentication, authorization, policy, or another mandatory gate prevents the requested operation |
Coverage is not scientific completeness. Even a successful search of every selected provider may omit relevant research that those providers do not index.
5. Calculate and communicate provider coverage
A useful operational coverage indicator is:
Completed provider fraction =
Number of fully completed required providers
------------------------------------------------
Number of required providers
For four required providers, of which two completed:
Completed provider fraction = 2 / 4 = 0.50
Expressed as a percentage, this is 50% of required providers completed.
This does not mean that 50% of all relevant scientific evidence was discovered.
Provider coverage is a service-execution measure, not an estimate of recall, source quality, or scientific completeness.
For meaningful operational reporting, also record the number of pages requested and completed, valid records returned, rejected records, and known provider limitations.
6. Respond to rate limits
HTTP 429 indicates that the server considers the client to have made too many requests within an applicable limit.
The provider may supply a Retry-After header.
Examples:
HTTP/1.1 429 Too Many Requests
Retry-After: 120
or:
Retry-After: Wed, 18 Nov 2026 15:00:00 GMT
The value may specify a delay in seconds or an HTTP date, as described in RFC 9110. RFC 6585 defines status 429.
Recovery rules:
- Determine the provider’s applicable rate-limit policy.
- Read and validate
Retry-Afterwhen present. - Do not retry before the indicated time if the operation remains eligible for retry.
- Apply a configured retry-attempt and elapsed-time budget.
- Use backoff and jitter where appropriate to prevent synchronized retries.
- Stop when the budget is exhausted rather than entering an unlimited retry loop.
- Preserve incomplete coverage while waiting for a later attempt.
An unreasonably large or invalid delay should be handled according to a documented policy. Do not silently replace a provider’s longer waiting requirement with an earlier retry.
7. Respond to temporary provider outages
HTTP 503 generally indicates temporary service unavailability. Other transport or gateway failures may also represent temporary conditions.
Recovery should consider:
- Whether the original request is safe to repeat.
- Whether the provider returned an explicit retry time.
- Whether repeated errors suggest an extended outage.
- Whether the provider is optional or required.
- Whether valid results are available from other providers.
- Whether a permitted, correctly labeled cached result can be used.
For large outages, a circuit-breaker design may temporarily suppress requests to the failing provider.
Returning fewer live results is often safer than repeatedly overloading a provider or misrepresenting previously cached results as current.
8. Handle invalid provider data
A provider may return valid HTTP and JSON responses that nevertheless contain unusable source records.
Examples include:
- Missing provider identifiers.
- Unexpected schema revisions.
- Invalid source URLs.
- Missing authoritative source revisions where required.
- Malformed dates or incompatible field types.
- Duplicate source identities.
- Unexpected or missing rights metadata.
- Conflicting source identifiers.
- Unsupported resource types.
Do not treat malformed or incomplete records as verified sources.
A recovery design may quarantine individual invalid records when record-level isolation is safe. Other failures may require rejecting the complete provider response.
Preserve sanitized validation errors and record the provider’s declared schema or contract revision.
Do not silently invent identifiers, scientific metadata, licenses, or missing publication dates to make a record pass validation.
9. Distinguish failed records from failed providers
A provider can complete its search request while returning a mixture of valid and invalid records.
For example:
Provider A
Transport: Success
Search scope: Complete
Returned records: 10
Accepted records: 8
Quarantined records: 2
This should not be reported as ten validated records.
If the project’s completion policy requires every returned record to pass validation, the provider’s overall contribution is not complete.
Where a policy allows record-level exclusions, disclose the exclusions and the resulting coverage classification.
Do not suppress the invalid-record count merely because a provider returned some usable results.
10. Check source identity, rights, and revisions
Recovered results must retain their original source relationships.
Verify:
- Provider identifier.
- Provider record identifier.
- Canonical source reference.
- Source revision.
- Publication and observation timestamps, where available.
- License and use restrictions.
- Content access scope.
- Relevant retrieval and validation timestamps.
Do not silently replace an unavailable historical source with an unrelated or newer source.
A metadata-only record should not be treated as permission to download full content.
Source identity and scientific credibility require independent evaluation even when recovery succeeds.
11. Use cached results carefully
Caching may improve availability during upstream failures, but cached results require clear provenance and freshness handling.
Distinguish:
- The timestamp of the original scientific observation.
- The source publication date.
- The time the provider was queried.
- The time the response was cached.
- The time the cache was validated.
- The time the cached response was displayed.
HTTP caching rules under RFC 9111 govern when cached HTTP responses may be reused, including conditions for serving stale responses.
For research discovery, additional application-level freshness policies may be needed, because an HTTP-fresh response can still refer to older scientific observations.
Do not automatically serve cached private results to a different tenant or identity.
When cached data are legitimately reused, identify them as cached and preserve their source and search context.
12. Define the safe recovery decision
Recovery may choose one of the following outcomes:
| Action | Appropriate situation |
|---|---|
| Accept validated results | Provider completed and data meet acceptance rules |
| Return partial results | Some authorized providers supplied usable records but required coverage is incomplete |
| Schedule an eligible retry | Temporary failure with an acceptable retry time and remaining budget |
| Hold pending provider recovery | Outage or rate-limit delay exceeds the current request’s budget |
| Quarantine invalid records | Record-level data fail schema or integrity validation |
| Block the operation | Authentication, authorization, rights, or mandatory governance gate fails |
| Escalate | Persistent integrity, identity, security, or systemic dependency failure |
These actions are conceptual requirements, not verified current Unified Discovery interface controls.
13. Prepare a synthetic recovery exercise
The reference scenario uses four required providers.
| Provider | Result | Usable records |
|---|---|---|
| A | Complete | 3 |
| B | Complete | 2 |
| C | HTTP 429, rate limited | 0 |
| D | HTTP 503, unavailable | 0 |
Expected interpretation:
Required providers: 4
Completed providers: 2
Usable records: 5
Coverage: PARTIAL
Completed provider fraction: 0.50
This exercise deliberately makes no real network requests and does not modify any research records.
14. Implement a reproducible recovery-policy model
Use Python 3.10 or later.
mkdir discovery-error-recovery
cd discovery-error-recovery
python3 -m venv .venv
source .venv/bin/activate
python --version
Save the following as discovery_recovery.py.
from dataclasses import dataclass
from datetime import datetime, timezone
from email.utils import parsedate_to_datetime
import json
@dataclass(frozen=True)
class ProviderOutcome:
provider: str
http_status: int | None
transport_error: bool = False
complete: bool = False
valid_records: int = 0
invalid_records: int = 0
retry_after: str | None = None
def retry_after_seconds(
value: str | None,
now: datetime
) -> int | None:
if value is None:
return None
value = value.strip()
if value.isascii() and value.isdecimal():
return int(value)
try:
parsed = parsedate_to_datetime(value)
except (TypeError, ValueError, IndexError):
return None
if parsed.tzinfo is None:
return None
seconds = (
parsed.astimezone(timezone.utc)
- now.astimezone(timezone.utc)
).total_seconds()
return max(0, int(seconds + 0.999999))
def classify(outcome: ProviderOutcome) -> str:
if (
outcome.valid_records < 0
or outcome.invalid_records < 0
):
raise ValueError("NEGATIVE_RECORD_COUNT")
if outcome.transport_error:
return "unavailable"
status = outcome.http_status
if status in (401, 403):
return "blocked"
if status == 429:
return "rate_limited"
if status in (500, 502, 503, 504):
return "unavailable"
if status is None or not 200 <= status < 300:
return "failed"
if outcome.invalid_records > 0:
return "invalid_data"
if not outcome.complete:
return "partial"
return "complete"
def retry_decision(
outcome: ProviderOutcome,
now: datetime,
attempts_used: int,
max_attempts: int = 3,
max_wait_seconds: int = 300
) -> dict:
state = classify(outcome)
if state not in ("rate_limited", "unavailable"):
return {
"retry": False,
"reason": "not_transient",
"delay_seconds": None
}
if attempts_used >= max_attempts:
return {
"retry": False,
"reason": "attempt_budget_exhausted",
"delay_seconds": None
}
requested_delay = retry_after_seconds(
outcome.retry_after, now
)
if requested_delay is not None:
if requested_delay > max_wait_seconds:
return {
"retry": False,
"reason": "defer_beyond_request_budget",
"delay_seconds": requested_delay
}
return {
"retry": True,
"reason": "provider_retry_after",
"delay_seconds": requested_delay
}
# Illustrative bounded exponential backoff.
# Production scheduling should also consider
# jitter, shared rate limits, and deadlines.
delay = min(
2 ** max(0, attempts_used),
max_wait_seconds
)
return {
"retry": True,
"reason": "bounded_backoff",
"delay_seconds": delay
}
def coverage_report(
outcomes: list[ProviderOutcome]
) -> dict:
names = [p.provider for p in outcomes]
if not outcomes:
raise ValueError("EMPTY_PROVIDER_SET")
if len(names) != len(set(names)):
raise ValueError("DUPLICATE_PROVIDER")
statuses = {
p.provider: classify(p)
for p in outcomes
}
completed = sum(
state == "complete"
for state in statuses.values()
)
usable = sum(
p.valid_records
for p in outcomes
)
invalid = sum(
p.invalid_records
for p in outcomes
)
blocked = any(
state == "blocked"
for state in statuses.values()
)
if blocked:
overall = "BLOCKED"
elif completed == len(outcomes):
overall = "COMPLETE"
elif usable > 0:
overall = "PARTIAL"
else:
overall = "UNAVAILABLE"
return {
"coverage": overall,
"required_providers": len(outcomes),
"completed_providers": completed,
"completed_fraction": round(
completed / len(outcomes), 4
),
"usable_records": usable,
"invalid_records": invalid,
"provider_statuses": statuses,
"scientific_completeness": "not_assessed"
}
def main():
now = datetime(
2026, 11, 14, 12, 0,
tzinfo=timezone.utc
)
providers = [
ProviderOutcome("A", 200, complete=True,
valid_records=3),
ProviderOutcome("B", 200, complete=True,
valid_records=2),
ProviderOutcome("C", 429,
retry_after="120"),
ProviderOutcome("D", 503)
]
report = {
"classification": "synthetic",
"search": coverage_report(providers),
"provider_C_retry": retry_decision(
providers[2], now, attempts_used=1
),
"provider_D_retry": retry_decision(
providers[3], now, attempts_used=1
),
"actual_provider_calls": 0,
"production_acceptance": "NOT_TESTED"
}
print(json.dumps(report, indent=2))
if __name__ == "__main__":
main()
The example classifies provider responses, determines eligible retry delays, and reports completed coverage separately from usable-record counts.
Important boundaries: It does not validate actual provider payload schemas, verify rights, distinguish all possible authorization policies, execute scheduled retries, perform cache reuse, or communicate with a live discovery backend. It is a recovery-decision model, not a production HTTP client.
The model treats provider-level authentication denial as a blocking condition for the overall requested search. A production system may support more granular optional-provider policies, but any resulting partial coverage must still be disclosed.
15. Run the recovery example
python discovery_recovery.py
Expected primary output:
Coverage: PARTIAL
Required providers: 4
Completed providers: 2
Completed provider fraction: 0.5
Usable records: 5
Invalid records: 0
Provider C: rate_limited
Provider D: unavailable
Scientific completeness: not_assessed
Production acceptance: NOT_TESTED
Provider C’s synthetic Retry-After: 120 produces an eligible 120-second retry delay under the reference budget.
The result does not authorize immediate retry or claim complete scientific coverage.
16. Implement negative and regression tests
Save as test_discovery_recovery.py.
from datetime import datetime, timezone
import unittest
from discovery_recovery import (
ProviderOutcome,
classify,
retry_after_seconds,
retry_decision,
coverage_report
)
NOW = datetime(
2026, 11, 14, 12, 0,
tzinfo=timezone.utc
)
class DiscoveryRecoveryTests(unittest.TestCase):
def test_complete(self):
result = coverage_report([
ProviderOutcome(
"A", 200,
complete=True,
valid_records=3
)
])
self.assertEqual(result["coverage"], "COMPLETE")
def test_partial_coverage(self):
result = coverage_report([
ProviderOutcome(
"A", 200,
complete=True,
valid_records=2
),
ProviderOutcome("B", 503)
])
self.assertEqual(result["coverage"], "PARTIAL")
self.assertEqual(result["completed_fraction"], 0.5)
def test_unavailable(self):
result = coverage_report([
ProviderOutcome("A", 503)
])
self.assertEqual(result["coverage"], "UNAVAILABLE")
def test_authorization_blocks(self):
result = coverage_report([
ProviderOutcome("A", 403)
])
self.assertEqual(result["coverage"], "BLOCKED")
def test_rate_limit_classification(self):
self.assertEqual(
classify(ProviderOutcome("A", 429)),
"rate_limited"
)
def test_invalid_data(self):
self.assertEqual(
classify(ProviderOutcome(
"A", 200,
complete=True,
valid_records=1,
invalid_records=1
)),
"invalid_data"
)
def test_incomplete_pagination(self):
self.assertEqual(
classify(ProviderOutcome(
"A", 200,
complete=False,
valid_records=1
)),
"partial"
)
def test_retry_after_seconds(self):
self.assertEqual(
retry_after_seconds("120", NOW),
120
)
def test_retry_after_http_date(self):
self.assertEqual(
retry_after_seconds(
"Sat, 14 Nov 2026 12:02:00 GMT",
NOW
),
120
)
def test_invalid_retry_after(self):
self.assertIsNone(
retry_after_seconds("not-a-date", NOW)
)
def test_retry_after_exceeds_budget(self):
result = retry_decision(
ProviderOutcome(
"A", 429,
retry_after="3600"
),
NOW,
attempts_used=1
)
self.assertFalse(result["retry"])
self.assertEqual(
result["reason"],
"defer_beyond_request_budget"
)
def test_exhausted_retry_budget(self):
result = retry_decision(
ProviderOutcome("A", 503),
NOW,
attempts_used=3
)
self.assertFalse(result["retry"])
def test_no_retry_on_denial(self):
result = retry_decision(
ProviderOutcome("A", 403),
NOW,
attempts_used=0
)
self.assertFalse(result["retry"])
def test_duplicate_provider(self):
with self.assertRaises(ValueError):
coverage_report([
ProviderOutcome("A", 200),
ProviderOutcome("A", 503)
])
def test_empty_provider_set(self):
with self.assertRaises(ValueError):
coverage_report([])
def test_negative_record_count(self):
with self.assertRaises(ValueError):
classify(ProviderOutcome(
"A", 200,
valid_records=-1
))
if __name__ == "__main__":
unittest.main()
17. Execute the tests
python -m unittest -v test_discovery_recovery.py
The reference suite defines sixteen tests covering complete and partial coverage, unavailable providers, authorization denial, rate limits, invalid records, incomplete pagination, Retry-After parsing, bounded retry behavior, duplicate providers, and malformed count data.
These are reference tests. Their presence does not establish production verification.
Actual deployment acceptance additionally requires real provider adapters, authorization, schema validation, persistence, provider quotas, concurrency, and fault-injection tests.
18. Address partial search results explicitly
When a search is partially successful, provide a concise coverage summary beside the results.
Illustrative user-facing wording:
Partial search results. Two of four requested providers completed successfully. Five usable records were returned. One provider was rate limited and another was unavailable. The results may exclude relevant sources. The complete search has not been verified.
Preserve provider-specific failures rather than replacing them with a generic “no results” message.
Do not claim that a topic has no relevant research when the necessary discovery providers were not fully checked.
19. Prevent unsafe retries and duplicate operations
Search retrieval is typically read-oriented, but recovery may interact with other systems through saved searches, source ingestion, exports, indexing, or publication workflows.
These operations may be mutating.
Before repeating a write:
- Identify the original operation and idempotency key, if supported.
- Determine whether the write committed.
- Read the authoritative object or operation state.
- Check for an existing record or conflicting revision.
- Use only the documented idempotency and retry contract.
- Preserve the original source and audit history.
An uncertain HTTP response must not trigger an uncontrolled duplicate Library import or graph mutation.
For truly read-only provider requests, retry eligibility still depends on the provider’s limits, authorization, and operational policy.
20. Reconcile dependent application state
Discovery failures may affect downstream workflows that depend on the search result.
| Application | Recovery responsibility |
|---|---|
| Unified Discovery | Report provider status, search coverage, valid records, and recovery limitations |
| Library | Preserve authoritative source identities, revisions, rights, and saved artifacts |
| Research Lab | Assess scientific implications of incomplete or invalid evidence |
| Workbench | Preserve reproducible analytical dependencies on accepted source revisions |
| Site Intelligence | Track geographic and observation-provider limitations where relevant |
| Decision Studio | Identify decisions or models affected by incomplete discovery coverage |
| Workspace | Track project incidents, ownership, recovery, and review decisions |
| Research | Prevent unsupported publication claims about incomplete evidence searches |
| Platform Core | Enforce identity, project boundaries, provider permissions, and audit controls |
These are intended architectural responsibilities, not independently verified deployed integrations.
21. Prepare a machine-readable recovery receipt
A recovery receipt should make the original failure and resulting search coverage reconstructable.
{
"schema_version": "example-1.0",
"workflow": "discovery_error_recovery",
"classification": "synthetic",
"query_reference": "synthetic-search-001",
"required_providers": 4,
"completed_providers": 2,
"completed_provider_fraction": 0.5,
"usable_records": 5,
"invalid_records": 0,
"coverage": "PARTIAL",
"providers": [
{
"provider": "A",
"status": "complete"
},
{
"provider": "B",
"status": "complete"
},
{
"provider": "C",
"status": "rate_limited",
"http_status": 429,
"retry_after_seconds": 120
},
{
"provider": "D",
"status": "unavailable",
"http_status": 503
}
],
"acceptance": {
"provider_coverage": "not_tested",
"payload_integrity": "not_tested",
"rights": "not_tested",
"authorization": "not_tested",
"cache_integrity": "not_tested",
"source_provenance": "not_tested",
"retry_policy": "not_tested",
"scientific_completeness": "not_assessed",
"production_runtime": "not_tested"
},
"publication_approval": "not_approved",
"release_decision": "NO_GO"
}
This is an illustrative evidence format, not a verified Sustainable Catalyst API response or database schema.
Replace placeholder values only with actual provider responses, executed tests, and authorized reviewer decisions.
22. Scientific and technical acceptance matrix
| Criterion | Pass condition | Evidence |
|---|---|---|
| Provider classification | Failure causes accurately distinguished | Actual response and error diagnostics |
| Required coverage | All required providers tracked | Provider execution ledger |
| Coverage disclosure | Incomplete searches labeled as partial | API and interface acceptance |
| Rate-limit compliance | Provider retry limits and Retry-After honored | Retry-policy tests |
| Retry bounds | No unlimited retry or cascading request storm | Fault-injection tests |
| Invalid data handling | Malformed or incompatible records excluded or quarantined | Schema negative tests |
| Source identity | Accepted results retain correct provider and source identifiers | Source reconciliation |
| Revision integrity | Source and search revisions remain traceable | Revision evidence |
| Rights | Only permitted research material processed | Rights-policy acceptance |
| Authorization | Provider and research access restrictions enforced | Trusted identity tests |
| Cache handling | Cached results reused only under applicable policy | Cache acceptance |
| Persistence | Accepted artifacts survive expected service and session boundaries | Database and reload tests |
| Idempotency | Recovery does not create unintended duplicate writes | Replay and concurrency tests |
| Scientific interpretation | No unsupported assertion that partial search is scientifically exhaustive | Scientific review |
| Runtime acceptance | Deployed behavior independently verified | Integration and browser evidence |
Acceptance rule: Record applicable criteria as Pass, Fail, Not Tested, or Not Applicable. A recovered user interface does not establish complete discovery if mandatory provider coverage or data-integrity checks remain incomplete.
23. Test production failure scenarios
Once the actual deployment is identified, conduct controlled integration tests using approved provider fixtures and disposable storage.
Required scenarios include:
- One provider returns HTTP 429.
- One provider returns HTTP 503 with Retry-After.
- A provider times out after partial response delivery.
- A provider returns malformed JSON.
- A provider returns a valid response with invalid source records.
- A provider’s schema revision changes.
- Pagination stops before the requested coverage is complete.
- A required provider’s authentication expires.
- A second tenant attempts to access protected cached results.
- A source revision changes during recovery.
- A dependent Library or graph service becomes unavailable.
- An ambiguous write fails after the server commits it.
- A saved partial result is reopened in another authorized session.
- Recovery attempts exceed the configured retry budget.
- A recovery-generated status or error response contains protected information.
Do not generate artificial load against external providers without authorization. Simulate rate limits and outages in isolated test services.
24. Escalation and controlled recovery
Escalate when:
- Provider access restrictions are bypassed.
- Private research or credentials are exposed.
- A partial search is represented as complete.
- Invalid data enter a governed Library or research record.
- Provider identity or source revisions cannot be reconciled.
- Unbounded retries threaten provider or platform stability.
- Recovery creates duplicate or inconsistent research artifacts.
- Published scientific conclusions depend on undisclosed incomplete coverage.
Preserve the last accepted research state and the relevant audit evidence.
Pause affected imports, analytical operations, or publication transitions when required.
Use only approved recovery operations, and do not clear production caches, alter provider credentials, or restore databases without appropriate authorization and tested rollback or forward-recovery procedures.
25. Required implementation audit
Before marking these procedures production verified, inspect:
- Actual Unified Discovery service repository and implementation commit.
- Provider adapter registry and request contracts.
- Timeout, retry, and rate-limit configuration.
- Provider status and coverage-reporting schema.
- Payload validation and quarantine behavior.
- Source identity and metadata normalization.
- Cache keys, freshness, and authorization partitioning.
- Trusted identity and project ownership.
- Search snapshot and persistence behavior.
- Library, graph, and research handoff contracts.
- Idempotency and duplicate-operation protections.
- Actual API errors and structured diagnostic output.
- Executed provider failure-injection and negative tests.
- Authenticated browser acceptance.
- Staging deployment revision and recovery receipts.
- Known unsupported or disabled functionality.
Document exact repository paths, code revisions, API schemas, CI results, runtime observations, and unresolved limitations.
26. Technical references
- Fielding, R., Nottingham, M. and Reschke, J. (2022). HTTP Semantics. RFC 9110. Available at: https://www.rfc-editor.org/rfc/rfc9110.html.
- Nottingham, M. and Fielding, R. (2012). Additional HTTP Status Codes. RFC 6585. Available at: https://www.rfc-editor.org/rfc/rfc6585.html.
- Fielding, R., Nottingham, M. and Reschke, J. (2022). HTTP Caching. RFC 9111. Available at: https://www.rfc-editor.org/rfc/rfc9111.html.
- Nottingham, M., Wilde, E. and Dalal, S. (2023). Problem Details for HTTP APIs. RFC 9457. Available at: https://www.rfc-editor.org/rfc/rfc9457.html.
- World Wide Web Consortium (W3C) (2013). PROV-O: The PROV Ontology. Available at: https://www.w3.org/TR/prov-o/.
- OWASP Foundation (2023). API Security Top 10. Available at: https://owasp.org/API-Security/.
- Python Software Foundation (n.d.). email.utils — Miscellaneous Utilities. Available at: Python documentation.
- Python Software Foundation (n.d.). unittest — Unit Testing Framework. Available at: Python documentation.
- Wilkinson, M.D. et al. (2016). ‘The FAIR Guiding Principles for scientific data management and stewardship’, Scientific Data, 3, 160018. Available at: https://doi.org/10.1038/sdata.2016.18.
27. Completion and verification record
| Field | Required record |
|---|---|
| Recovery identifier | Unique incident or operation reference |
| Original query | Authorized search and filter context |
| Required providers | Expected provider set and versions |
| Provider outcomes | Completed, rate limited, unavailable, invalid, or blocked states |
| Search coverage | Complete, Partial, Unavailable, or Blocked |
| Usable records | Validated result count and identifiers |
| Rejected records | Invalid count, reason, and permitted diagnostic evidence |
| Retry policy | Actual limits, attempts, delays, and decisions |
| Cache status | Source, freshness, and reuse authorization |
| Source provenance | Provider and revision reconciliation |
| Rights and authorization | Pass, Fail, or Not Tested |
| Persistence | Pass, Fail, or Not Tested |
| Idempotency | Pass, Fail, or Not Tested |
| Scientific completeness | Explicit assessment or Not Assessed |
| Root cause | Confirmed finding or unresolved hypothesis |
| Corrective action | Actual authorized recovery operation |
| Runtime acceptance | Executed API and browser verification |
| Reviewer | Responsible reviewer and date |
| Outstanding limitations | Unresolved provider, research, or governance risks |
Completion criterion: Discovery error recovery is accepted when provider outcomes and record validation are accurately classified, retry and authorization policies are respected, usable results preserve their correct source provenance, partial coverage is explicitly disclosed, unsafe mutations are avoided, and the affected operation has passed the applicable runtime and governance acceptance checks.
Scientific limitation: A complete provider search does not necessarily capture all scientifically relevant literature or data, and a recovered search does not establish the credibility, quality, or suitability of its results. Those require separate research appraisal.
Current implementation status: Practical recovery workflow, provider classification model, synthetic coverage example, Retry-After interpretation, bounded retry decisions, sixteen reference regression-test definitions, failure disclosure, safe recovery rules, and proposed acceptance criteria documented. No specific Sustainable Catalyst provider adapter, retry scheduler, cache implementation, federated search API, or production recovery procedure is certified without repository inspection, real integration testing, authenticated runtime evidence, and release approval.
