On 2 July 2010 06:12, Lars <[email protected]> wrote: > I have a simpler Apache output filter written using mod_python. I'm > curious if it is possible to implement this as a wsgi application > hosted by mod_wsgi; I am particularly interested in mod_wsgi's ability > to run applications as processes separate from the main Apache server. > > The filter is being used to modify content accessed via Apache's proxy > module -- that is, the current configuration looks something like > this: > > PythonOutputFilter /tmp/filter.py FILTER > <Location /test/> > SetOutputFilter FILTER > > ProxyPass http://www.example.com/display/USERDOCS/ > ProxyPassReverse http://www.example.com/display/USERDOCS/ > </Location> > > Can I do something similar with mod_wsgi?
Quoting: http://blog.dscpl.com.au/2010/05/modpython-project-soon-to-be-officially.html """ If you are using mod_python input or output filters there simply isn't any replacement. Frankly though I always thought that writing input or output filters in mod_python was a really bad idea. Yeah it may work, but it wouldn't exactly be efficient. You would be much better writing a proper Apache module in C to do what is required, certainly if performance is an issue. """ That said, what does your filter do? In most cases there are custom C Apache modules that likely can perform the same task much more efficiently. As I mention in that prior post,I personally think that writing Apache filters in Python is a bad idea. I also might add that the way that mod_python implemented filters, meant that technically it was not possible to write a filter which adhered by the guidelines/rules of Apache as far as processing of special buckets for flushing and EOS. As such, mod_python filters were arguably not well behaved. Thus if any replacement was developed, it could not present the same API as mod_python did as that wasn't adequate by virtue of how it hid the bucket mechanism in Apache and those special buckets. Graham -- You received this message because you are subscribed to the Google Groups "modwsgi" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/modwsgi?hl=en.
