Hi Gang!
I'm running into a little snag right now involving using cache
evaluation on a TQL query. My query is relatively simple, however it
looks like it's intermittently losing it's reference to a cached
version of the compiled SQL statement in Transfer. What I'm trying to
figure out is the reason for this.
My query looks like this:
<cfset query = getTransfer().createQuery("from template.SMSTemplate as
t where t.name = :name and t.active = :active and t.parentTemplateID
is null") />
<cfset query.setParam('active', 1, 'boolean') />
<cfset query.setParam('name', 'whatever name', 'string') />
<cfset query.setCacheEvaluation(true) />
<!--- pull out our queryset --->
<cfset qTemplateID = getTransfer().listByQuery(query) />
Relatively simple query, however it's intermittently giving me the
following error in my logs (doesn't appear to follow any real pattern
for when it happens, but the errors appear to happen in clusters):
"Information","cfthread-7","02/24/10","14:42:18","GSS_MESSENGER","Error
in action on incoming message => [Cannot find
java.lang.ref.softrefere...@9aa4a2 key in structure.] [The specified
key, java.lang.ref.softrefere...@9aa4a2, does not exist in the
structure.] [] [[{ID={CF_CFPAGE},COLUMN={0},TEMPLATE={C:\nwmdev\apache
\Apache2\htdocs\workspace\frameworks\transfer11\com\tql\collections
\EvaluationCache.cfc},RAW_TRACE={ at
cfEvaluationCache2ecfc344983282$funcREAP.runFunction(C:\nwmdev\apache
\Apache2\htdocs\workspace\frameworks\transfer11\com\tql\collections
\EvaluationCache.cfc:81)},TYPE={CFML},LINE={81}},
{ID={CF_UDFMETHOD},COLUMN={0},TEMPLATE={C:\nwmdev\apache\Apache2\htdocs
\workspace\frameworks\transfer11\com\tql\collections
\EvaluationCache.cfc},RAW_TRACE={ at
cfEvaluationCache2ecfc344983282$funcHAS.runFunction(C:\nwmdev\apache
\Apache2\htdocs\workspace\frameworks\transfer11\com\tql\collections
\EvaluationCache.cfc:30)},TYPE={CFML},LINE={30}},
{ID={CF_TEMPLATEPROXY},COLUMN={0},TEMPLATE={C:\nwmdev\apache
\Apache2\htdocs\workspace\frameworks\transfer11\com\tql
\SelectStatement.cfc},RAW_TRACE={ at
cfSelectStatement2ecfc38660934$funcSELECTSTATEMENT.runFunction(C:
\nwmdev\apache\Apache2\htdocs\workspace\frameworks\transfer11\com\tql
\SelectStatement.cfc:83)},TYPE={CFML},LINE={83}},
{ID={CF_TEMPLATEPROXY},COLUMN={0},TEMPLATE={C:\nwmdev\apache
\Apache2\htdocs\workspace\frameworks\transfer11\com\tql
\TQLManager.cfc},RAW_TRACE={ at
cfTQLManager2ecfc1352251664$funcEVALUATEQUERY.runFunction(C:\nwmdev
\apache\Apache2\htdocs\workspace\frameworks\transfer11\com\tql
\TQLManager.cfc:28)},TYPE={CFML},LINE={28}},
{ID={CF_TEMPLATEPROXY},COLUMN={0},TEMPLATE={C:\nwmdev\apache
\Apache2\htdocs\workspace\frameworks\transfer11\com
\Transfer.cfc},RAW_TRACE={ at
cfTransfer2ecfc1351268847$funcLISTBYQUERY.runFunction(C:\nwmdev\apache
\Apache2\htdocs\workspace\frameworks\transfer11\com\Transfer.cfc:
564)},TYPE={CFML},LINE={564}},
{ID={CF_TEMPLATEPROXY},COLUMN={0},TEMPLATE={C:\nwmdev\apache
\Apache2\htdocs\workspace\cfc\com\nextweb\mobile\gss\service
\TemplateService.cfc},RAW_TRACE={ at
cfTemplateService2ecfc651746452$funcGETDEFAULTTEMPLATEIDBYNAME.runFunction(C:
\nwmdev\apache\Apache2\htdocs\workspace\cfc\com\nextweb\mobile\gss
\service\TemplateService.cfc:251)},TYPE={CFML},LINE={251}},
{ID={CF_UDFMETHOD},COLUMN={0},TEMPLATE={C:\nwmdev\apache\Apache2\htdocs
\workspace\cfc\com\nextweb\mobile\gss\service
\TemplateService.cfc},RAW_TRACE={ at
cfTemplateService2ecfc651746452$funcGETTEMPLATEIDBYNAME.runFunction(C:
\nwmdev\apache\Apache2\htdocs\workspace\cfc\com\nextweb\mobile\gss
\service\TemplateService.cfc:192)} ...
I'm not sure what could cause this to happen, however it only seems to
happen in one place in the application. It's failing in a block that
takes some information collected from the URL along with a loaded
service object and fires it off in a CFTHREAD for async processing.
Do you think that it could possibly be an issue from being executed
from within CFTHREAD? When I'm firing off the thread to process the
action that's intermittently failing from the above error(s), the
service object that is passed in is loaded with a reference to the
TransferFactory which is living in the application scope.
So, in summary, here's what's happening:
1.) Request comes in, some information is collected and a service
object is created with a reference to Transfer (which resides in
APPLICATION (which is persisted for 12 hours)).
2.) The information that is collected and the service object are
passed into a uniquely named CFTHREAD for asyc processing.
3.) The service object processes the data collected in the cfthread
and hits the database (and cached Transfer objects) for validation,
etc. During that process the TQL query listed above is executed (with
useCacheEvaluation turn on).
4.) This process intermittently fails giving an error similar to the
above listed block from our logs.
Anyone have any thoughts as to why this might be happening? I've been
playing with it for a day now and I'm getting frustrated.
Thanks!
Nick Haggmark
--
Before posting questions to the group please read:
http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer
You received this message because you are subscribed to the Google Groups
"transfer-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/transfer-dev?hl=en