Just to let you know, I am looking at patching ZServer using my PatchKit product to do "Content-Encoding: ..." stuff... anyone interested in testing when I get it running? (Probably a couple of days before I get a running version...) Adrian... -- Adrian Hungate All views expressed in this email are those of the whole world, however some people don't realise this yet. ----- Original Message ----- From: "JanStiller T-Online" <JanStiller@t-online.de> To: <zope-dev@zope.org> Sent: Wednesday, October 31, 2001 4:50 AM Subject: [Zope-dev] RAMCacheManager and gzip
Hi,
Is it possible to marry the RAMCacheManager and gzip?
I'm just working on a little shop and - for speed's sake - do 'ram-cache' the article-listings and push all the Zope-Content through mod_gzip. With this combination, I'm getting it 3x faster in Zope and 5x faster over the wire (normally 64k). That's great so far. But I don't see any sense in zipping cached content over and over, so I tried to zip the cached data in RAMCacheManager. In my first attempt, i replaced:
ZCache_get (RAMCacheManager.py):
entry.access_count = entry.access_count + 1 return entry.data
with:
entry.access_count = entry.access_count + 1 ob.REQUEST.RESPONSE.setHeader('Content-Encoding','compress') return zlib.compress(entry.data)
The results:
1. This works with Mozilla 0.96 only for very small entry.data. When I set entry.data to 'XX', it works, but any real page gets '<html><body></html></body>' as the result.
2. This doesn't seem work in IE alltogether. (with 'Content-Encoding: gzip' - zlib.compress != gzip!?)
I'm willing to spend some days of work for this feature, but although I have 2 years experience in Python I'm quite new to Zope and Internet-RFCxxxx's and this is definitely a point, where I would appreciate some hints from more experienced Zope-programmers (or a product, of course -- or the statement, that this won't be possible... ;o)
regards
Jan Stiller
P.S. sorry, if my words seems a bit confused, I'm more used to reading than writing english...
_______________________________________________ Zope-Dev maillist - Zope-Dev@zope.org http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )