james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joan Carles" <joancar...@indibil.com>
Subject RE: System Load
Date Mon, 26 Feb 2001 16:17:58 GMT

----- Original Message -----
From: Federico Barbieri <scoobie@betaversion.org>
To: <james-dev@jakarta.apache.org>
Sent: Monday, February 26, 2001 1:37 PM
Subject: Re: System Load


> "Joan Carles Núñez" wrote:
> >
> > Hi,
> >
> >    Ok. Would it be a matter of writing a native C function that queries
system
> > load and call that from the JVM via JNI?
> > Doing this for Linux should be easy, don't know about Windows...
> >
> >        J. C.
> >
>
> On a second though I'm not sure if this can better performances... there
> are mainly three groups of threads... those acceptiong mail (SMTP),
> those processing (mailets) and those providing services (POP3, IMAP).
> In theory acceptiong threads should have always better priority than the
> other two and service threads should be faster than processing threads,
> no matter haw heavy the system load is.
>
> In some extreme situstion it may make sense to freze a group of threads
> (limit the number of active threads in that group):
> If the buffer is full limit accepting threads, if the number of users is
> high limit processing etc.
>
> In all this situation thou I don't see any specific reaction to the
> system load... not sure...

Correct me if I am wrong, here go some thoughts:
It is always desirable that a machine does not go over system load =1. If
this
happens very often then it is a matter of upgrading or adding more servers.
The thing is, the server should handle peak times smoothly without the need
of upgrading.
Sendmail's design is based on forking a process for every request. That's
why
it will stop processing mails (and queue them) when the number of requests
is
very high and the system load goes over 1, it basically concentrates in
keeping
up with requests.
If James creates a new Thread per request then it should apply the same
principle.
All in all, it is a matter of avoiding excesive use of resources (threads,
sockets,
cpu etc).
In the case of RDBMS based queues, processing mail may increase the
load quite a lot. System load indicates the average number of processes held
in
the queue waiting for CPU time. In my experience, when load is very high the
system starts to behave differenly and exponential growth of
threads/sockets/queueing
is a situation that may bring the server down to its knees.

What do you think?

   J. C.









Mime
View raw message