You can begin mulitple threads simply by declaring a frameset.  In that
case, you'll have two or more pages being loaded into their respective
frames with (near) simultaneous calls.  Which means the server can be
responding to either of those calls at any given time.  The problem now
comes when these two (or more pages) make reference to a common session or
applicaiton variable.  Who get's precedence?  What if they are both writing
at the same instance.  This is the reason for locking.

The argument here though is that the server should be able to handle this
locking on the fly, on it's own.

I think this is going come down to a developer style issue - more than one
way to do it, and all of them right because they acheive the same results.

I've yet to see strong arguments why CF Server should not handle the
locking, but then again, I've yet to see strong arguments why the developers
shouldn't handle it.  Hence, I think a compromise is in order, and would
offer the best solution for everyone involved (see my earlier post on this
thread).

My observations, not yours.

Shawn Grover

-----Original Message-----
From: Matthew R. Small [mailto:[EMAIL PROTECTED]]
Sent: Monday, March 18, 2002 3:01 PM
To: CF-Talk
Subject: RE: RE: UDF question


I don't think it's a multi-threaded language because it is not possible
(to my knowledge) to start a new thread and have it run while the main
thread continues execution, then notify the main thread when it's done
executing.  The fact that we need to be concerned about multi-threading
comes into play because the server itself is multi-threaded and those
other threads can affect the performance of a single thread.

As I sit here I'm starting to think that CFML is neither mulit-threaded
nor single threaded.  It's somewhere in between because it has
characteristics of both.  Fractal threaded maybe? :-)


My humble opinion.

Matt Small
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Monday, March 18, 2002 4:38 PM
To: CF-Talk
Subject: Re: RE: UDF question

See below:

----- Original Message -----
From: "Matthew R. Small" <[EMAIL PROTECTED]>
Date: Monday, March 18, 2002 2:33 pm
Subject: RE: UDF question

> The only concurrency issues that seem to come up in CF are when we
> needto single thread any piece of code - that's what the locks do.
> But I
> haven't seen any code at all that allows us to start new threads
> in the
> same page.
Everytime a new user goes onto your web site, a new thread is used for
that user.  So although at the page level, you can't start new threads,
threading certainly exists in CF at the application level.

> As I understand it, C++ is a multi-threaded language.  CFAS is a
> multi-threaded application written in C++.  CFML is a single-threaded
> language that needs to take into account multiple threads on
> occasion.
If CF needs to take into account multiple threads, then it's multi-
threaded capable. :)

>
> Please correct me if I'm wrong.
>
> - Matt Small
>
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Monday, March 18, 2002 4:10 PM
> To: CF-Talk
> Subject: Re: UDF question
>
> CF is merely an abstraction of a crap load of C++ code.
>
> I agree with you on the process that happens when you define a
> variable
> in CF.  I don't see how that absolves the programmer of coming up
> with
> the best way of handling concurrency issues.
>
> Regardless, CF does provide you with many mechanisms of locking
> control.  What really matters is picking the one that suits you,
> and to
> write code that is in line with the decision you've made.
>
>
> ----- Original Message -----
> From: junkMail <[EMAIL PROTECTED]>
> Date: Monday, March 18, 2002 1:18 pm
> Subject: Re: UDF question
>
> > With respect to this issue, comparing CFML to C++ is apples to
> > oranges.
> > I can't expect a low-level language to automatically manage
> > concurrent access
> > to shared memory resources, because I have defined the resources
> > and I have
> > decided how they are to be accessed and shared.   I can't expect
> a
> > such system
> > to be prescient.
> >
> > The situation is different in ColdFusion.  Although I declare
> and
> > use the
> > variables, ColdFusion creates the resources in memory and
> > essentially decides
> > how they are to be accessed and shared.  ColdFusion can AND
> SHOULD
> > manage the
> > concurrency issues.
> >
> > C++ is not a multi-threaded language.  It's a language capable
> of
> > producingmulti-threaded applications, such as ColdFusion.
> >
> > [EMAIL PROTECTED]
> >
> >
> > ----- Original Message -----
> > From: <[EMAIL PROTECTED]>
> > To: "CF-Talk" <[EMAIL PROTECTED]>
> > Sent: Monday, March 18, 2002 1:58 PM
> > Subject: Re: UDF question
> >
> >
> > > Interesting.
> > >
> > > Any language that implements locking (read:  any that are worth
> > > programming in) uses some sort of "sloppy" locking mechanism.
> > Some are
> > > downright evil (read: C++).  Certainly, I can't think of any
> > multi-
> > > threaded languages that handle concurrency automatically.
> >
> >
>
>


______________________________________________________________________
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to