Skip to content

perf(ui): deduplicate refreshes and poll active jobs only [4/5] - #188

Open
Anthony Cintron (prbatero) wants to merge 1 commit into
prbatero/feat/perf-project-details-apifrom
prbatero/feat/perf-project-details-ui
Open

perf(ui): deduplicate refreshes and poll active jobs only [4/5]#188
Anthony Cintron (prbatero) wants to merge 1 commit into
prbatero/feat/perf-project-details-apifrom
prbatero/feat/perf-project-details-ui

Conversation

@prbatero

Copy link
Copy Markdown
Contributor

Summary

Part 4 of 5 in the project layer-loading performance stack. Stop duplicate and overlapping project-detail requests and make background refresh conditional on actual active work.

Changes

  • Add response-aware JSON GET handling with ETag and bodyless 304 support.
  • Share same-project in-flight requests and abort superseded project requests.
  • Force refresh after mutations while allowing normal navigation to use a fresh cache.
  • Skip state updates for 304 responses.
  • Poll only while the tab is visible, no request is running, and at least one job is active.

Testing

  • Full UI suite: 114 passed.
  • Every changed UI file passes ESLint with zero warnings.
  • Production Vite build passed.

Stack

Review Notes

This PR intentionally does not change route loading or Azure Maps asset delivery; those changes are isolated in PR 5.

Add response-aware GET handling, ETag support, request cancellation and same-key single-flight behavior. Stop background project polling while hidden, in flight, or when every known job is terminal.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant