[ColdBox 3.1] Error: The symbol you provided persistVariables is not the name of a function.

I have ColdBox 3.1 deployed on my production site right now. After a recent upgrade to 64-bit Window Server 2008 and 64-bit CF 9, I’ve occasionally seen the below error crop up in the logs when calling setNextEvent from one of my handlers.

That line of Controller.cfc is persistVariables(argumentCollection=arguments); and the persistVariables method is defined right there in that file.

Has anyone else ever seen this error?

Thanks!

~Brad

Application Execution Exception
Error Type: Application : [N/A]
Error Messages: Entity has incorrect type for being called as a function.
The symbol you provided persistVariables is not the name of a function.

ID: ??
LINE: 425
Template: D:\websites\wwwroot\common\coldbox\system\web\Controller.cfc
ID: CF_TEMPLATEPROXY
LINE: 235
Template: D:\websites\wwwroot\common\coldbox\system\FrameworkSupertype.cfc
ID: CF_UDFMETHOD
LINE: 190
Template: D:\websites\wwwroot\common\handlers\ehCheckout.cfc
ID: CFINVOKE
LINE: 694
Template: D:\websites\wwwroot\common\coldbox\system\web\Controller.cfc
ID: CF_UDFMETHOD
LINE: 579
Template: D:\websites\wwwroot\common\coldbox\system\web\Controller.cfc
ID: CF_TEMPLATEPROXY
LINE: 243
Template: D:\websites\wwwroot\common\coldbox\system\Coldbox.cfc
ID: CF_TEMPLATEPROXY
LINE: 99
Template: D:\websites\wwwroot[www.mystar12.com](http://www.mystar12.com)\Application.cfc

Hmm not really I do see some weird stuff once in a while under high load where cf loses scope of some functions.

Luis Majano
CEO
Ortus Solutions, Corp
www.ortussolutions.com

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Social: twitter.com/ortussolutions | twitter.com/coldbox | twitter.com/lmajano

I think I may have figured this out. I found a setNextEvent call in
my code that looked like so:
setNextEvent(
  event='content.ehContent.index'
  ,addToken=false
  ,ssl=SSLService.isSSLRequired('content.ehContent.index')
  ,persistVariables=rc
);

persistVariables is the wrong argument name-- it should have been
persistStruct. That means inside the setNextEvent method in
controller.cfc, arguments.persistVariables was defined as a struct and
when this line was reached:

// persist Flash RAM
persistVariables(argumentCollection=arguments);

it was seeing the arguments-scoped variable, and not the method in the
CFC of the same name.

Thanks!

~Brad