Add Discord-hosted preview caching (C11)
This commit is contained in:
@@ -101,8 +101,14 @@ Downloads run after a finished walk when the scrape used `mode: "download"`:
|
||||
(`source != 'embed'`).
|
||||
- Progress counters: `downloaded`, `downloadErrors`.
|
||||
|
||||
Previews are **planned (C11)**: the Discord CDN resizer (`?width=320&height=320&format=webp`) into
|
||||
`thumbs/`, stored by hash, failure never fails the scrape.
|
||||
Previews run after every walk, in both modes:
|
||||
|
||||
- Only Discord-hosted image and GIF URLs (`cdn.discordapp.com`, `media.discordapp.net`) are
|
||||
transformed to the CDN resizer (`media.discordapp.net?...width=320&height=320&format=webp`).
|
||||
Third-party embeds are skipped.
|
||||
- One attempt per row, no retries; a failure marks `preview_error` and never fails the scrape.
|
||||
- Stored by hash in `thumbs/<sha256>.webp`; `preview_hash` and `preview_bytes` land on the row, and
|
||||
the counter is `previewed`. Previews count toward the storage limit.
|
||||
|
||||
## Job states
|
||||
|
||||
|
||||
Reference in New Issue
Block a user