RE: [Zope-dev] support for low level HTTP Response logging?
Are you mainly concerned about the http headers in the response, or the response body? If it is just the headers, Squid's log_mime_hdrs feature will log all HTTP headers from both the request and response for you for each request. If nothing else, perhaps it's a start... Sean -Original Message- From: Romain Slootmaekers [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 25, 2003 2:25 AM To: [EMAIL PROTECTED] Subject: [Zope-dev] support for low level HTTP Response logging? Yo, searching the zope site and googling yielded too many data and no info, so I might as well ask it here. We are very interested in finding out the exact HTTP Responses that the zope server pushes towards the client. So is there a low level hook for logging the http responses ? We want the exact response, complete with all header info etc. Why not just sniff, you might ask? Well, we are developing a web application for mobile microbrowsers, and most these clients have no hooks for attaching a sniffer client side. Installing a sniffer server side is not possible for other reasons. TIA, Sloot. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] support for low level HTTP Response logging?
On Tuesday 25 February 2003 12:08 pm, Romain Slootmaekers wrote: > We need this in our 3th line support, were we want to be able to follow > all ins and outs for singled out user (fi filtered on cookie). > We also need to be able to turn this on/off at runtime. I would do this in the front-end proxy. Set up a squid acl to catch this one user, and send his requests via tcpwatch (or similar) rather than direct to zope. -- Toby Dickenson http://www.geminidataloggers.com/people/tdickenson ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] support for low level HTTP Response logging?
Clemens Robbenhaar wrote: Hi Romain, > Yo, > > searching the zope site and googling yielded too many data and no info, > so I might as well ask it here. > > We are very interested in finding out the exact HTTP Responses that the > zope server pushes towards the client. > > So is there a low level hook for logging the http responses ? > We want the exact response, complete with all header info etc. There is no explicit hook, but you might add Your logging code in Zope/lib/python/ZPublicher/HTTPResponse.py, for example in the 'write' method of the HTTPResponse, or by wrapping the 'self.stdout' in __init__ by something that also logs the output before writing to the passed 'stdout' stream. Of course this most probably will bring performance down (or even the complete Zope, if there is a simple typo in the hacked code ;-) I assume You only need this for testing. No. actually, it is for a production setup, so it would be preferable if it could be done without changing the zope source code [this gives all kinds of problems, extra work,... when we need to update a server] We need this in our 3th line support, were we want to be able to follow all ins and outs for singled out user (fi filtered on cookie). We also need to be able to turn this on/off at runtime. We can sift out the user we want, turn off/on the logging, aso in our own code, if we could just have a low level zope hook. For the requests, we already have done this since there are plenty of hooks available. (yes, grep -i "someString" $(find ./ -name "*.py") is my friend ;) ) for Test/Development setups, we have plenty of options: proxying, sniffing, source code hacking, stepping with debugger,. Romain. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] support for low level HTTP Response logging?
Andreas Jung wrote: http://hathaway.freezope.org/Software/TCPWatch Apparantly, I forgot to mention this: proxying isn't an option either. You can't just, on the fly, put a proxy between several components in a production setup. Sloot. --On Dienstag, 25. Februar 2003 11:24 +0100 Romain Slootmaekers <[EMAIL PROTECTED]> wrote: Yo, searching the zope site and googling yielded too many data and no info, so I might as well ask it here. We are very interested in finding out the exact HTTP Responses that the zope server pushes towards the client. So is there a low level hook for logging the http responses ? We want the exact response, complete with all header info etc. Why not just sniff, you might ask? Well, we are developing a web application for mobile microbrowsers, and most these clients have no hooks for attaching a sniffer client side. Installing a sniffer server side is not possible for other reasons. TIA, Sloot. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] support for low level HTTP Response logging?
http://hathaway.freezope.org/Software/TCPWatch --On Dienstag, 25. Februar 2003 11:24 +0100 Romain Slootmaekers <[EMAIL PROTECTED]> wrote: Yo, searching the zope site and googling yielded too many data and no info, so I might as well ask it here. We are very interested in finding out the exact HTTP Responses that the zope server pushes towards the client. So is there a low level hook for logging the http responses ? We want the exact response, complete with all header info etc. Why not just sniff, you might ask? Well, we are developing a web application for mobile microbrowsers, and most these clients have no hooks for attaching a sniffer client side. Installing a sniffer server side is not possible for other reasons. TIA, Sloot. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope ) -- - -Andreas Jung http://www.andreas-jung.com - - EMail: andreas at andreas-jung.com - -"Life is too short to (re)write parsers" - - ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )