Google Cloud Run的默认存储是什么? [英] What's the default storage for Google Cloud Run?

查看:72
本文介绍了Google Cloud Run的默认存储是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我找不到有关Google Cloud Run拥有的存储的文档.例如,当我们创建虚拟机时,它是否包含很少的千兆字节存储? 如果不是,是否有一个'/tmp'文件夹,我可以在请求期间将数据临时放入其中?可以使用的限制是什么?

There is not documentation that I can find about the storage that Google Cloud Run has. For example, does it contains few Gigabyte storage as we create a VM? If not, is there a '/tmp' folder that I can put data temporarily into during the request? What's the limitation if available?

如果它们都不可用,我要在运行Cloud Run时保存一些临时数据的建议是什么?

If neither of them available, what's the recommendation if I want to save some temporary data while running Cloud Run?

推荐答案

Cloud Run是一个无状态服务平台,没有任何内置存储机制.

Cloud Run is a stateless service platform, and does not have any built-in storage mechanism.

可以将文件临时存储在容器实例中以进行处理,但是如

Files can be temporarily stored for processing in a container instance, but this storage comes out of the available memory for the service as described in the runtime contract. Maximum memory available to a service is 2 GB.

对于持久存储,建议与其他GCP服务集成提供存储或数据库.

For persistent storage the recommendation is to integrate with other GCP services that provide storage or databases.

为此,最重要的服务是云存储

The top services for this are Cloud Storage and Cloud Firestore.

这两个特别适合Cloud Run,因为它们具有最无服务器"的兼容性:水平扩展以匹配Cloud Run的扩展能力,并具有在状态更改时触发事件的能力,以通过以下方式插入异步,无服务器架构 Cloud Pub/Sub 和Cloud Storage的云函数具有Cloud Function 事件和功能;触发器.

These two are a particularly good match for Cloud Run because they have the most "serverless" compatibility: horizontal scaling to matching the scaling capacity of Cloud Run and the ability to trigger events on state changes to plug into asynchronous, serverless architectures via Cloud Pub/Sub and Cloud Storage's Registering Object Changes and Cloud Functions with Cloud Function Events & Triggers.

这篇关于Google Cloud Run的默认存储是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆