by Kay Smoljak
Noteworthy threads from the famous ColdFusion-Talk (CF-Talk) List on House of Fusion for the Week of May 11 - 18, 2008
Thread: Latency after ColdFusion 8 upgrade
Sud Luthra was looking for advice to resolve a speed and latency issue on an enterprise application after upgrading to ColdFusion 8. Sud's team had already downgraded the JVM to 1.5 and had seen some improvements, but were still not happy with the performance. Chris Peterson suggested verifying that server monitoring, memory profiling and debugging were all turned off, a suggestion that was backed up by Jochem van Dieten and Tom Chiverton, although Tom did further clarify that server monitoring and memory profiling should not have as big an impact as debugging. Jon Clausen added that if a third party database driver were being used, switching to ColdFusion 8's native drivers might make a performance difference.
Thread: Help! Can't I set a specific time zone for a ColdFusion App?
Bob Wright wanted a way to set the time zone for an entire application, as it was hosted on a server in a different timezone to the one he wished the application to use. Because they were used throughout the application, changing each date function instance would be a large job, and changing the server time zone was not an option. Mike Chabot confirmed that the timezone had to be set on the server, and that while it was possible to supply a time zone argument to the JVM in the ColdFusion administrator, this would not take effect everywhere (for example, not in the database). William Seiter suggested writing a user defined function which duplicated the functionality of Now(), but with a timezone offset. Bobby Hartsfield suggested a similar solution, and Dave Watts linked to a pre-written user defined function on cflib.org.
Thread: CFLOCK issues in ColdFusion 8
Wim Lemmens was having an issue with an application that made extensive use of CFLOCK, including nested locks. Wim's test server had recently been upgraded from ColdFusion MX 6.1 to ColdFusion 8 and requests were now being blocked which previously were not. Dave Watts commented that in most cases he had seen, the use of CFLOCK was unnecessary, and suggested Wim replace the nested locks with named locks.
Wim followed up to confirm that the problem had been found, and that it was actually caused by ColdFusion 8's monitoring service, specifically the memory tracking. He added that the CF 8.0.1 updater had been applied – leading Hemant Khandelwal from Adobe to request follow up information, offlist.
Thread: defining variables in a new loop from an old loop
New ColdFusion coder Travis Mitchell wanted to use a variable from his initial loop in a second loop. William Seiter offered a solution using the Evalute() function, and James Holmes showed that it was possible to solve Travis' problem two different ways, without using Evaluate(), which does not perform very well.
Threads:
JRun 600MB+ shortly after boot up
**UPDATE** JRn 600MB+ shortly after boot up
**UPDATE** JRun 600MB+ shortly after boot up
Two separate threads this week discussed JRun memory usage. First, Jason Durham reported that his development install of ColdFusion 8.0.1 on Windows XP was consuming 600+ MB of memory shortly after startup, and all requests were timing out. Mark Kruger, James Holmes and Brad Wood all made troubleshooting suggestions – including downgrading the JVM, changing JVM settings and checking that it was not a code issue – none of which solved the problem. Even after rebuilding the machine, the JRun memory usage remained high, although Jason's application did start responding.
In a separate thread, Richard White posted about a problem he was having with a development laptop running slowly. After reading Jason's thread, he started to wonder about JRun memory usage and was surprised to find it was in the hundreds of megabytes.
In both threads, several listers discussed how JRun memory allocation works, explaining why allocated memory is not returned to the operating system when no longer needed. Their conclusions were that the only real solution is to use a machine with plenty of memory for development purposes, and possibly to limit the memory that JRun is able to address. However, limiting the memory available to JRun may cause ColdFusion to run slower.
Thread: Problems with 64 bit ColdFusion 8 on 64 bit Vista IIS7
Nathan Strutz was having ColdFusion 8 64-bit installation issues on 64-bit Windows Vista using IIS7 – the connectors were not automatically run, and the web server configuration tool was unable to recognise IIS7. Asha Kasala from Adobe suggested a few IIS setting changes to try, and Nathan reported back that one of these settings – the IIS6 compatibility setting – was the key to solving the problem. Andrew Scott and Jason Durham also both added information on how they overcame difficulties with 64-bit installations on Windows.
Kay is an all-round web developer who has been developing with ColdFusion since 2000. She runs Clever Starfish with her partner Dave and several very demanding cats, and sits on the committee of the Australian Web Industry Association. She is a regular writer for Fusion Authority and the Fusion Authority Quarterly Update, and a ColdFusion blogger on Sitepoint.com.