How PhotoX scales to millions of images
The shape of the production system behind this prototype, in the order a photo travels.
Sized for the brief
- Photographers
- hundreds → 5 000
- Galleries
- thousands → 250 000
- Images
- millions → 50 M
- Peak upload
- 40 000 files / hour (Comrades day)
- Face search p95
- < 400 ms per event index
- Time to searchable
- < 5 min median
Where things live
- Originals: private object storage (S3-compatible, Cape Town region), never public, signed download links that expire.
- Previews and thumbnails: CDN-fronted bucket, watermark baked in server-side.
- Face embeddings: vector index partitioned per event, encrypted, deletable per athlete.
- Records: PostgreSQL for orders, payouts, campaigns, consent and audit; read replicas for analytics.
- Queues: one job per file per stage, retried with back-off; workers autoscale on queue depth.
Integrations
- PayFast split payments (or Peach / Paystack) with webhooks for paid, failed and refunded.
- Face and OCR: managed vision services first, own models when volume justifies it.
- Email and WhatsApp for order, follow and takedown notifications.
- Accounting export (Xero / Sage) for payout and commission ledgers.
- POPIA tooling: consent register, subject access export, deletion pipeline with proof.