Skip navigation
silviasalsa
Currently Being Moderated

what are cf Application Variables?

Oct 23, 2007 1:56 PM

what are cf Application Variables?

SessionVariables?
ServerVariables?
clientVariables?
any otherVariables?

what are locking and how is it significant to these variables?

what do you lock and what reasons to lock and how many locks? common locks?

how are all these relevant when a cf program crashes?


i ask because i am a beginner and the seniors were talking about these issuse but was not defined and clear to me.

Thanks
 
Replies
  • Currently Being Moderated
    Oct 23, 2007 2:14 PM   in reply to silviasalsa
    I will leave it to others to point to the entire chapters in the
    documentation that discusses these issues as well as innumerable blogs,
    white papers and discussion lists and give the 10 second rundown.

    Normal HTTP request-response are stateless. No data is persisted from
    one request to the next under normal conditions. To allow data to
    persist ColdFusion (and most other web languages in one way or another)
    create persistent scopes. ColdFusion offers several levels and varietes
    of scopes to persist data; server, application, session, client and
    cookie to name some and request sort of in a way.

    Each of these scopes of different purposes and characteristics. Some
    are specific to a user (session and client) some to an application
    (application) and some to an entire server (server). Some are stored in
    memory on the server (session, application and server) some on the
    client either in memory or a file (cookie).

    Locking is a concept to protect data from race conditions. Since web
    applications can be accessed by multiple people from multiple locations
    at the same time, sometimes applications can attempt to change the data
    in a common variable to different values at the same time. Sometimes
    this can cause serious consequences to an application, i.e a race
    condition. When this is the case, locking can be employed to only allow
    the value of a variable to be changed one at a time, but this can have
    serious performance consequences so adjudication needs to be used on
    when and how much should be locked at any given point. In versions past
    (pre-CF5) there where bugs and problems with the global scopes like
    server, application and session so universal locking with was a
    workaround to avoid these problems.

    Ok, that took way more then 10 seconds. You can see this is a big
    topic. If you are a beginner who wishes to learn more, I highly
    recomened reading the documentation and other published material. Then
    if you have specific questions about certain aspects of what you read we
    can help clarify the concepts.

    Usually such broad and global questions do not receive much positive
    responses from a list such as this.



     
    |
    Mark as:
  • Currently Being Moderated
    Oct 23, 2007 2:15 PM   in reply to silviasalsa
    Start here and here.

    Phil
     
    |
    Mark as:
  • Currently Being Moderated
    Oct 23, 2007 2:29 PM   in reply to silviasalsa
    In addition to the links paross1 provided, you might just ask your senior developers to walk you through some code.
     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)