6

I'm working on a simple multimedia messaging app for Android, and I was trying to use Google AppEngine's BlobStore as my cloud storage for the various image, video, and audio files that will be transferred. However, all of the examples and such that I've seen for uploading to blobstore assume that I'm doing it via an HTTP form, and so I'm kind of at a loss as to what to do.

I've seen several people asking the same question, but none of them seem to ever get a satisfactory answer. Can I or should I use AppEngine's blobstore in this way, and if so how do I go about doing it?

Thanks, SO.

Zenanon
  • 185
  • 2
  • 7
  • Can you not make a request to your app to get the upload url then send the data in a multipart/form-data encoded post request to that url? – Robert Kluin Mar 25 '11 at 19:48
  • Try this : [Step by Step Description][1] [1]: http://stackoverflow.com/questions/16246734/using-blobstore-with-google-cloud-endpoint-and-android – user2922935 Sep 13 '14 at 22:30

2 Answers2

4

You could go with something like this:

1. On Google App Engine, create a Web Handler that calling blobstore.create_upload_url() returns an action_POST_URL

2. On Android, post the image to the action_POST_URL using HttpClient and MultipartEntity.

Shashank Shekhar
  • 3,958
  • 2
  • 40
  • 52
systempuntoout
  • 71,966
  • 47
  • 171
  • 241
2

for Java

    BlobstoreService blobstoreService = 
                             BlobstoreServiceFactory.getBlobstoreService();
    String action_POST_URL= blobstoreService.createUploadUrl(redirect_URL);
Shashank Shekhar
  • 3,958
  • 2
  • 40
  • 52
Eunice
  • 21
  • 2