Menu

Our hourly search-engine ping hashes what a page says, because an all-digit hash comes back from Redis as a number
📰

Our hourly search-engine ping hashes what a page says, because an all-digit hash comes back from Redis as a number

DEV Community: redis·Daniel Pertu·3 days ago
#FlDp95yh
#devtoredis#devto#dev#every#hash
Long article (842 words) — no AI summary yet.
Reading 0:00
15s threshold

Munchable's marketing site is a few hundred pages that come out of code, not out of a CMS. The live sitemap lists 523 URLs, and I wanted Bing, Yandex and the other engines that speak IndexNow to hear about a changed page within the hour instead of whenever a crawler wandered past.

The protocol is trivial: one POST with a list of URLs and a key. The interesting part is deciding which URLs go in the list, because the guidance is blunt that re-announcing unchanged pages earns you a 429 and then a reputation. So the job has one rule: submit a URL only when what it says has changed.

Do not hash the HTML

The obvious way to detect a change is to fetch every page and hash the markup. It fails on the first deploy. Next stamps a fresh build id into every page, so all 523 pages look changed after every release, which is exactly the spam pattern the job exists to avoid.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.