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

504: GATEWAY_TIMEOUT #40

Open
DmitryAdam opened this issue Dec 13, 2023 · 8 comments
Open

504: GATEWAY_TIMEOUT #40

DmitryAdam opened this issue Dec 13, 2023 · 8 comments

Comments

@DmitryAdam
Copy link

After fresh install from clicking the vercel deploy button, this message appear:
This Serverless Function has timed out.

Your connection is working correctly.

Vercel is working correctly.

504: GATEWAY_TIMEOUT
Code: FUNCTION_INVOCATION_TIMEOUT
ID: sin1::xvkft-1702434374787-3c525d8b2102

If you are a visitor, contact the website owner or try again later.
If you are the owner, learn how to fix the error and check the logs.

@peterkyle01
Copy link

Changed the serverless.yml file on line 13 on the timeout from 15 to 30 because I read that is the max for vercel and it worked ,also make the function calls near your location on vercel to reduce the timeouts.

@DmitryAdam
Copy link
Author

DmitryAdam commented Jan 6, 2024

I did it,
this is my serverlesss.yml:

service: serverlesswp-wordpress-starter

provider:
  name: aws
  runtime: nodejs18.x
  httpApi:
    payload: '2.0'

functions:
  requestHandler:
    handler: api/index.handler
    memorySize: 1024
    timeout: 30
    events:
      - httpApi:
          method: any
          path: /{proxy+}
    environment:

@IMPranshu
Copy link

Well, I think we can run only 1 serverless function project in the hobby project. If you are running this your other projects will eventually timeout on the "Hobby Plan". I have tested it out. It would help if you upgraded to Pro or used multiple Vercel accounts.

@DmitryAdam
Copy link
Author

I did, I just running 1 project on this vercel account

@eucelso
Copy link

eucelso commented Jan 16, 2024

I have the same problem: I changed the file serverlesss.yml, but the error persists.

Could someone give me a light?

@IMPranshu
Copy link

One thing I noticed is that I was changing the PlanetScale DB's location from the default and I was facing the timeout error.

When I kept it to default I didn't face this error, I tried it multiple times. Hope this helps.

@eucelso
Copy link

eucelso commented Jan 16, 2024

I ended up changing my config here to Europe because that's where I am, I'll try to keep the default location to see then

@eucelso
Copy link

eucelso commented Jan 16, 2024

tks @IMPranshu I kept it to default and works!

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

4 participants