Question

I am developing an app-engine connected android project using the eclipse plugin. When I upload an image to the blobstore, how do I make it callback an endpoint method? I find great posts here that can be used as reference to understand my question better (if you need to).

using blobstore with google cloud endpoint and android

Saving blobs with Google Endpoint

So really, I want to know how to make the callback url an endpoint method such as saveAnimalData below (I stole from referenced link)

@ApiMethod(name = "saveAnimalData", httpMethod = HttpMethod.POST)
        public String saveAnimalData(AnimalData request) throws Exception {
}

Pas de solution correcte

Autres conseils

You should be able to use

https://appid.appspot.com/_ah/api/apiname/version/saveAnimalData

As your final destination url when calling. blobstoreService.createUrl(destination) .

Just bear in mind that the request here is not your original submission. GAE will first call an internal URL (the one created by the blobstoreservice), store the blob and then call your destination URL so whatever info you send will be lost before reaching your endpoint (eg AnimalData will be null)

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top