Ben Nadel
On User Experience (UX) Design, JavaScript, ColdFusion, Node.js, Life, and Love.
I am the chief technical officer at InVision App, Inc - a prototyping and collaboration platform for designers, built by designers. I also rock out in JavaScript and ColdFusion 24x7.
Meanwhile on Twitter
Loading latest tweet...
Ben Nadel at CFUNITED 2009 (Lansdowne, VA) with:

Could Not Unlock The Names Lock "GOOGLE.TXT" Because No Lock Is Known By That Name

By Ben Nadel on
Tags: ColdFusion

I just had this error sent to me:

Could not unlock the named lock GOOGLE.TXT because no lock is known by that name.

I have absolutely no idea what this means. When I look at the chunk of code that seems to have triggered it, given the stack trace and ColdFusion tag context, it seems it was this CFLock tag:

  • <cflock
  • timeout="5"
  • throwontimeout="false"
  • name="google.txt"
  • type="EXCLUSIVE">
  •  
  • <cffile
  • action="APPEND"
  • file="#GetDirectoryFromPath( GetCurrentTemplatePath() )#google.txt"
  • output="#LOCAL.QueryValue#"
  • addnewline="true"
  • fixnewline="false"
  • />
  •  
  • </cflock>

But what about that could cause the error? And why would ColdFusion attempt to unlock a lock that had no name? I can only assume that the server was having a bit of trouble (hanging or about to shut down) and just "could not compute." The way I figure it, the only reason it would go to Unlock a lock would be in the close of a CFLock tag. However, if that was the case, surely the CFLock tag would know its own name??? Very curious.

Here is some of the stack trace if you are interested:

coldfusion.runtime.LockManager$UnknownLockException: Could not unlock the named lock .....GOOGLE.TXT because no lock is known by that name. at coldfusion.runtime.LockManager.releaseNamedLock(LockManager.java:89) at coldfusion.tagext.lang.LockTag.doFinally(LockTag.java:209) at cfApplication2ecfc1429649158$funcONSESSIONSTART.runFunction



Reader Comments

Is this code recently written? the name google.txt seems strange to me, only because it possibly may be that cf is thinking that is a variable of some sort?

Does it error every time, or just once in a blue moon?

Reply to this Comment

first thing that strikes me is the use of a "." in the name, maybe its causing a problem. I know it should be a string but maybe under the hood in java its freaking it out.

Reply to this Comment

google has a cached version of this error. Doesnt look like the "." is the cause as this guys lock has a different name

http://216.239.59.104/search?q=cache:mhw3IYXq4pAJ:www.helpdesk.umd.edu/os/unix/applications/pine/394/+%22Could+not+unlock+the+named+lock+%22+%22because+no+lock+is+known+by+that+name%22&hl=en&ct=clnk&cd=2

Reply to this Comment

Post A Comment

You — Get Out Of My Dreams, Get Into My Comments
Live in the Now
Oops!
Comment Etiquette: Please do not post spam. Please keep the comments on-topic. Please do not post unrelated questions or large chunks of code. And, above all, please be nice to each other - we're trying to have a good conversation here.