Skip to main content
Version: v10.5.0

Queues

HyperFetch sends requests through queues, one per query key. A queue decides when a request goes out: identical GET requests join one call, queued requests go one at a time, and cancelable requests replace each other. The Queues page shows each queue that has requests and lets you pause it from HyperFlow, which is the quickest way to see how your UI behaves while requests wait.

One card per queue, with its status and active requests.


Read the list​

Each card shows a query key with its status and request counts. Search the list with Search by query key.

StatusMeaning
RunningThe queue holds requests that are being sent or wait their turn
PendingThe queue is empty and waits for the next request
StoppedThe queue was stopped. Its requests wait until you start it again

Inspect a queue​

Select a card to open the queue.

A stopped queue holding three uploads.

The overview counts the queue's observers and the requests it processed, with how many succeeded, failed or were canceled, and how many are pending. Below it are its response times, data transferred and processing times.

Observers are the subscriptions in your app to the loading state or the queue of this key: every mounted useFetch, useSubmit and useQueue that uses it counts as one.


Control a queue​

Open Actions in the queue's toolbar. Each action runs in your app.

The queue is stopped, so the menu offers Start.

ActionWhat happens in your app
StopThe queue pauses. Running requests are aborted and stay queued, new ones wait
StartThe queue resumes and sends its waiting requests
ClearEvery request is removed from the queue
Set loading / Restore loadingHooks that use this key show their loading state, without sending anything, until you restore it

While a queue is stopped, its requests show as Paused on the Network page.

Test slow and offline paths

Stop the queue of a form's submit request, then submit the form. You can now check your spinner, a disabled button or an "unsaved changes" warning for as long as you need. Start the queue to let the request through.

Read Dispatcher for how queues, deduplication and cancelation work in the client.


Next steps​