-
Notifications
You must be signed in to change notification settings - Fork 401
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Redirect all frontend routes to start-instance until configured #41
Comments
I intentially didn't do it to avoid adding a D1 query on all requests. |
But don't we hit D1 on every frontend UI request anyway? Especially now that we are reading the thumbnail etc from the DB? |
We would need to query D1 to detect that the instance hasn't been configured. |
This code runs on every frontend request: wildebeest/frontend/src/routes/layout.tsx Lines 18 to 25 in 44898ac
In this function, we can check whether the config exists (rather than just naively casting it) and throw a |
And if this is problematic (from a performance point of view) we need to implement some caching of the instance data in the system somewhere (outside of D1) perhaps in a KV? |
No description provided.
The text was updated successfully, but these errors were encountered: