Skip to content
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

Question: Is it possible to increase the hook.go timeout? #67

Open
adambraimbridge opened this issue Dec 19, 2019 · 0 comments
Open

Question: Is it possible to increase the hook.go timeout? #67

adambraimbridge opened this issue Dec 19, 2019 · 0 comments

Comments

@adambraimbridge
Copy link

adambraimbridge commented Dec 19, 2019

Hello,

I'm using the Netlify authentication webhook to call a function which generates a new cloudant database:

image
Above: Netlify webhook configuration

image
Above: Cloudant database that's created via the webhook function

The function has to return the credentials for the newly-created database, which is saved as app_metadata in the user's Netlify identity account.

Although the code does behave as expected, the hook returns a timeout error.

"Failed to perform webhook in time frame."

#error=server_error&error_description=Failed+to+perform+webhook+in+time+frame+%285+seconds%29`

I can see that the timeout is in the hooks.go script. Is it possible to extend that timeout? Perhaps from a global, environment or configuration variable?

https://github.com/netlify/gotrue/blob/master/api/hooks.go#L106

My source code: https://github.com/adambraimbridge/goldbug/blob/be9c82dcc8a9df3d92cb9df071bd6fce2ef9b37e/functions/get-cloudant-database.js

Many thanks, Adam.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant