简体   繁体   English

成功部署后 Cloud Run 错误 504(上游请求超时)

[英]Cloud Run Error 504 (Upstream Request Timeout) after successful deploy

I was following this tutorial from Google to deploy a servise to Cloud Run ( https://codelabs.developers.google.com/codelabs/cloud-run-hello-python3#5 ).我正在按照 Google 的本教程将服务部署到 Cloud Run ( https://codelabs.developers.google.com/codelabs/cloud-run-hello-python3#5 )。 In Cloud Shell my project is deployed successfully (screenshot below).在 Cloud Shell 中,我的项目已成功部署(截图如下)。 However, once I click on the link I get timeout.但是,一旦我单击链接,我就会超时。 If I test it locally from Cloud Shell it works fine.如果我从 Cloud Shell 在本地测试它,它工作正常。

在此处输入图像描述

Why could this be happening?为什么会发生这种情况? Where could I get more data about the issue?我在哪里可以获得有关该问题的更多数据?

As mentioned in the Documentation :文档中所述:

For Cloud Run services, the request timeout setting specifies the time within which a response must be returned by services deployed to Cloud Run.对于 Cloud Run 服务,请求超时设置指定部署到 Cloud Run 的服务必须返回响应的时间。 If a response isn't returned within the time specified, the request ends and error 504 is returned.如果在指定时间内没有返回响应,则请求结束并返回错误 504。

The timeout is set by default to 5 minutes and can be extended up to 60 minutes.超时默认设置为 5 分钟,最长可延长至 60 分钟。 You can change this setting when you deploy a container image or by updating the service configuration.您可以在部署容器映像或更新服务配置时更改此设置。 In addition to changing the Cloud Run request timeout, you should also check your language framework to see whether it has its own request timeout setting that you must also update.除了更改 Cloud Run 请求超时之外,您还应该检查您的语言框架,看看它是否有自己的请求超时设置,您还必须更新该设置。

You can refer to this Public group issue which will be helpful in resolving the current error.您可以参考此公共组问题,这将有助于解决当前错误。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在 Vercel 部署 NEXTJS 中发出 API 请求时出现错误 504 - Error 504 when making an API request in NEXTJS deploy at vercel gcp 云在标头之前运行上游连接错误或断开连接/重置。 重置原因:协议错误 - gcp cloud run upstream connect error or disconnect/reset before headers. reset reason: protocol error Cloud Run 在第 2 步部署时失败并出现权限错误 - Cloud Run Fails on Step-2 Deploy with Permissions Error 添加磁盘后在谷歌云中打开 jupyterlab notebook 时出现 504 错误 - 504 error when opening jupyterlab notebook in google cloud after adding disk 开始使用 Google Cloud Kubernetes 集群后,Cloud Build 无法部署 Cloud Run - Cloud Build fails to deploy Cloud Run after started using Google Cloud Kubernetes Cluster 无法部署到 Cloud Run,“遇到内部错误”,建议? - Cannot deploy to Cloud Run, `Internal error encountered`, suggestions? 尝试部署到 Google Cloud Run 时出现权限错误 - Permission error when trying to deploy to Google Cloud Run Cloud Run 端点入门 - 请求超时或请求太大错误 - Getting Started with Endpoints for Cloud Run - Request Timeout or Request Too Large Errors 如何解决 AWS Elastic Beanstalk 504 超时错误? - How to solve AWS Elastic Beanstalk 504 Timeout Error? Cloud Run、使用命令部署与使用 InteliJ Cloud Code 部署 - Cloud Run, Deploy with Commands vs Deploy with InteliJ Cloud Code
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM