Who runs the job when you use Upstash QStash?
QStash delivers a message to an address your app exposes. Your app runs the job at that address. This profile covers QStash. Upstash Redis and Workflow are separate products.
Keep the publish credential on your server. Have the receiving code verify the request signature, a proof that the delivery came from QStash, before it does any work. Put a job ID in the message and keep the report and its access rules in your app.
What happens if the app gets the same request twice?
QStash retries failed deliveries. Its publish deduplication can suppress a repeated submission with the same ID within ten minutes. The receiving code still needs to handle repeated delivery safely.
Use one result record and file per intended job. If saving the report succeeds but the response fails, a later attempt can find that result. Return success after the work is saved. After retries run out, inspect the dead-letter queue, where failed deliveries wait for review, before trying again.
How can you rehearse a timeout without sending a request?
Draw a made-up report request and one receiving address on paper. Keep accounts, addresses, customer data and storage disconnected.
- Mark the receiving checkDraw a delivery with no valid signature and mark it rejected before work. Draw a verified delivery and give it one fictional report ID.
- Lose the success responseMark the report saved and the response lost. Trace the same report ID on a retry. The app should find one file and one result record.
- Decide when to stopDraw a delivery that keeps failing. Mark it for review in the failed-message queue. Check the app’s result record before attempting the job again.
Which parts of delivery count toward the bill?
Upstash lists 1,000 messages per day on QStash Free. Each delivery attempt counts, including retries. The current pay-as-you-go plan lists US$1 per 100,000 messages. Check bandwidth, schedule and retention limits for your plan.
The delivery log helps explain an attempt, while your app’s record tells the visitor whether the report is ready. Keep the job ID, result and retry decision in your own records if you change delivery services.