How NOT to Code - Challenge 14

Feb 12, 2010

Today's challenge is in ColdFusion and it's very simple. It's actually fine to use this code if you understand what it does. The problem is that it's the worse named and one of the least understood tags in cfml. For example, many shared hosting providers leave this tag active for their users.

So what do you think this call does?

<cfobjectcache action = "clear"/>


Amar Trivedi

Amar Trivedi wrote on 02/12/104:41 PM

That will kill all the cached objects across applications. CFOBJECTCACHE will kill all cached queries in App1, App2 and all other apps. This can be HUGE performance issue if apps are dealing with large data sets.

Write your comment

(it will not be displayed)