System Design Lab

Advanced · Remember answers so you don't ask twice.

Caching

Reading from memory takes milliseconds; asking a database or an API takes hundreds. A cache trades freshness for speed, and the hard part is deciding how stale is acceptable.

Wiring up the simulator…

Try this

Run each experiment in the simulator above, then tick it off.

Key ideas

Hit, miss, TTL

A hit is served from memory. A miss goes to the source and fills the cache. TTL is how long an entry lives.

Invalidation is the hard part

When the source changes, either wait out the TTL or delete the cached entry yourself.

Cache what's read often and changes rarely

Catalogs, settings, exchange rates. Not account balances.

In your Pabbly workflows

If a workflow looks up the same thing on every run (a price list, a mapping table, a token), fetch it once and keep it in a sheet or variable instead of calling the API each time. Fewer calls, fewer rate-limit errors, fewer tasks.

Check yourself

0/2

Get every question right to mark this lab done. Wrong answers let you try again.

Q1. TTL is…

Q2. The main risk of a long TTL?