0

I would like to store the blobkey of a profile photo in a database I am making for a webapp. I see that blobkeys are just listed as strings, but I wanted to know the maximum length a blobkey can be so I know the size to use in my database schema. I checked the documentation but I cannot see it listed. Does anyone know the maximum length of a blobkey?

Thanks!

Edit: Blobstore uses the X-AppEngine-BlobKey header to communicate the Blobkey, does that mean I should limit to the maximum size of a header?

Seems to me that this would ~4K-16K as per: Maximum on http header values?

Community
  • 1
  • 1
ptlu
  • 31
  • 3
  • Why do you need to limit/set the size of the blobkey in your database schema? Blobkey is something that you do not control. Google can change their implementation at any moment, and your schema will be broken as a result. – Andrei Volgin Jul 09 '14 at 18:01
  • Not that I really need to limit it. More I am asking what a sane limit would be if I were to put it in a database. Should I just make it a `TEXT` column and be done with it, or can I use a `VARCHAR` of a specific length? – ptlu Jul 10 '14 at 04:37
  • That's the point. Don't set a specific length for something you do not control. These days you are not going to save much with such micro-optimizations. – Andrei Volgin Jul 10 '14 at 04:39
  • That is fair. Thanks for he advice. – ptlu Jul 10 '14 at 18:37

0 Answers0