--- Freddy <[EMAIL PROTECTED]> wrote:
> Let me see. A scalable app that uses session
> vaiables? Try an application that
> delivers personalized content. Store a cookie that
> logs the user in on entry to
> the site. It then retrieves a list of links, images,
> and pertinent user info
> that is stored in session variables. If the user
> moves to a different server on
> the cluster it makes one more database call to
> repopulate the session variables.

What do you do when the one of those session variables
needs to have it's value changed?  How do you do it on
both servers?  I've been in this situation.  Why do I
need to reinvent the wheel just to do something like
this?  And, if they're constants, why not put them in
the request or variables scope?  Why bother with all
that locking?  More lines of code = more chances of
bugs.

> 
> No this isn't mission critical. However not all
> applications are. It is a large
> application on a very busy site. It has worked
> flawlessly for the past year. One
> critical application has had troubles and is in need
> of a major re-write (it
> hasn't even been deployed yet). This was done by a
> contractor at my full time
> workplace. They used over a hundred session
> variables. I told them not to do it
> that way it was not a well thought out method but
> managment wouldn't listen,
> they wanted it fast and the contractor was not very
> familiar with many other
> methods to accomplish the requirments. (actually I
> recomended using wddx)
> 
> It seems to me there are many applications that are
> not going to have to scale.
> It depends on the project. I always have tried to
> impress upon a client that
> they may not want this (scalability) now they may in
> the future. It isn't
> something you "add on" later. I have been told many
> times they are not going to
> go to a server cluster so why spend the extra time
> and money building an
> application for it? Some clients change their minds,
> but they are in the
> minority.

Thank you for agreeing with me.  I would add that an
app is never mission critical until it breaks.

> 
> Small shopping cart applications can use session
> variables to maintain state in
> an application in association with cookies. I have
> built some very stable
> applications that do just that and the client again
> has had no problems.

And I as well have written many apps with session vars
that are perfectly stable.

> 
> I am simply saying that session variables are not a
> horrible thing when used
> correctly. They work "as advertised" it is up to the
> developer to know how and
> when to use them. I look at  session variables like
> a motor scooter, great to go
> down the street to the market and grab a coke and 
> some chips but I wouldn't try
> to use it to go pick up a big screen tv. For that
> I'd use a van. The trick is to
> know where your going before you choose how to get
> there.

My point is that many people don't know this.  If I
can help it, I avoid using session vars, simply
because of all the coding overhead, which increases
the probability of bugs (and not "easy-to-find" bugs).
 Session vars are like a scooter that requires
training wheels, special fuel, and an attachment that
prevents one scooter from passing another scooter. 
And hey, it's up to you to make sure all that stuff's
there.  This is not something that's condusive(sp?) to
good programming.




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. http://www.fusionauthority.com/ads.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to