Read the story

Architecture

Turns Monday boards into a dashboard.Cash flow refreshes at 6 AM.

Weekly board exports in Drive and a 6 AM read of the three patient boards become one immutable snapshot in Cloud Storage. The browser pins that snapshot and computes every tab from one metric registry, where a card counts its own drilldown rows.

17 ms

for the multi year Weekly tab, down from about 5.2 seconds

45 of 45

stored snapshot checks the cash flow pace rebuild matched exactly before it shipped

~$460K

of patient value on 25 retreatment cases no lead pointed at, found by fixing the join

18 min

from the finance lead's request in the Feature requests tab to it live, Oct 28

New York --:-- simulated

Next board read
Hybridge Cowork Dashboard Weekly board exports in Drive and a 6 AM read of the three patient boards become one immutable snapshot in Cloud Storage. The browser pins that snapshot and computes every tab from one metric registry, where a card counts its own drilldown rows. Cloud Scheduler check every 5 minutes OIDC Google IAP 9 granted accounts Monday boards Leads + 3 patient boards cowork-ingest Cloud Run, private Snapshot bucket Cloud Storage, immutable cowork-web Cloud Run, streams data Dashboard 9 tabs, math in browser Drive folder 4 weekly exports Launchpad relay feature requests Core package one metric registry API, 6 AM weekly export 4 xlsx GET /tasks/check pointer last stream 1 snapshot signed in ID token computes Refresh now GCP hybridge-cowork, us-central1

Hover a part to trace what it touches. Click it for its notes.

  • Built by me
  • Managed by Google
  • Outside system
  • Main data path
  • On demand
  • Credentials cross

When it breaks

What each failure does, and what it does not do.

  1. Monday is down at six

    The read throws and nothing publishes. The dashboard keeps the last good boards and the next five minute check tries again.

    packages/ingest/src/ingest.ts:240

  2. Exports arrive one at a time

    Nothing rebuilds until all four files have changed. A half dropped set never reaches the page.

    packages/ingest/src/ingest.ts:131

  3. A refresh lands mid read

    The daily read publishes only onto the pointer it started from. If a Refresh now published first, the daily read steps aside.

    packages/ingest/src/ingest.ts:261

What I tuned

Small choices that keep it fast and cheap.

  1. Ask Monday for less

    The read asks only for the columns the dashboard uses. Every column took 104 seconds across the three boards. This takes about 45.

    packages/ingest/src/monday.ts:10

  2. Sorted date indexes

    Every tab computes in the browser against sorted date indexes. The multi year Weekly tab went from about 5.2 seconds to about 17 milliseconds.

    README.md

  3. Read the history once

    The pace reads each board's full activity log once, about two minutes, and caches it. Each daily read then fetches two days, about a second.

    packages/ingest/src/history.ts:5

Guards

Rules the code enforces, not rules people remember.

  1. The card counts its rows

    Each metric is defined once and the card number is computed from its drilldown rows. A test checks that for every metric across ranges and locations.

    packages/core/test/metrics.test.ts:59

  2. Figures from production

    A golden test asserts numbers read off the running old dashboard. It caught a one day shift on 948 dates that the parity test missed.

    packages/core/test/golden.test.ts:103

  3. Only the signed header

    The person comes from the header IAP signs, checked against Google's keys and this service's audience. The unsigned email header is never read.

    packages/web/src/iap.ts:71