My problem revolves around a user making a text file upload to my app. I need to get this file and process it with my app before saving it to the datastore. From the little I have read, I understand that user uploads go directly to the datastore as blobs, which is ok if I could then get that file, perform operations on it(meaning change data inside) and then re-write it back to the datastore. All these operations need to be done by the app. Unfortunately from the datastore documenation, http://code.google.com/appengine/docs/python/blobstore/overview.html an app cannot directly create a blob in the datastore. That's my main headache. I simply need a way of creating a new blob/file in the datastore from my app without any user upload interaction.
相关问题
- java.lang.NullPointerException at java.io.PrintWri
- What is the best way to do a search in a large fil
- Spring Integration - Inbound file endpoint. How to
- __call__() missing 1 required positional argument:
- Upload file to Google Cloud Storage using AngularJ
相关文章
- Is there a size limit for HTTP response headers on
- What is the correct way to declare and use a FILE
- appcfg.py command not found
- Making new files automatically executable?
- Google app engine datastore string encoding proble
- How to serialize data into indented json [duplicat
- Creating a custom file like object python suggesti
- Angular route not working when used with Google Ap
Thanks for your help. After many sleepless nights, 3 App Engine Books and A LOT of Googling, I've found the answer. Here is the code (it should be pretty self explanatory):
blobstore != datastore
.You can read and write data to the datastore as much as you like so long as your data is <1MB using a
db.BlobProperty
on your entity.As Wooble comments, the new File API lets you write to the blobstore, but unless you are incrementally writting to the blobstore-file using tasks or something like the mapreduce library you are still limited by the 1MB API call limit for reading/writing.