Replies: 1 comment
-
|
I think running cron jobs is the responsibility of the infrastructure, not the framework. That’s likely why TanStack Start’s documentation doesn’t mention them. In general, you can implement any task you want to run periodically as a Server Route, and then configure your deployment infrastructure to call it on a schedule. For example, if you implement a Server Route at {
"$schema": "https://openapi.vercel.sh/vercel.json",
"crons": [
{
"path": "/api/hello",
"schedule": "0 5 * * *"
}
]
}Other platforms, such as Cloudflare, provide similar mechanisms. For details, please refer to the documentation of the infrastructure you’re deploying to. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Problem Description
I want to run scheduled tasks (such as clearing the cache every morning, syncing data every hour, etc.) in the TanStack Start application, but I couldn't find any relevant guidelines in the documentation.
Methods I've Tried
Beta Was this translation helpful? Give feedback.
All reactions