Why does Zope run multiple instances of z2.py by default?
Hi, I was just wondering why Zope runs multiple threads of z2.py by default? For example in my ps listing I have: zope 18183 1 0 10:25 ? 00:00:00 /home/zope/Zope/bin/python /home/zope/Zope/z2.py -u zope -f - p - zope 18184 18183 0 10:25 ? 00:00:10 /home/zope/Zope/bin/python /home/zope/Zope/z2.py -u zope -f - p - However one of my colleagues only has a single zope instance appear in his ps listing on his machine. His zope installation still runs fine. We are running Zope on Red Hat Linux 9. Does something like this make a difference? Thanks Tim Edwards Trainee Analyst Programmer Henry Walker Eltin Phone: 02 9887 6327 Fax: 02 9887 2412 Email: tim.edwards@hwe.com.au
--On Donnerstag, 20. November 2003 17:54 Uhr +1100 Tim Edwards <Tim.Edwards@hwe.com.au> wrote:
Hi,
I was just wondering why Zope runs multiple threads of z2.py by default? For example in my ps listing I have:
Because Zope is multi-threaded!? -aj
And you can control the amount of threads in the "start" script. There is plenty of documentation on this in the z2.py in the root of your zope install. 2.7 handles it in the config area which I am just learning about. :) Jake -- http://www.ZopeZone.com Andreas Jung said:
--On Donnerstag, 20. November 2003 17:54 Uhr +1100 Tim Edwards <Tim.Edwards@hwe.com.au> wrote:
Hi,
I was just wondering why Zope runs multiple threads of z2.py by default? For example in my ps listing I have:
Because Zope is multi-threaded!?
-aj
_______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Andreas Jung wrote:
--On Donnerstag, 20. November 2003 17:54 Uhr +1100 Tim Edwards <Tim.Edwards@hwe.com.au> wrote:
I was just wondering why Zope runs multiple threads of z2.py by default? For example in my ps listing I have:
Because Zope is multi-threaded!?
And because Linux represents threads as processes. But they're still threads, as you'll see if you kill the parent. (You should also notice that all the statistics are the same.) You can understand the relationship between these by doing a ps auxf --jcc -- "Code generators follow the 80/20 rule. They solve most of the problems, but not all of the problems. There are always features and edge cases that will need hand-coding. Even if code generation could build 100 percent of the application, there will still be an endless supply of boring meetings about feature design." (http://www.devx.com/java/editorial/15511)
Tim Edwards wrote at 2003-11-20 17:54 +1100:
I was just wondering why Zope runs multiple threads of z2.py by default? For example in my ps listing I have:
zope 18183 1 0 10:25 ? 00:00:00 /home/zope/Zope/bin/python /home/zope/Zope/z2.py -u zope -f - p - zope 18184 18183 0 10:25 ? 00:00:10 /home/zope/Zope/bin/python /home/zope/Zope/z2.py -u zope -f - p -
In standard setup (under Unix), you have a "daemon" and the true Zope process (with several threads). The daemon supervises the Zope process. If Zope should die unexpectedly, the daemon logs a message and restarts Zope. There is a "z2.py" option that causes the daemon not to start. -- Dieter
On Thu, Nov 20, 2003 at 05:54:30PM +1100, Tim Edwards wrote:
Hi,
I was just wondering why Zope runs multiple threads of z2.py by default? For example in my ps listing I have:
zope 18183 1 0 10:25 ? 00:00:00 /home/zope/Zope/bin/python /home/zope/Zope/z2.py -u zope -f - p - zope 18184 18183 0 10:25 ? 00:00:10 /home/zope/Zope/bin/python /home/zope/Zope/z2.py -u zope -f - p -
However one of my colleagues only has a single zope instance appear in his ps listing on his machine. His zope installation still runs fine. We are running Zope on Red Hat Linux 9. Does something like this make a difference?
Zope forks the process early onwards; one daemon process, one controller. This can be controlled using the -Z command line option. See z2.py -h for info on that option. -- Martijn Pieters | Software Engineer mailto:mj@zope.com | Zope Corporation http://www.zope.com/ | Creators of Zope http://www.zope.org/ ---------------------------------------------
participants (6)
-
Andreas Jung -
Dieter Maurer -
J Cameron Cooper -
Jake (aka BZ) -
Martijn Pieters -
Tim Edwards