[Zope] Apache is not caching Zope pages
Hello again There´s something very strange with the Apache + ZServer solution presented in the zope.org howtos. The problem is: I have a Zope 2.1.6 with SiteAccess and Apache 1.3.12 with the mod_proxy and mod_expire set up to that all request get at por 80 by Apache are proxed back to port 8080 of Zope. SiteAccess garantees that this cycle works all the time and port 8080 is never accessed directly. This works fine. The problem is that the Apache proxy is not caching the pages as it should, so that requests made to Zope once are not made again until expired from the cache. This results that every single request made to Apache goes directly to Zope and than the lack of robustness of ZServer makes it very slow and unstable (as expected). The strange thing is that the directory used for the cache is been filled up with files but it looks like Apache is ignoring them and going directly to Zope. When I shut down Zope, it never goes to the cached files and when I make requests to Apache the Zope´s log grows up all the time for the same bunch of pages. Here´s the configuration in my httpd.conf CacheRoot "D:/Program Files/Apache Group/Apache/proxy" CacheSize 5 CacheGcInterval 1 CacheMaxExpire 24 CacheLastModifiedFactor 0.1 CacheDefaultExpire 1 CacheForceCompletion 90 ProxyPass /zope/ http://10.10.10.176:8080/ ProxyPassReverse /zope/ http://10.10.10.176:8080/ ExpiresActive On ExpiresDefault A86400 ExpiresByType image/gif A604800 ExpiresByType image/jpg A604800 ExpiresByType text/html M43200 Anyone knows why this happens? What´s the workaround? I searched through all the web and find nothing about the mod_proxy configuration so it´s turning to be extremelly difficult to maintain the Zope site, even with the robust Apache as the front-end. Thanks ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] zope not receiving POSTs from Apache
Hi And again there´s a weird behavior concerning Zope+Apache :) Well, I have successfully set up an Apache in a Solaris system with Zope configured behind it using the ProxyPass/Rewrite modules and SiteAccess Product method. It looked to work fine but then I realized that the forms are not submitting correctly. When I click a submit button it do goes to the correct page but no data is passed to it, it´s like there was no Post at all. Anyone knows something about this? Regards ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] problems with the export
Something strange happened when I tried to export a site. I tried many times but none worked. Anyone knows what could this be? Here follows the Zope error message: Zope Error Zope has encountered an error while publishing this resource. Error Type: AttributeError Error Value: Astral Troubleshooting Suggestions The URL may be incorrect. The parameters passed to this resource may be incorrect. A resource that this resource relies on may be encountering an error. For more detailed information about the error, please refer to the HTML source for this page. If the error persists please contact the site maintainer. Thank you for your patience. Traceback (innermost last): File D:\Zope\lib\python\ZPublisher\Publish.py, line 214, in publish_module File D:\Zope\lib\python\ZPublisher\Publish.py, line 179, in publish File D:\Zope\lib\python\Zope\__init__.py, line 202, in zpublisher_exception_hook (Object: ElementWithAttributes) File D:\Zope\lib\python\ZPublisher\Publish.py, line 165, in publish File D:\Zope\lib\python\ZPublisher\mapply.py, line 160, in mapply (Object: manage_exportObject) File D:\Zope\lib\python\ZPublisher\Publish.py, line 102, in call_object (Object: manage_exportObject) File D:\Zope\lib\python\OFS\ObjectManager.py, line 450, in manage_exportObject (Object: ElementWithAttributes) File D:\Zope\lib\python\OFS\ObjectManager.py, line 226, in _getOb (Object: ElementWithAttributes) AttributeError: (see above) Regards Fabio Akita - Developer F/Nazca S&S / Adversiting [EMAIL PROTECTED] ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] namespace and PARENTS doubt
Hi again That may be a simple doubt but that´s it: 'commands' The above statement just doesn´t work. The 'parameter' is a DTML variable in the global namespace. But if I try: That will work. What I am trying to do is to execute the " 'commands'." above for lot´s of 'parameter' folders. But the _['PARENTS[1].' + 'something'] trick doesn´t work. Is there another way to make the first statement work? (maybe I was a bit confusing here, I hope you understand the problem) Regards ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] the "manage_" methods
Hello I am trying to realize how the manage_ DTML methods works. The only documentation that I found was a quick reference that just say that the methods exist with simple descriptions as: manage_addDTMLMethod(id, [title, file, REQUEST, submit]) But there is no details about how this works, what´s required. Is there any documentation about them? I am trying to do a webpage that can change the content of properties of a folder. Regards. []´s Fabio Akita - Developer F/Nazca S&S / Adversiting [EMAIL PROTECTED] ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] WebServers with Exotic Features
Hello once again (sorry for bothering so much) I've found the solution for part of the question I wrote some minutes ago :) RewriteCond %{HTTP_HOST}^zope\.server\.com\.br RewriteRule ^(.*) /zope$1 [P,R] RewriteCond %{HTTP_HOST}^iis\.server\.com\.br RewriteRule ^(.*) /iis$1 [P,R] ProxyPass /zope/ http://www.server.com.br:8080/ ProxyPassReverse /zope/ http://www.server.com.br:8080/ ProxyPass /iis/ http://www.server.com.br:8060/ ProxyPassReverse /zope/ http://www.server.com.br:8060/ That did the job of the correct URL reassignment between apache/IIS/ZServer. But the Proxy Static Cache issue still continue. I did not understand very well the explanation given in the Apache WebSite (http://www.apache.org/docs/misc/rewriteguide.html) under the section "On-the-fly Content-Regeneration", which gives the following example: RewriteCond %{REQUEST_FILENAME} !-s RewriteRule ^page\.html$ page.cgi [T=application/x-httpd-cgi,L] What this means? Maybe that for each static page.htm that I want I need a separate page.cgi? Is this only cgi-compliant? Can it be linked with the Proxy? Or maybe I am completely wrong and the Proxy alone is able to do the Static Cache I need? Just to be more specific: I will have content that will change only on a daily basis, so I do not want the ZServer to dinamically generate the same page all day long. If the Rewrite or the Proxy modules could handle the cache of the page it will be very handy as I will not have to use Squid and can stay with the Apache alone. Regards >Hello again. More problems to be solved :) > >Now I've been trying some exotic things:) The tests are still going on in a >NT machine. > >Here's what I'd like to do : I have installed Apache for NT (yes, I know it's >still beta but I am waiting for a new Linux server that will be here in a few >days :) on default port 80. I also configured IIS to be on port 8090 and ZServer >to be on it's default port 8080. > >I'd like to do the following things using the Rewrite module : Point zope.server.com >to www.server.com:8080 and point iis.server.com to www.server.com:8090. I tried >things like these: > >RewriteCond %{HTTP_HOST} ^zope\.server\.com >RewriteRule ^(.*) http://zope.server.com:8080$1 [R] > >But if I do this the user will see http://zope.server.com:8080/page.htm written >in his's browser instead of http://zope.server.com/page.htm, which I'd prefer. > > >I am trying to ally this to the Proxy Reverse module to accomplish this result >(and I wouldn't like to use the pcgi version of Zope, I prefer to try ZServer). >The ProxyPass alone do part of the job, when Zope has the Site Access Product, >but cannot accomplish all of these goals. > >The other thing is that I'd like to add the static cache feature of the Rewrite >module. Something as the following example: > >RewriteCond %{REQUEST_FILENAME} !-s >RewriteRule ^page\.html$ page.cgi [T=application/x-httpd-cgi,L] > >I'll use the pcgi version if there's no other way and I still want the URL hidding >feature (zope.server.com instead of www.server.com:8080). If all these really >work fine maybe the Apache could be a better alternative to Squid, mainly because >of it's well known robustness, flexibility and log accuracy. > >Maybe some of the things I am trying to do will be impossible, but it's exciting >trying to do such things :) If someone know some of these features (mainly, >I'd like to know more about the static cache feature and Rewrite+ProxyPass modules). >And the NT machine is still just for tests, so maybe the Linux version of Apache >can give me more flexibility as I am already used to it. > >Thanks. > >___ >Zope maillist - [EMAIL PROTECTED] >http://lists.zope.org/mailman/listinfo/zope >** No cross posts or HTML encoding! ** >(Related lists - > http://lists.zope.org/mailman/listinfo/zope-announce > http://lists.zope.org/mailman/listinfo/zope-dev ) > > ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] WebServers with Exotic Features
Hello again. More problems to be solved :) Now I've been trying some exotic things:) The tests are still going on in a NT machine. Here's what I'd like to do : I have installed Apache for NT (yes, I know it's still beta but I am waiting for a new Linux server that will be here in a few days :) on default port 80. I also configured IIS to be on port 8090 and ZServer to be on it's default port 8080. I'd like to do the following things using the Rewrite module : Point zope.server.com to www.server.com:8080 and point iis.server.com to www.server.com:8090. I tried things like these: RewriteCond %{HTTP_HOST}^zope\.server\.com RewriteRule ^(.*) http://zope.server.com:8080$1 [R] But if I do this the user will see http://zope.server.com:8080/page.htm written in his's browser instead of http://zope.server.com/page.htm, which I'd prefer. I am trying to ally this to the Proxy Reverse module to accomplish this result (and I wouldn't like to use the pcgi version of Zope, I prefer to try ZServer). The ProxyPass alone do part of the job, when Zope has the Site Access Product, but cannot accomplish all of these goals. The other thing is that I'd like to add the static cache feature of the Rewrite module. Something as the following example: RewriteCond %{REQUEST_FILENAME} !-s RewriteRule ^page\.html$ page.cgi [T=application/x-httpd-cgi,L] I'll use the pcgi version if there's no other way and I still want the URL hidding feature (zope.server.com instead of www.server.com:8080). If all these really work fine maybe the Apache could be a better alternative to Squid, mainly because of it's well known robustness, flexibility and log accuracy. Maybe some of the things I am trying to do will be impossible, but it's exciting trying to do such things :) If someone know some of these features (mainly, I'd like to know more about the static cache feature and Rewrite+ProxyPass modules). And the NT machine is still just for tests, so maybe the Linux version of Apache can give me more flexibility as I am already used to it. Thanks. ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] sequence-item as a method argument
Hello again I´m still testing the usability and reliability of Zope. To accomplish this goal I am developing a very very simple shopping cart. But I got troubled by something aparently simple. This is the code: SESSION['cartItems'] is an array created in another DTML document using the well known SQLSession product. Here I am retrieving the itens of this array and passing it to a ZSQL method to get the selected items. The sqlSearchProduct, alone, works well. If I substitute the inner for a simple the block works fine, otherwise it gives me the following error: Zope has encountered an error while publishing this resource. Error Type: NameError Error Value: sequence Anyone knows what is going on? I think this must be a simple thing. Thanks []´s Fabio Akita - Developer F/Nazca S&S / Adversiting [EMAIL PROTECTED] ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] Zope, Apache/NT, Reliability issues
Hello I am a developer and we are studying the possibility of adopting Zope as a production platform for our clients. Actually I use PHP, Perl and ASP as server-side "platforms" and I will also be testing WebObjects although I have to say that Zope interested me much more as a programmer ^_^ Until now I have read lots of documentations, DTML looks good enough and I learned a lot about Python. But there are still some doubts that no online document could solve easily. Concerning the installation I´d like to know if anyone knows (or knows some document that details about) the essencial differences between the many ways of installing Zope. I´ve used the ZServer in stand alone mode and I also have implemented the easy Proxy Reverse trick in Apache. I will try FastCGI and PCGI as soon as possible, but I have some doubts now. My test platform is a Windows NT 4 running Apache 1.3.12. The first doubt comes to the fact that I could not find the pcgi module for NT (I do not have any kind of C compiler, so I´ll be very glad if anyone know a binare version). So I´d like to know where can I find informations about installing Zope using PCGI in an NT Apache installation. The second doubt: what exactly are the differences of running it in PCGI mode or in ZServer? I do understand the concept of forking a process and interfacing a web server and a process through a CGI interface as PCGI and I also understand the fact of the multithreading feature in ZServer. Basically it would mean that each connection request will fork a new Zope connection and then maintain it in some kind of a connection pool (as databases do)? Or will there be only one process running Zope and a queue of requests to access it? What are the performance impacts, what are the hardware (memory/CPU) impacts? Personally I do not like the concept of CGI but know nothing about the Persistent CGI concept. And what about the method of "masquerading" the ZServer through Apache? I have read solutions using the Rewrite module and the Proxy module, but it actually means (roughly speaking) that if there are 10 requests made to Apache then it will make 10 requests to ZServer so, considering only the reliability issue of the server even if Apache can handle millions of requests per second, the ZServer would fall down much faster than that so I cannot see any advantage of using Apache in front of it. Of course I understand the other advantages of Apache as it´s many configuration options, robustness as a web server, etc, but can the ZServer stay up and running in pair with Apache? Maybe there´s any way to configure Apache to cache the pages -- as a Squid would -- so it can "filter" the requests and low the requests level that it will do to ZServer? And what about it´s object oriented database? I also have some doubts about it. I worked a lot with relational databases as MS SQL and MySQL but never tried to study an OO approach to DB. How fast it is? How much requests can it handle without hanging, collapsing or corrupting data? I mean, anyone tried to do some study of a database that changes everytime and have queries everytime, I mean, searches in a database where it´s data changes constantly (searching a static database is much different than searching on a mutable one). Row level locking, transaction, consistency, etc, all these concepts apply here? Can it be substituted by a traditional relational database and have it´s contentes interfaced to "looks like" object oriented? The reliability issue is important as I would´t like to have to write a cron to verify if the server is up and running and, if not, kill all of it´s processes and start all over again. It´s not professional, it´s just an ugly band-aid. Actually the PCGI module for NT is not that important as I do prefer working with Apache on Linux but some of our clients prefer working on NT as much of it´s products are already up and running on NT, so Zope on NT would be the preferred option (is Zope+NT as stable as Zope+Linux, only talking about the web server robustness). Well, these are my doubts for now. Thanks for the attention. I hope we can do some interesting discussion. []´s Fabio Akita - DeveloperF/Nazca S&S / Adversiting