From: "Perrin Harkins" <[EMAIL PROTECTED]>
To: "Greg Cope" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: 13 May 2000 01:57
Subject: Re: speed up/load balancing of session-based sites - POT


: On Sat, 13 May 2000, Greg Cope wrote:
: > : Likewise with sessions. Even if you load balance across multiple
machines
: > : you don't need to access a session database on every request. Most
load
: > : balancing systems have something so they'll send the seme "session"
: > : (typically ip address) to the same backend server for N seconds as
long as
: > : the backend server is up of course.
: > :
: > : You can then put a daemon on each backend server as a local buffer and
: > : cache between the httpds and the session database. This daemon can
even
: > : load balance the session information over several databases if it's
: > : needed.
: > :
: > : viola, a lot less "real time" lookups in the database needed and a lot
: > : less direct connections.
: [...]
: > But - is this model not transaction safe ? - It may save alot of DB use
and
: > hence be alot quicker - but what if the webserver "disappears" halfway
: > through an IP based load ballanced "sesssion" - a potential source of
: > failure - something which a load ballancer is supposed to help with..
: >
: > Also if the loadballance goes south, and a secound takes over does it
have
: > the same IP based session info (probably not - but could be wrong ...) -
: > hence another potential source of failure.
:
: You have to do a write-through cache, i.e. you must write to the database
: as well as the cache, but you only have to READ the database if you don't
: find the session in the cache.  If you have a fair amount of read-only use
: of the session this can be a big win.

Ok - but I find that most of my session stuf updates a "last access"
atribute within the session and hence is mostly read + write - not just read
but YMMV - good point tho.

Greg

:
: - Perrin
:
:

Reply via email to