trafficserver-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joshua Tolley <eggyk...@gmail.com>
Subject Plugin problems
Date Wed, 16 Feb 2011 00:09:52 GMT
A site I'm working with needs some fairly intelligent edge caching, and I've
been trying out traffic server to implement it. Enough has gone wrong that I'm
wondering if either I'm doing something very wrong, or traffic server really
isn't suited for the things I'm trying to do.

For instance, I set up traffic server as a reverse proxy, in front of a local
apache instance. I tried using cache.config to cache all png files and no html
files, like this:

url_regex=localhost suffix=png ttl-in-cache=10m
url_regex=localhost suffix=html action=never-cache

I stopped traffic server, deleted the cache file, restarted traffic server,
and requested an html file and a png image through traffic server including
a "Cache-control: only-if-cached" header to see if the files would come from
the cache. As expected, I got a 504 Not Cached error, as expected. I requested
the files again, without the header, and received them normally. At this point
I'm hoping only the image file is cached, but when I request the files again,
with the Cache-control header, I get both of them normally.

So then I started fiddling with some of the example plugins. I managed to
compile the add-header and output-headers plugins easily enough, and to
install them. But the add-header plugin didn't add any headers, and the
output-headers plugin didn't output any headers. I added some INKDebug() lines
to both plugins and recompiled them so I could be sure they were running, and
saw all kinds of output telling me, for instance, the add-header plugin was
running and trying to add a header. But no header showed up on the output.

Finally, a more general question. The documentation says plugins can't modify
the cache directly. Some of our requirements are that we need to cache or not
cache objects based on headers, cookies, etc., but I'm not entirely sure
that's actually possible. I'd appreciate any comments you can give. Thanks in
advance.

--
Joshua Tolley

Mime
View raw message