ColdBox 3.0 Latest from GIT

To help test 3.0 before the release, I updated my fork (https://github.com/aarongreenlee/coldbox-platform) with the latest from the master ColdBox repo and am getting an error when a viewlet timesout in the cache.

renderview(view=‘foo’, cache=true, cacheTimeout=5, cacheLastAccessTimeout=5, cacheSuffix=‘en’);

When I revisit my site about 5 min. later I get an error on system/plugins/Renderer.cfc line 127 that “cbox_RenderedView” is undefined; however, it looks like the instance.templateCache.lookup() returned true. I’ve tested this quite a few times since last night and the amount of time does not seem to be an issue. I receive the error 6 min after the initial request, 40min after the initial request, etc…

This is on my local machine and I am the only one making a request so I know I am trying to render an expired view.

If someone could help confirm this, I would appreciate it.

Thanks.

Aaron

Aaron,

Can you redownload from github. I cannot reproduce locally.

Luis F. Majano
President
Ortus Solutions, Corp

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

Bummer. Still getting the error.

Do you see anything wrong with these template cache settings? I think they are pretty stock.

template = {
provider = “coldbox.system.cache.providers.CFColdBoxProvider”
,properties = {
objectDefaultTimeout = 30,
objectDefaultLastAccessTimeout = 30,
useLastAccessTimeouts = true,
freeMemoryPercentageThreshold = 90,
reapFrequency = 2,
evictionPolicy = “LRU”,
evictCount = 2,
maxObjects = 300,
objectStore = “ConcurrentSoftReferenceStore” //memory sensitive
}
}

Thanks.

Aaron

Just this: freeMemoryPercentageThreshold = 90,

Try removing that or setting to 0

Luis F. Majano
President
Ortus Solutions, Corp

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

What is alarming me is that the application has not changed, and the lookup thinks the value is there.

freeMemoryPercentageThreshold = 0, had no effect. I’ll investigate a little deeper.

It may be that the views are not being cached. I’ll debug more in the morning…

Here is my quick inspection:

// DEBUGGING – GREENLEE
writeDump(var={a=cbox_cacheKey,keys=instance.templateCache.getKeys() },top=3,output=expandPath(’/atvlogs/debugging.log’));

// Is the view already cached?
if( instance.templateCache.lookup(cbox_cacheKey) ){
// Render it out
cbox_timerHash = instance.debuggerService.timerStart(“rendering Cached View [#arguments.view#.cfm]”);
cbox_renderedView = instance.templateCache.get(cbox_cacheKey);
instance.debuggerService.timerEnd(cbox_timerHash);
// Post View Render Interception
cbox_iData.renderedView = cbox_RenderedView;
announceInterception(“postViewRender”, cbox_iData);
// Return it
return cbox_iData.renderedView;
}

and then…

// Are we caching view
if ( arguments.cache ){
writeDump(var=‘Caching #cbox_cacheKey#’,top=3,output=expandPath(’/atvlogs/debugging.log’));
instance.templateCache.set(cbox_cacheKey,cbox_iData.renderedView,arguments.cacheTimeout,arguments.cacheLastAccessTimeout);
}

The results follow. It looks like none of the keys I tried to cache were saved.

struct

KEYS:
[array]

  1. ACC_4RELEASES
  2. ACC_4PRODUCTS
  3. ACC_4TOPICS

Aaron,

If you use the free memory threshold, then they won’t be cached because the engine stops you because there is no free memory. You had it at 90, that means that the JVM must have 90% free memory in order to cache. That is pretty much never. I would suggest drop that setting to 0 and re-test.

On my local tests, I can see them on the cache panels, I even added a new feature to the panels to test :slight_smile: You can now expire keys from the cachebox report

Luis F. Majano
President
Ortus Solutions, Corp

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

I’ve changed the settings… but, don’t you think its an issue that the lookup() reported true?

I just can't replicate it though.

Aaron, I posted an enhanced lookup on the concurrent store. I canot
for all I can, reproduce this issue, but I reworked it a little as it
is now cleaner. Can you please try, this is the only issue I have
before 3.0 release on Wedensday

Hi Luis,

I updated to the latest version and after doing a deploy to production (windows, CF clustered multi-instance) I get the following error after I do a deploy. Note: I’m using the deploy interceptor and also forced a fwreinit after deploy. I’ve ran some tests and the error occurs randomly it seems.

Thoughts?

thanks.

N

Oops! Exception Encountered

Application Execution Exception

Error Type: Application : [N/A]
Error Messages: The method getAppStartHandlerFired was not found in component C:\inetpub\wwwroot\myapp\frameworks\coldbox\system\web\Controller.cfc.
Ensure that the method is defined, and that it is spelled correctly.

Tag Context:

ID:

CF_TEMPLATEPROXY

LINE:

222

Template:

C:\inetpub\wwwroot\myapp\frameworks\coldbox\system\Coldbox.cfc

ID:

CF_TEMPLATEPROXY

LINE:

79

Template:

C:\inetpub\wwwroot\myapp\Application.cfc

Framework Snapshot

Current Event:

General.index

Current Layout:

N/A

Current View:

N/A

Bug Date:

03/29/2011 06:44:33 PM

Coldfusion ID:

JSessionID=7c309f1e9f4f78284a0323535911313434f5

Template Path :

C:\inetpub\wwwroot\myapp\index.cfm

Path Info :

/index.cfm/incident/authenticate/

Host & Server:

connect.guardly.com 211010-2

Query String:

Browser:

Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_7; en-US) AppleWebKit/534.16 (KHTML, like Gecko) Chrome/10.0.648.204 Safari/534.16

Remote Address:

205.211.169.2

Form variables:

Session Storage:

Cookies:

CFID:

13202

CFTOKEN:

65947418

JSESSIONID:

7c309f1e9f4f78284a0323535911313434f5

Stack Trace:

coldfusion.runtime.TemplateProxy$InvalidMethodNameException: The method getAppStartHandlerFired was not found in component C:\inetpub\wwwroot\myapp\frameworks\coldbox\system\web\Controller.cfc.
at coldfusion.runtime.TemplateProxy.throwInvalidMethodNameException(TemplateProxy.java:749)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:478)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:337)
at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2360)
at cfColdbox2ecfc574898861$funcPROCESSCOLDBOXREQUEST.runFunction(C:\inetpub\wwwroot\myapp\frameworks\coldbox\system\Coldbox.cfc:222)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:405)
at coldfusion.runtime.UDFMethod$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:491)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:337)
at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2360)
at cfApplication2ecfc1185572755$funcONREQUESTSTART.runFunction(C:\inetpub\wwwroot\myapp\Application.cfc:79)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:405)
at coldfusion.runtime.UDFMethod$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:491)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:337)
at coldfusion.runtime.AppEventInvoker.invoke(AppEventInvoker.java:88)
at coldfusion.runtime.AppEventInvoker.onRequestStart(AppEventInvoker.java:258)
at coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:349)
at coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.java:48)
at coldfusion.filter.MonitoringFilter.invoke(MonitoringFilter.java:40)
at coldfusion.filter.PathFilter.invoke(PathFilter.java:94)
at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:70)
at coldfusion.filter.BrowserDebugFilter.invoke(BrowserDebugFilter.java:79)
at coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:28)
at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
at coldfusion.filter.NoCacheFilter.invoke(NoCacheFilter.java:46)
at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)
at coldfusion.filter.CachingFilter.invoke(CachingFilter.java:62)
at coldfusion.CfmServlet.service(CfmServlet.java:200)
at coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:89)
at jrun.servlet.FilterChain.doFilter(FilterChain.java:86)
at coldfusion.monitor.event.MonitoringServletFilter.doFilter(MonitoringServletFilter.java:42)
at coldfusion.bootstrap.BootstrapFilter.doFilter(BootstrapFilter.java:46)
at jrun.servlet.FilterChain.doFilter(FilterChain.java:94)
at jrun.servlet.FilterChain.service(FilterChain.java:101)
at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:106)
at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
at jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:286)
at jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:543)
at jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.java:203)
at jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:428)
at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)

Extra Information Dump

[N/A]

Make sure that the coldbox bootstrapper is also refreshed. The bootstrapper changed for 3.0 to comply with ColdFusion on Application start.

I would suggest a reboot if possible or do a complete wipe of anything coldbox in application scope.

Luis F. Majano
President
Ortus Solutions, Corp

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

Hi Luis,

I restarted all of the instance and everything seems to be fine now. I will monitor and let you know if the issue occurs.

Thanks.

Nolan