FAQ Database Discussion Community


GAE + Blobstore: Serve different image size depending on viewport width

javascript,html,image,google-app-engine,blobstore
As we know, we can serve images from the blobstore using its serving url, and append =sXX to indicate the image's width: <!-- serving an image of 600px width --> <img src="{{serving_url}}=s600" alt=""/> This works well, except we want to serve a smaller image for smaller screens for obvious webperf...

What is the correct flow to upload an image and use getServingUrl() in app engine?

java,google-app-engine,google-cloud-storage,google-cloud-endpoints,blobstore
I have an android app that wants to include image sending in the instant messaging client. I'm terribly confused on the way to do this using the blobstore or google cloud storage. Can someone please outline the steps to achieve this from the backend perspective? My goal is to end...

404 error when uploading file to GCS with query string on Production

java,google-app-engine,google-cloud-storage,blobstore
I am using flash to upload a file to GCS. I create a upload url using the following successUrl "/cms/requestManager?ps={"1":{"action":"Upload Audio Recording","sendId":1,"data":{"fileName":"testQuestionAudioRecording","category":"testQuestionRecording"}},"jsInstanceID":"ahdzfmRldi1keW5hY3RpdmVzb2Z0d2FyZXITCxIKSlNJbnN0YW5jZRjKm-kBDKIBBmRzLmNtcw","userActive":true}" When I send the file upload it comes back with a 404 error. I check in the appengine instance logs for 404 errors and there are none. The...

Replacing the FileService Api to create a Blob file in server side

java,google-app-engine,gwt,google-cloud-storage,blobstore
I am using the FileService Api to save files to the Blobstore from server side like this: FileService fileService = FileServiceFactory.getFileService(); AppEngineFile file = null; file = fileService.createNewBlobFile(contentType, fileName); boolean lock = true; FileWriteChannel writeChannel = null; writeChannel = fileService.openWriteChannel(file, lock); ByteBuffer bb = ByteBuffer.wrap(FILE_BYTES); writeChannel.write(bb); writeChannel.closeFinally(); BlobKey blobKey =...

migrating images to google app engine datastore or blobstore

python,google-app-engine,gae-datastore,blobstore
I have property model, containing a field image_url. class Property(ndb.Model): date_created=data.UTCDateTimeProperty(auto_now_add=True) # some other fields here image_url = ndb.StringProperty(indexed=False) and image model, class Image(ndb.Model): property = ndb.KeyProperty() file = ndb.KeyProperty(indexed=False) # some other fields image_url = ndb.StringProperty(indexed=False) Now I have 'n' number of images for each property in my local...

Google App Engine. How to see photos stored in BlobStore

google-app-engine,blobstore
I stored several photos on app engine using BlobstoreService. How to browse these photos ? I know that we can download each photo individually using its blob key, however there is no a way of accessing all photos from app engine console online to manage it ? (Delete for example...)...

Non ascii filename in blobstore (Google App Engine)

python,google-app-engine,blobstore
I am trying to upload some picture to Google App Engine using the Blobstore. And some of the files contain non-ascii characters. When I download these files, the filename for these downloaded file appeared to show the "key" in blobstore, rather than the original file name. My site is http://wlhunaglearn.appspot.com/...

GAE BlobstoreUploadHandler doesn't recognize files

python,google-app-engine,python-requests,blobstore
When I send a request from a client like this: with open(config.datafile, "rb") as f: r = requests.post(config.endpoint, files={"file": f}) print r.text to my GAE app like this: class FileUploadHandler(blobstore_handlers.BlobstoreUploadHandler): def post(self): self.response.out.write(self.get_uploads()) I would expect to get something like this: { "file": "line 1\nline 2\nline 3\nline 4\nline 5\nline 6\nline...

Python Google App Engine. GET Request sent twice

python,google-app-engine,jinja2,blobstore,webapp2
A GET Request is being sent twice when a User clicks a link in a Google App Engine, Python App. The App uses webapp2 and jinja2. This only happens if a Blobstore image is missing from the Datastore Model, "Event". If the image is present in "Event", there is only...