ColdBox Forums Notification: Post to Interceptors issue and suggestion...

Title: Interceptors issue and suggestion...
Thread: Interceptors issue and suggestion...
Forum: Enhancements
Conference: ColdBox
User: CaptainPalapa Luis,

While writing some interceptors this morning to fire on
AfterConfigurationLoad(), I noticed that every time I tried to issue a trace, I
got the error "SESSION is not defined". Now, that makes sense, since this is
all from the onAppInit call loadColdbox() in the application.cfc and
onSessionStart hasn't fired yet.

My suggestion is, if possible, to still
allow trace calls (via the logger plugin), but if, in those items, you can
detect that NOT isDefined("SESSION"), then perhaps the tracers can be queued up
some other way, until the session storage is available. I believe the logger
plugin calls the sessionStorage plugin, and...well, you see the point.

What I
did, even though it makes no sense to have any of it now, was to wrap the trace
in a:
[code]
<cfif isDefined("session")>
  <cfset
getPlugin("logger").tracer("AfterConfigurationLoad in testInterceptor firing.")
/>
</cfif>
[/code]

Just FYI, thought you might want to know about this.
- Will B.
http://www.luismajano.com/forums/index.cfm?event=ehMessages.dspMessages&threadid=C2256A0C-FF65-CEF6-65D2402ACC8B793D