Engineering

Write your event software as if the network will fail, because it will

Offline-first is not a feature you add. It is an architectural decision that has to be made before the first line of code.

6 min read

Hero art direction: Engineer's desk at night, two monitors angled away, notebook with a hand-drawn box-and-arrow diagram, cold chai.

The venue network is the least reliable thing in the room

Not because venues are careless, but because a hall filling with two thousand phones is a genuinely hostile radio environment, and the access points were specified for a different room layout by someone who left three years ago.

Plan for degradation as the normal state and full connectivity as a bonus.

What offline-first actually means

It is not caching. Caching makes a connected app faster. Offline-first means the application is correct with no network at all, and treats connectivity as an optimisation.

Concretely:

The read path is local. The delegate list, the session grid, the access rules — all present on the device before doors open. A scan validates against local data in milliseconds.

The write path is a local queue. A check-in writes to local storage and returns immediately. A background worker drains the queue when a link exists.

Conflicts have a defined resolution. Two counters check in the same delegate: first write wins, second is flagged to an exception desk with both timestamps. Decided in advance, not by whichever request happened to arrive second.

The UI tells the truth. A visible indicator showing connected, syncing, or queued with a count. Staff handle a known degraded state well; they handle an ambiguous one badly.

Retrofitting this is expensive

An application built assuming a request-response cycle cannot be made offline-first by adding a service worker. The data model, the conflict rules and the UI states all change.

This is why it belongs in the first architectural conversation, and why "we will add offline support later" usually means "we will rewrite this later".

What genuinely needs the network

Being honest about this shortens the list:

  • Payment authorisation, where a value is at stake
  • Sending an email or SMS
  • Anything reading a system you do not control

Everything else on the check-in path can be local. Notably, this includes badge validation, which is the operation people assume must be remote and is the one that most needs not to be.

Bring your own network for the critical path

Where the operation genuinely cannot tolerate degradation, do not use the venue's network at all. A small dedicated wireless network for registration devices — a few access points, one switch, one router with bonded cellular — is a modest line item and removes an entire class of failure.

Leave the venue Wi-Fi to delegates, where it belongs, and where its failure is an inconvenience rather than an incident.

Test the failure, not the success

The single most useful test: turn the network off, run the full check-in flow for twenty delegates, turn it back on, and verify all twenty synced exactly once.

Then do it again with the app already open, and again after a device restart. Those three paths behave differently and only the first one gets tested by accident.

An engineer's desk at night, two monitors angled away, a notebook open at a hand-drawn box-and-arrow diagram.

Questions we get

Follow-ups

01Does offline-first work for a delegate-facing mobile app?

For the agenda, personal schedule and venue map, yes, and it should — those are exactly what a delegate opens in a basement hall with no signal. Live features like polls and messaging need connectivity by nature, and should degrade visibly rather than hang.

02How much data can we realistically hold on a device?

A delegate list of 10,000 records with the fields needed for check-in is a few megabytes — trivial. The constraint is not storage, it is the initial sync time and keeping it current as late registrations arrive. Sync at the start of each shift rather than continuously.

03What about security if the list is on the device?

Encrypt at rest, scope the local dataset to what that device needs, and be able to revoke a device remotely. A lost tablet with a full delegate list is a breach; a lost tablet with an encrypted, revocable, scoped subset is an inconvenience and a replacement cost.

Talk to the team that runs this on the floor

Send the date, the city and the headcount. We reply with numbers.

Was this useful?