tracker issue : CF-3037000

select a category, or use search below
(searches all categories and all time range)
Title:

Bug 74109:(Watson Migration Closure)Method calls on VARIABLES scope CFCs do not scale linearly

| View in Tracker

Status/Resolution/Reason: Closed/Won't Fix/LowImpact

Reporter/Name(from Bugbase): Sean Corfield / Sean Corfield (Sean Corfield)

Created: 12/09/2008

Components: Language, CF Component

Versions: 9.0

Failure Type: Unspecified

Found In Build/Fixed In Build: 0000 /

Priority/Frequency: Major / Unknown

Locale/System: English / Platforms All

Vote Count: 1

Problem:

Method calls on VARIABLES scope CFCs do not scale linearly.
Method calls on APPLICATION scope CFCs scale linearly but not if they are in VARIABLES scope for some reason.

See Isaac Dealey's blog post: http://ontap.riaforge.org/blog/index.cfm/2008/12/8/CFCWarning
Method:

See Isaac's blog. He provides code examples and workarounds.
<!-----------agent.cfc------------------>



<cfcomponent output="false">
   <cfset instance = structNew() />
   <cfset instance.cache = QueryNew("cachename,content") />
   
   <cffunction name="init" access="public" output="false">
      <cfreturn this />
   </cffunction>
   
   <cffunction name="fetch" access="public" output="false">
      <cfargument name="cachename" type="string" required="true" />
      <cfset var record = 0 />
      
      <cfreturn record />
   </cffunction>
   
   <cffunction name="store" access="public" output="false">
      <cfargument name="cachename" type="string" required="true" />
      <cfargument name="content" type="any" required="true" />
      
      <cfreturn arguments />
   </cffunction>
</cfcomponent>



<!----------------------test.cfm----------------->



<cfset agent = CreateObject("component","agent").init() />
<cfloop index="x" list="100,300,1000,3000">
   <cfset ticks = getTickCount() />
   
   <cfloop index="y" from="1" to="#x#">
      <cfset agent.store("id_#y#","hello world") />
   </cfloop>
   
   <cfset time = getTickCount()-ticks />
   <cfoutput>
      <div>#x# records = #numberformat(time)#ms (#decimalformat(time/x)#ms / record)</div>
   </cfoutput><cfflush />
</cfloop>

Result:

----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3037000

External Customer Info:
External Company:  
External Customer Name: Sean Corfield
External Customer Email: 479B4EDC43F3A88B992016B6
External Test Config: 12/09/2008

Attachments:

Comments:

This bug appears to be bogus. Check the stream of comments on Isaac's blog. No one can reproduce (and I can't either). Given the hanging memory usage Mike Schierberl had identified, I took Isaac's tests at face value but there's obviously something deeper going on in his setup. Feel free to close this.
Vote by External U.
24439 | November 10, 2011 07:06:50 PM GMT