-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
Reload/Refresh the GraphQL content from MySQL data. #26042
Comments
So have you tried using ENABLE_GATSBY_REFRESH_ENDPOINT? If so, is there something that's not working correctly? |
Can you elaborate a bit more on what did you try? And what didn't work? Did you try sending a POST request to |
@vladar @herecydev app.post('/__refresh', (req, res) => { const enableRefresh = process.env.ENABLE_GATSBY_REFRESH_ENDPOINT const refreshToken = process.env.GATSBY_REFRESH_TOKEN const authorizedRefresh =
if (enableRefresh && authorizedRefresh) {
} app.listen(8001, function() { Still, this doesn't seem to refresh the graphQL query's data. |
Not sure if this will help, but I think you need to remove a space from the variable definition in your .env file. Try changing |
@AjayDhimanELS You don't need to add anything to your gatsby-node file to enable this feature. Did you try removing the space from |
Unfortunately I also have troubles with this. I've created a
When I start Gatsby with
|
I'm using Node/Express to successfully push some data into a MySQL db. Now the issue is that GraphQL is not refreshing/loading the new/recently added data. I tried following these:
Force a refresh of GraphQL data without restarting gatsby develop #14395
gatsby with graphql won't load new data #2847
But couldn't get any help. Have we found any simpler solutions to this?
The text was updated successfully, but these errors were encountered: