user1250991
user1250991

Reputation: 97

Referring to GAE Blobstore Entries by their URL

In the software I'm writing, I need a URL to the blobstore entry. The raw blobstore entry bytes are not useful to me.

I saw a similar question to this elsewhere:

How to get the direct url of a binary file in the Google Blobstore?

However, I don't have a high enough 'rep' value to reply to the accepted answer, and I'm seeking additional clarification of that answer. The accepted answer indicates that you can refer to blobstore entries by their URL if you write a handler for that case. I'm interested to see an example of this type of handler. The GAE documentation for a BlobstoreDownloadHandler does not provide an example of this case, and only provides an example of how to get the raw bytes of the blobstore entry, which again isn't what I want.

If I can't get a URL for a blobstore entry directly, how would I do that using a handler of some kind?

Upvotes: 0

Views: 184

Answers (1)

Greg
Greg

Reputation: 10360

The docs here explain how to use it, were you looking somewhere else? send_blob doesn't cause the blob to be read into your app's memory, if that's what concerns you? It sets a header on the response, that gets turned into the blob-content by AppEngine.

Upvotes: 1

Related Questions