使用Google App Engine将图片/视频上传到Google云端存储空间 [英] Upload images/video to google cloud storage using Google App Engine

查看:134
本文介绍了使用Google App Engine将图片/视频上传到Google云端存储空间的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已阅读发送图片到谷歌云存储使用谷歌应用程序引擎。然而,代码中的答案,该文件将首先上传到Blobstore,所以文件不能超过32MB。

如何直接将大文件上传到Google Cloud Storage?



我已经检查过官方文档上传对象,但我仍然没有知道如何写一个表单来发布一个大文件。

解决方案

easy since 1.7.0

  upload_url = blobstore.create_upload_url('/ upload_handler',gs_bucket_name ='my_bucket')

将直接上传到Google Storage,并返回指向上传的blob密钥在云端存储中。


I have read the question from Sending images to google cloud storage using google app engine.

However, the codes in the answer that the file will upload to Blobstore first, so the file can not be exceeded 32MB.

How can I upload the large file to Google Cloud Storage directly?

I have checked the official document Upload Objects, but I still don't know how to write a form to post a large file.

解决方案

easy since 1.7.0

upload_url = blobstore.create_upload_url('/upload_handler', gs_bucket_name='my_bucket')

Will upload straight to Google Storage and return you blob keys that point to the uploads in Cloud Storage.

这篇关于使用Google App Engine将图片/视频上传到Google云端存储空间的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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