Skip to content

docs(arch): DR-011 — retract DR-010's reach-back clause; search becomes query-driven - #59

Merged
ChrisonSimtian merged 1 commit into
mainfrom
docs/dr-011-search-driven-indexing
Jul 27, 2026
Merged

docs(arch): DR-011 — retract DR-010's reach-back clause; search becomes query-driven#59
ChrisonSimtian merged 1 commit into
mainfrom
docs/dr-011-search-driven-indexing

Conversation

@ChrisonSimtian

Copy link
Copy Markdown
Contributor

Answers the question "is reach-back actually the right way, and how do MediathekArr and RundfunkArr solve it?" — by checking, rather than reasoning from first principles. The answer changed the design.

What the comparables do

MediathekArr keeps no catalog. It is a live search proxy: "pretending to be a usenet indexer, but actually just fetching and parsing search results from MediathekViewWeb". TVDB supplies metadata; the effort goes into an "advanced filter and matching system" to survive "the horrendous lack of consistency and metadata in ARD/ZDF Mediatheken".

RundfunkArr uses curated configuration: data/shows.json (tvdbId, german name, aliases, episodes) plus data/rulesets.json (Mediathek topic, duration filters, season/episode regex, matching strategy), extended by community pull requests. SQLite is cache and history only.

Neither reads Sonarr's monitored series via the Sonarr API.

Why not

The Newznab contract is pull-by-query. Sonarr already knows what it monitors and issues t=tvsearch&q=…&tvdbid=…&season=&ep= for exactly what it wants. An indexer isn't supposed to know the monitored list — that's the client's job.

And the reason the question arose for us is our own choice, not a property of being an *arr indexer: DR-010 de-emphasised MediathekView in favour of the direct ARD/ZDF APIs. MediathekViewWeb is effectively a complete dump, so MediathekArr gets breadth for free. Our ARD crawler must walk A-Z catalog → show page → episodes → item page, so it has to be told which shows to walk. RundfunkArr has the identical constraint and answers it with human curation.

The work-list problem is self-inflicted by the direct-API decision.

What DR-011 decides

  1. Search is query-driven — resolve on demand, cache, so any show works without pre-registration.
  2. The standing crawl list survives only as RSS-feed input, since RSS-Sync genuinely needs a recent-releases list.
  3. Reach-back is demoted to an optional pre-warm. Nothing may depend on a configured *arr instance to function.
  4. Matching is where the effort belongs — that's where both comparables concentrate.

Reach-back was also insufficient on its own: an interactive search for a show that's unmonitored, or monitored but not yet crawled, returns nothing. A query-driven path was needed regardless — which demotes reach-back by definition.

Consequences

Honest about the evidence

Recorded in the DR rather than glossed:

  • MediathekArr's README does not explicitly state live-versus-cached. "Fetching and parsing search results" strongly implies live, but it's an inference.
  • Neither project documents RSS feed support — which is precisely the half that still needs a standing crawl. Our RSS design can't be copied from either and has to be reasoned out.

Document handling

DR-010's clause is struck through in place, not deleted, with a blockquote explaining the retraction — the history is worth keeping readable. Its header and the DR index record it. CLAUDE.md stated the retracted claim as fact and is corrected.

Backlog changes

#6 Re-scoped from "the crawl work-list" to optional pre-warm; no longer blocks #12
#58 New — query-driven search, incl. negative caching, timeouts and outbound rate-limiting
#49 On hold. Its SharpCompress advisory was already fixed by a version bump in #53, and the filmliste turns out to be the only full-catalog source available — exactly what MediathekArr depends on. Deleting it would remove our fallback if per-show crawling proves too narrow.

Docs only — no code, no test changes.

🤖 Generated with Claude Code

…ery-driven

DR-010 stated that polling each Sonarr/Radarr instance for its monitored series
"is the crawl work-list". That made the monitored list load-bearing: #6 was scoped
as the work-list, #12 was blocked behind it, and #4/#48 became prerequisites for
basic indexing. Before building it, checked how the comparable projects solve the
same problem.

Neither does it this way:

- MediathekArr keeps no catalog at all. It is a live search proxy — "pretending to
  be a usenet indexer, but actually just fetching and parsing search results from
  MediathekViewWeb", with TVDB for metadata and the real effort in matching.
- RundfunkArr uses curated configuration: data/shows.json plus data/rulesets.json
  (Mediathek topic, filters, season/episode regex), extended by community PRs.

Neither reads Sonarr's monitored series via the Sonarr API, because the Newznab
contract is pull-by-query: Sonarr already knows what it monitors and asks for
exactly what it wants. An indexer is not supposed to know the monitored list.

The reason the question arose for us is our own choice, not a property of being an
*arr indexer: DR-010 de-emphasised MediathekView in favour of the direct ARD/ZDF
APIs. MediathekViewWeb is effectively a complete dump, so MediathekArr gets breadth
free; our ARD crawler must walk A-Z catalog -> show page -> episodes -> item page and
therefore has to be told which shows to walk. The work-list problem is self-inflicted
by the direct-API decision.

DR-011 accordingly:
- Search becomes query-driven (resolve on demand, cache), so any show works without
  pre-registration.
- The standing crawl list survives only as RSS-feed input, since RSS-Sync genuinely
  needs a recent-releases list.
- Reach-back is demoted to an optional pre-warm. Nothing may depend on a configured
  *arr instance to function.
- Matching (EpisodeNumbering, SeriesType, the unset Show.TvdbId) is where the effort
  belongs, since that is where both comparables concentrate.

Reach-back was also insufficient on its own: an interactive search for a show that is
unmonitored, or monitored but not yet crawled, returns nothing — so a query-driven
path was needed regardless, which demotes reach-back by definition.

DR-010's clause is struck through in place rather than deleted, so the history stays
readable, and its header records the retraction. CLAUDE.md stated the retracted claim
as fact and is corrected.

Recorded honestly in the DR: MediathekArr's README does not explicitly say
live-versus-cached (inferred), and neither project documents RSS support — which is
exactly the half that still needs a standing crawl, so our RSS design cannot be copied
from either.

Backlog: #6 re-scoped to an optional pre-warm and unblocked from #12; #58 opened for
query-driven search; #49 (delete MediathekView) put on hold — its SharpCompress
advisory was already fixed by a version bump in #53, and the filmliste is the only
full-catalog source available, which is precisely what MediathekArr depends on.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@ChrisonSimtian
ChrisonSimtian merged commit 922c13c into main Jul 27, 2026
1 check passed
@ChrisonSimtian
ChrisonSimtian deleted the docs/dr-011-search-driven-indexing branch July 27, 2026 22:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant