BlobStore vs Cloud Storage for storing user upload

2019-07-22 12:50发布

问题:

I'm new to AppEngine and I'm building an app that accept user image uploads from Android devices.

I built it with Cloud Storage but then I realized that I have problems uploading large files (maybe because of request time limits?)

so I figured out I should use Blobstore's upload URL to properly upload multiple large files. Blobstore also has the on-the-fly image resizing feature which is very nice.

the thing is, Cloud Storage is cheaper than the Blobstore.

should I move the uploaded files from Blobstore to Cloud Storage after uploading ?

is there a way to upload multiple large files to AppEngine without going through the Blobstore upload URL way ?

I'm using Go if it matters..

回答1:

The simplest answer is probably to use a signed url to allow the user to upload directly to Cloud Storage. This lets you bypass App Engine entirely for your upload, which in turn simplifies the network usage and allows you to take full advantage of all of Cloud Storage's upload infrastructure.



回答2:

Currently, blobstore is $0.0009 / GBHour, while Cloud Storage is $0.0027 / GBHour, so it seems that blobstore is now 3 times cheaper than Cloud Storage. So while there may be reasons to move to Cloud Storage, cost is not currently one of them. Note that the prices changed recently.

If you need the richer API provided by Cloud Storage, then that's another story of course.