This commit is contained in:
javi
2011-12-06 19:05:39 +01:00
2 changed files with 4 additions and 1 deletions

View File

@@ -9,6 +9,9 @@ var CartodbWindshaft = function(serverOptions) {
// set the cache chanel info to invalidate the cache on the frontend server
serverOptions.afterTileRender = function(req, res, tile, headers, callback) {
res.header('X-Cache-Channel', req.params.dbname);
// note - may not be invalidating properly
res.header('Last-Modified', new Date().toUTCString());
res.header('Cache-Control', 'no-cache,must-revalidate, public');
callback(null, tile, headers);
};

View File

@@ -35,7 +35,7 @@ function VarnishClient(host, port, ready_callback) {
connect();
client.on('data', function(data) {
client.on('data', function (data) {
data = data.toString();
lines = data.split('\n', 2);
if(lines.length == 2) {