Poor performance with CB 4.2

We are in the process of upgrading a system from Coldbox 3.8 to 4.2. With all the changes in the framework, there are a lot of modifications we are making, but it is actually going very well, with one SIGNIFICANT exception.

We have a REST search service resource that performed very well under 3.8. However, under 4.2 (without any code changes), performance has gone from 1 second to 4 seconds to complete. We have added some metrics (elapsed time via getTickCount() via LogBox messages) and it appears the performance hit is localized to the renderData method (rendering JSON).

By way of a brief explanation, following is the process utilized by the reporting system:

· System determines the report types that need to be returned and the maximum number of total reports (there are numerous types of reports)

· Threads are spawned for each type of report. Each thread returns a collection of reports that matched the criteria as a struct-array

· Threads are joined and the records are aggregated (combined) the sorted into date descending order

· Results are returned using the renderData() as JSON to the client system

Each thread is completing in sub-second. The sorting process is averaging about 500ms (for 1,000 reports). All told the time in system is about 1500ms. However, the response is taking almost 5000ms, with Coldbox 4.2, to be returned to the client. Under 3.8, this process was taking about 2500ms. If we add more report types, the end-to-end is taking 20,000ms (or longer) versus 7,000ms under 3.8!

System is running on Windows Server 2012, with Adobe CF 11 (Updater 9) using SQL Server 2008 R2.

Any ideas? I can provide additional information, if desired.

We are in the process of upgrading a system from Coldbox 3.8 to 4.2. With all the changes in the framework, there are a lot of modifications we are making, but it is actually going very well, with one SIGNIFICANT exception.

We have a REST search service resource that performed very well under 3.8. However, under 4.2 (without any code changes), performance has gone from 1 second to 4 seconds to complete. We have added some metrics (elapsed time via getTickCount() via LogBox messages) and it appears the performance hit is localized to the renderData method (rendering JSON).

By way of a brief explanation, following is the process utilized by the reporting system:

<![if !supportLists]>· <![endif]>System determines the report types that need to be returned and the maximum number of total reports (there are numerous types of reports)

<![if !supportLists]>· <![endif]>Threads are spawned for each type of report. Each thread returns a collection of reports that matched the criteria as a struct-array

<![if !supportLists]>· <![endif]>Threads are joined and the records are aggregated (combined) the sorted into date descending order

<![if !supportLists]>· <![endif]>Results are returned using the renderData() as JSON to the client system

Each thread is completing in sub-second. The sorting process is averaging about 500ms (for 1,000 reports). All told the time in system is about 1500ms. However, the response is taking almost 5000ms, with Coldbox 4.2, to be returned to the client. Under 3.8, this process was taking about 2500ms. If we add more report types, the end-to-end is taking 20,000ms (or longer) versus 7,000ms under 3.8!

System is running on Windows Server 2012, with Adobe CF 11 (Updater 9) using SQL Server 2008 R2.

Any ideas? I can provide additional information, if desired.

Everything that Brad said. We need more metrics into what is causing those issues. FusionReactor would be the best choice.

Anecdotal but I’ve seen the same issue in the past. For certain things I’ve taken the old JSON plugin and converted it to a module to use because of the horrible serializeJSON() performance. (On certain things)

Performance issue has been solved by changing server configuration. Developer had turned off caching in CF Admin in order to diagnose another problem. Once the caching was turned back on, performance degradation disappeared. Performance is now, with 4.2, similar to 3.8.

All is well!