September 2007
Intermediate to advanced
600 pages
20h 21m
English
Now that you know what race conditions are and how they can lead to unpredictable results, it’s time to learn how to use locking to avoid them. We’ll get into the nuances shortly, but the basic idea is to place opening and closing <cflock> tags around any part of your code that changes application variables (or session variables, which are discussed in the next chapter) or any other type of information that might be shared or changed by concurrent page requests. Table 19.5 takes a closer look at the tag’s syntax.
| Attribute | Description |
|---|---|
| type | Optional. The type, or strength, of the lock. Allowable values are Exclusive and ReadOnly. You should use Exclusive to indicate blocks of code that change the ... |
Read now
Unlock full access