Well from what I have read so far as it pertains to reading variables in the
memory, it's ok to not lock them. You don't want to get overzealous with
locking, it does have an impact on performace. What is the summattion with
CFLOCK? I am doing a presentation at the CFUG in Orlando Thursday at 7 pm at
the IT Research building (a shameless plug I know) and I think I have it
down pretty good I would just like to know what the rest of the community
agrees on. Some of the things I have summed up are:
CFLOCK should be used on writes of session,server, and application variables
CFLOCK should be used on reads of CFX_Tags (though I just saw that so I am
not sure about that)
Locking should not be initiated at server level as it will severly impede
performance
Reading memory variables is ok as long as you are sure that the write to
them has been locked
ANything else to add?
Robert Everland III
Web Developer
Dixon Ticonderoga
-----Original Message-----
From: DJMixes.Com [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, August 02, 2000 12:16 AM
To: [EMAIL PROTECTED]
Subject: Re: More CFLOCK
Ok, thanks for that. I though I was getting the hang of it till I came
across a huge cfif with a few application and sesion vars in it.
starts like this
<CFIF #STRUCTKEYEXISTS(APPLICATION.USERSLOGGEDIN, USERIDATDOOR)#>
more application settings
more session settings
more
more
</cfif>
I can't just lock the whole cfif, can I?
I think Ben needs to write a book on just locking in cf. :)
Derek
"Seth Petry-Johnson" <[EMAIL PROTECTED]> wrote in message
news:<00a901bffc18$4107ad20$[EMAIL PROTECTED]>...
> > Does anyone know how to go about locking this line?
> >
> > <CFSET APPLICATION.USERSLOGGEDIN["#Session.UserID#"].TIMECREATED =
NOW()>
>
> <!--- create copy of Session.UserID --->
> <!--- substitute SCOPE param for NAME if using CF 4.5 --->
> <CFLOCK NAME="#Session.SessionID#" TYPE="readonly" TIMEOUT="30">
> <CFSET localUserID = Session.UserID>
> </CFLOCK>
> <!--- now write the application param --->
> <CFLOCK NAME="#Application.ApplicationName#" TYPE="readonly" TIMEOUT="30">
> <CFSET UsersLoggedIn[localUserID].TimeCreated = Now()>
> </CFLOCK>
>
> Regards,
> Seth Petry-Johnson
> Argo Enterprise and Associates
>
>
> --------------------------------------------------------------------------
----
> Archives: http://www.mail-archive.com/[email protected]/
> To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.
----------------------------------------------------------------------------
--
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.
------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.