▧ Data loading ›   ♧ Project spec ⌄   ☆   ··· ♧   ↗

Optimistic loading refactor

Overview

The product currently has multiple flows where the interface waits for server confirmation before showing new or refreshed data. This creates the perception that core actions are slow, uncertain, or stuck even when backend latency is within acceptable bounds.

At a glance

AreaCurrent user-visible
problem
Proposed optimistic
behavior
Success signal
Ride requestRequest ride is slow to respondShow immediate submitting state, reserve UI state locally, reconcile on server responseFaster perceived confirmation
Live ride updatesDriver map location updates late, ETA refresh is too slow, pickup pin changes update latePredict and smoothly interpolate updates while background refresh continuesFewer visible jumps, fresher UI
Pricing & promosFare estimate updates late, promo code feels delayedApply local estimate immediately, refresh authoritative values in backgroundReduced perceived calculation time
MessagingDriver message looks stuck sendingInsert pending message immediately, reconcile deliveryClear sending feedback
Rating & historyDriver rating takes too long, trip history loads slowlyUpdate local rating and cached history instantlyNo empty loading state

Architecture

UserUserAppAppCacheCacheServerServerTake actionApply optimistic updateRender immediatelySend requestConfirm or correctReconcile stateRender final state

Data model changes

Add support for the following metadata in shared client state:

FieldPurpose
optimisticidentifies provisional entities or values
pendingSincetracks age of in-flight optimistic state
sourcedistinguishes local prediction vs server value
reconciliationStatuspending, confirmed, corrected, failed
lastKnownGoodAthelps stale-while-revalidate decisions
retryTokensupports idempotent retry for sensitive mutations

Success metrics

  • Median perceived response time for key actions decreases significantly
  • Fewer loading spinners and blank states on primary ride flows
  • Higher completion rate for request, cancel, message, and rating flows
  • Lower user-reported confusion around whether an action succeeded
  • Reduced visible tab flicker and stale content complaints

Instrumentation

Track:

  • time to first visible feedback after user action
  • time spent in pending optimistic state
  • reconciliation mismatch rate
  • rollback/error rate by flow
  • number of blank-state renders on targeted screens
  • number of tab transitions served from cache/prefetch

Risks and mitigations

RiskImpactMitigation
Optimistic state is wrongTemporary inconsistencyBackground reconciliation
Server request failsState needs rollbackRestore previous values with clear feedback
Ask Linear ⤢   ×
Find issues with loading performance
I found 13 bug issues matching syncing errors. The most
relevant active ones are in review or in progress.
▂▅▇ENG-1139Driver rating takes too long to s…
···ENG-1691Trip summary appears blank b…
···ENG-1020Driver message looks stuck se…
▂▅▇ENG-1081Ride and Delivery tab switch is…
···ENG-1123Request ride slow to respond
···ENG-1181Driver map location updates late
▂▅▇ENG-1219Cancel ride confirmation is slow
···ENG-1262ETA refresh is too slow
···ENG-1316Fare estimate updates late
▂▅▇ENG-1428Trip history loads slowly
⊕   Show 3 more issues
Make a plan to refactor data
loading to be optimistic
I created the PRD around the issues you surfaced.
Optimistic loading refactor
A plan to improve perceived app performance by implementing optimistic UI updates and background reconciliation across core ride flows.
What can I help with next?
Ask Linear…
◌@↑
Ask Linear ⤢   ×
Find issues with loading performance
I found 13 bug issues matching syncing errors. The most
relevant active ones are in review or in progress.
▂▅▇ENG-1139Driver rating takes too long to s…
···ENG-1691Trip summary appears blank b…
···ENG-1020Driver message looks stuck se…
▂▅▇ENG-1081Ride and Delivery tab switch is…
···ENG-1123Request ride slow to respond
···ENG-1181Driver map location updates late
▂▅▇ENG-1219Cancel ride confirmation is slow
···ENG-1262ETA refresh is too slow
···ENG-1316Fare estimate updates late
▂▅▇ENG-1428Trip history loads slowly
⊕   Show 3 more issues
Make a plan to refactor data
loading to be optimistic
I created the PRD around the issues you surfaced.
Optimistic loading refactor
A plan to improve perceived app performance by implementing optimistic UI updates and background reconciliation across core ride flows.
What can I help with next?
Ask Linear…
◌@↑
Ask Linear ⤢   ×
Find issues with loading performance
I found 13 bug issues matching syncing errors. The most
relevant active ones are in review or in progress.
▂▅▇ENG-1139Driver rating takes too long to s…
···ENG-1691Trip summary appears blank b…
···ENG-1020Driver message looks stuck se…
▂▅▇ENG-1081Ride and Delivery tab switch is…
···ENG-1123Request ride slow to respond
···ENG-1181Driver map location updates late
▂▅▇ENG-1219Cancel ride confirmation is slow
···ENG-1262ETA refresh is too slow
···ENG-1316Fare estimate updates late
▂▅▇ENG-1428Trip history loads slowly
⊕   Show 3 more issues
Make a plan to refactor data
loading to be optimistic
I created the PRD around the issues you surfaced.
Optimistic loading refactor
A plan to improve perceived app performance by implementing optimistic UI updates and background reconciliation across core ride flows.
What can I help with next?
Ask Linear…
◌@↑
▧ Data loading ›   ♧ Project spec ⌄   ☆   ··· ♧   ↗

Optimistic loading refactor

Overview

The product currently has multiple flows where the interface waits for server confirmation before showing new or refreshed data. This creates the perception that core actions are slow, uncertain, or stuck even when backend latency is within acceptable bounds.

At a glance

AreaCurrent user-visible
problem
Proposed optimistic
behavior
Success signal
Ride requestRequest ride is slow to respondShow immediate submitting state, reserve UI state locally, reconcile on server responseFaster perceived confirmation
Live ride updatesDriver map location updates late, ETA refresh is too slow, pickup pin changes update latePredict and smoothly interpolate updates while background refresh continuesFewer visible jumps, fresher UI
Pricing & promosFare estimate updates late, promo code feels delayedApply local estimate immediately, refresh authoritative values in backgroundReduced perceived calculation time
MessagingDriver message looks stuck sendingInsert pending message immediately, reconcile deliveryClear sending feedback
Rating & historyDriver rating takes too long, trip history loads slowlyUpdate local rating and cached history instantlyNo empty loading state

Architecture

UserUserAppAppCacheCacheServerServerTake actionApply optimistic updateRender immediatelySend requestConfirm or correctReconcile stateRender final state

Data model changes

Add support for the following metadata in shared client state:

FieldPurpose
optimisticidentifies provisional entities or values
pendingSincetracks age of in-flight optimistic state
sourcedistinguishes local prediction vs server value
reconciliationStatuspending, confirmed, corrected, failed
lastKnownGoodAthelps stale-while-revalidate decisions
retryTokensupports idempotent retry for sensitive mutations

Success metrics

  • Median perceived response time for key actions decreases significantly
  • Fewer loading spinners and blank states on primary ride flows
  • Higher completion rate for request, cancel, message, and rating flows
  • Lower user-reported confusion around whether an action succeeded
  • Reduced visible tab flicker and stale content complaints

Instrumentation

Track:

  • time to first visible feedback after user action
  • time spent in pending optimistic state
  • reconciliation mismatch rate
  • rollback/error rate by flow
  • number of blank-state renders on targeted screens
  • number of tab transitions served from cache/prefetch

Risks and mitigations

RiskImpactMitigation
Optimistic state is wrongTemporary inconsistencyBackground reconciliation
Server request failsState needs rollbackRestore previous values with clear feedback

Architecture

UserUserAppAppCacheCacheServerServerTake actionApply optimistic updateRender immediatelySend requestConfirm or correctReconcile stateRender final state
▧ Data loading ›   ♧ Project spec ⌄   ☆   ··· ♧   ↗

Optimistic loading refactor

Overview

The product currently has multiple flows where the interface waits for server confirmation before showing new or refreshed data. This creates the perception that core actions are slow, uncertain, or stuck even when backend latency is within acceptable bounds.

At a glance

AreaCurrent user-visible
problem
Proposed optimistic
behavior
Success signal
Ride requestRequest ride is slow to respondShow immediate submitting state, reserve UI state locally, reconcile on server responseFaster perceived confirmation
Live ride updatesDriver map location updates late, ETA refresh is too slow, pickup pin changes update latePredict and smoothly interpolate updates while background refresh continuesFewer visible jumps, fresher UI
Pricing & promosFare estimate updates late, promo code feels delayedApply local estimate immediately, refresh authoritative values in backgroundReduced perceived calculation time
MessagingDriver message looks stuck sendingInsert pending message immediately, reconcile deliveryClear sending feedback
Rating & historyDriver rating takes too long, trip history loads slowlyUpdate local rating and cached history instantlyNo empty loading state

Architecture

UserUserAppAppCacheCacheServerServerTake actionApply optimistic updateRender immediatelySend requestConfirm or correctReconcile stateRender final state

Data model changes

Add support for the following metadata in shared client state:

FieldPurpose
optimisticidentifies provisional entities or values
pendingSincetracks age of in-flight optimistic state
sourcedistinguishes local prediction vs server value
reconciliationStatuspending, confirmed, corrected, failed
lastKnownGoodAthelps stale-while-revalidate decisions
retryTokensupports idempotent retry for sensitive mutations

Success metrics

  • Median perceived response time for key actions decreases significantly
  • Fewer loading spinners and blank states on primary ride flows
  • Higher completion rate for request, cancel, message, and rating flows
  • Lower user-reported confusion around whether an action succeeded
  • Reduced visible tab flicker and stale content complaints

Instrumentation

Track:

  • time to first visible feedback after user action
  • time spent in pending optimistic state
  • reconciliation mismatch rate
  • rollback/error rate by flow
  • number of blank-state renders on targeted screens
  • number of tab transitions served from cache/prefetch

Risks and mitigations

RiskImpactMitigation
Optimistic state is wrongTemporary inconsistencyBackground reconciliation
Server request failsState needs rollbackRestore previous values with clear feedback
Ask Linear ⤢   ×
Find issues with loading performance
I found 13 bug issues matching syncing errors. The most
relevant active ones are in review or in progress.
▂▅▇ENG-1139Driver rating takes too long to s…
···ENG-1691Trip summary appears blank b…
···ENG-1020Driver message looks stuck se…
▂▅▇ENG-1081Ride and Delivery tab switch is…
···ENG-1123Request ride slow to respond
···ENG-1181Driver map location updates late
▂▅▇ENG-1219Cancel ride confirmation is slow
···ENG-1262ETA refresh is too slow
···ENG-1316Fare estimate updates late
▂▅▇ENG-1428Trip history loads slowly
⊕   Show 3 more issues
Make a plan to refactor data
loading to be optimistic
I created the PRD around the issues you surfaced.
Optimistic loading refactor
A plan to improve perceived app performance by implementing optimistic UI updates and background reconciliation across core ride flows.
What can I help with next?
Ask Linear…
◌@↑
Ask Linear ⤢   ×
Find issues with loading performance
I found 13 bug issues matching syncing errors. The most
relevant active ones are in review or in progress.
▂▅▇ENG-1139Driver rating takes too long to s…
···ENG-1691Trip summary appears blank b…
···ENG-1020Driver message looks stuck se…
▂▅▇ENG-1081Ride and Delivery tab switch is…
···ENG-1123Request ride slow to respond
···ENG-1181Driver map location updates late
▂▅▇ENG-1219Cancel ride confirmation is slow
···ENG-1262ETA refresh is too slow
···ENG-1316Fare estimate updates late
▂▅▇ENG-1428Trip history loads slowly
⊕   Show 3 more issues
Make a plan to refactor data
loading to be optimistic
I created the PRD around the issues you surfaced.
Optimistic loading refactor
A plan to improve perceived app performance by implementing optimistic UI updates and background reconciliation across core ride flows.
What can I help with next?
Ask Linear…
◌@↑
Linear. At your command.