Caching Strategies for High-Performance, Low-Cost Websites

2025-05-16
Caching Strategies for High-Performance, Low-Cost Websites

This article details the caching techniques used on the author's websites, jasonthorsness.com and hn.unlurker.com. Different approaches are presented for various website types: mostly-static sites utilize content hashing, CDNs, and client-side caching; data-driven dynamic sites combine short-term cache-control headers, backend memory caching, single-instancing, and disk caching; and for authenticated sites, the author suggests prioritizing non-per-user components and leveraging collaborative caching between the browser and server. Through clever caching strategies, the author achieves high performance at a minimal cost, maintaining stability even under heavy traffic.

Read more
Development

Analyzing the Entire Hacker News Dataset with DuckDB

2025-04-30
Analyzing the Entire Hacker News Dataset with DuckDB

The author downloaded the complete Hacker News dataset—a 20GB JSON file containing everything ever posted on the site—and analyzed it using the DuckDB database. The post details the download process and uses SQL queries to calculate 12-week moving averages of the frequency of mentions for specific programming languages (Python, JavaScript, Java, Ruby, Rust). The author praises DuckDB's ease of use and speed, humorously suggesting future possibilities like training LLMs on the dataset.

Read more
Development

DeepSeek R1: Chain-of-Thought Reasoning Model, Free and API Access

2025-01-26
DeepSeek R1: Chain-of-Thought Reasoning Model, Free and API Access

DeepSeek R1 is a new model and service that exposes chain-of-thought reasoning to the user. You can try it for free at chat.deepseek.com, or via an API at platform.deepseek.com (currently significantly cheaper than OpenAI). Alternatively, click 'Judge Me' to see what the model thinks about your user agent, browser capabilities, and IP location headers. If you dare.

Read more