Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Serving images, how to? #9

Open
AtmanActive opened this issue Jan 15, 2015 · 1 comment
Open

Serving images, how to? #9

AtmanActive opened this issue Jan 15, 2015 · 1 comment

Comments

@AtmanActive
Copy link

Hi,

First, kudos for coding this module and thanks for sharing.

Now, following your instructions carefully, I'm a bit confused how would one go for serving images from memcached via your module.

Since the data in the memcache key store needs to look like this:

EXTRACT_HEADERS\r\n
Content-Type: image/png\r\n
Cache-Control:max-age=21600\r\n
\r\n
NOW WHAT?

The thing that I don't understand here is how would one encode binary image data right below the header's textual data.

Thanks.

@bpaquet
Copy link
Owner

bpaquet commented Jan 15, 2015

No encoding, just put the binary data after the second \r\n, like in http
protocol.

On Thu, Jan 15, 2015 at 6:46 PM, AtmanActive [email protected]
wrote:

Hi,

First, kudos for coding this module and thanks for sharing.

Now, following your instructions carefully, I'm a bit confused how would
one go for serving images from memcached via your module.

Since the data in the memcache key store needs to look like this:

EXTRACT_HEADERS\r\n
Content-Type: image/png\r\n
Cache-Control:max-age=21600\r\n
\r\n
NOW WHAT?

The thing that I don't understand here is how would one encode binary
image data right below the header's textual data.

Thanks.


Reply to this email directly or view it on GitHub
#9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants