Finding out what package provides an unsatisified link

Here's a quick tip for Linux users... Should you find a missing dependency on the system, be it while running ColdFusion or any other software, you can query the system to find out what package should provide the missing library, and then find and install that package.

As an example, if the legacy X development packages aren't installed then you might find ColdFusion reporting an error about the Graphing Service. Inspecting the ColdFusion logs its revealed that there's a missing link in one of the Java AWT libraries:

Error [main] - Unable to initialize Graphing service: java.lang.UnsatisfiedLinkError: /opt/coldfusionmx7/runtime/jre/lib/i386/


ColdFusion MX and Database Design at Harvard

Proper Database Design remains a weakness of mine when considering my web application development skills, so this semester I've decided to cross that one off my list by enrolling in the Harvard Extension School class:

CSCI E-253 Developing Web-based Database Applications
Web-based applications offer the advantages of workstation productivity and ease of use together with the power and sophistication of relational database servers. This course provides the concepts and skills necessary to design and develop web-based database applications. Students build a working database application using Oracle and a client application using ColdFusion to serve the information needs of an enterprise. Through hands-on projects, students will build, populate, query, and write transactions for a relational database using SQL and then develop a client application to access their database. As a final project, students will build a prototype client/server application.

We've only met one week so far, and tonight will be the second class. I'm thrilled to know that the instructor is not only very articulate when conveying technical ideas, but she professes to be very passionate about both Oracle and ColdFusion.

Database design is a topic not commonly found in ColdFusion FastTrack classes or other CF-related classes from private vendors/instructors. Outside of formal academia, the most comprehensive course on ColdFusion and Database Design that I know of is taught by Adam Churvis and his brother son at Productivity Enhancement. I've often perused the curriculum there, but I find it hard to take time off of work for travel.

Advanced Development with ColdFusion MX and SQL Server 2000
This new version of our ever-popular Advanced Database course is now even better. We took out the Oracle content because only 5% of our students really used it and the other 95% didn't care, plus we removed the data warehousing and load testing content so we could add even more exercises and also spend more time teaching engineering principles, like when you would use one technique for a solution as opposed to another... Now there's plenty of time to explain exactly when and why you would use a correlated subquery versus an outer join, when you should stick with CFQUERY rather than migrate to a stored procedure, etc.

Get Glued at CFUNITED! Class for me today, Breezo for everyone tomorrow!

Get Glued with Model-Glue! (Joe Rinehart)My first day at CFUNITED was largely spent in Joe Rinehart's class Forms and Beans: Refactoring existing ColdFusion using Objects. Joe's focus was on how an OO approach to ColdFusion development can save time by encapsulating application behaviors to reusable ColdFusion components, Further, when iteratively blended into a procedural application by gradually replacing procedural code with OO-based code the procedural application becomes easier to maintain and scalable.

The class had about 15 persons, most of whom were reasonably advanced in ColdFusion development and generally understood OO concepts already. This allowed Joe to speed up a bit, although he was prepared to cover CFC best practices or basic OO PIE concepts in futher detail if needed.

The quick pace permitted the class to move on at the end to make room for a great overview of the Model-Glue framework while also digging deeper into the ServiceFacade and Decorator patterns as they apply to CFCs. Indeed, I was not the sharpest knife in the drawer in this class, and I was certainly humbled by Joe's mastery not only of ColdFusion but OO thought processes. Complex code just streamed effortlessly from his fingertips to the screen while maintaining the cadence and never missing a beat in the presentation flow.

Joe advised developers to perform discrete unit testing of components, which in short means building a test harness that isolates a CFC to validate that it behaves as intended, where testing the CFC outside the larger application reduces complexity during the design or debugging phases. Here, Joe recommended Paul Kenney's CFCUNIT as a very convenient and robust means of unit testing in ColdFusion.

Joe's choice of IDE for ColdFusion is CFEclipse, and I think that Joe and everyone else will be very pleased with some important information from Macromedia coming very soon! I followed along in the class while using Fedora Core 4 Linux on my laptop. FC4 actually ships Java and Eclipse with the distribution, so FC4 is a great way to get started with CFEclipse (although FC4 is technically not supported for ColdFusion, its very close to the supported RH distros and I've encountered no CF problems as a result of running on FC4 so far).

On Wednesday night at 9pm in room 4, there will be a panel discussion of Model-Glue under the guise of a new Model-Glue BOF session. Then at 9:30 I'll help Joe start the online Breezo of Model-Glue that will be broadcast live from CFUNITED. You can RSVP for the Breezo here:

After class I headed out to dinner to celebrate ColdFusion's bright future with the Macromedia CF engineers Dean Harmon, Mike Nimer, Tom Jordahl, director of engineering Damon Cooper, CF QA Bob Powell and Billy Sahlas, plus Ben Forta and Tim Buntel who are presenting the keynote tomorrow, and also Amy Brooks and Christine Lawson of Developer Relations. Macromedia definitely has a huge turnout at this unique ColdFusion conference, and Amy in particular has done a great job at organizing everything. Check out the Macromedia booth in the exhibit hall where we'll all be hanging out to talk to you and help answer your ColdFusion questions. Stop by for posters and T-shirts!

I think CFUNITED is booked with 8-900 attendees, so I plan to get up early for Ben and Tim's keynote address tomorrow morning... just a paltry 7 hours from now :( I'd like to set up my video camera to record the keynote, then I'll try to edit it down to a small file for distribution here soon so everyone can share the good news :)

See you there and see you at the Model-Glue BOF tomorrow!

Fedora Core 4 Linux Ships GCJ Stack - Java, Eclipse, Tomcat

I'm psyched about using the new FC4 distribution. It's easier than ever to get started with Java on a fresh install since some of the new package groups are Java Development which includes 122 Java utilites, Eclipse version 3.1M7 (to which I promptly installed CFEclipse 1.1.17 release), and Tomcat 5.

Lots of other fun stuff is included, too, including Open Office 2.0 (Beta) and a new desktop theme called Clearlooks, replacing the old Bluecurve theme.

I mentioned in an earlier post today that I did a kind of semi-destructive install/quasi-upgrade. That means that when I installed FC3 last fall sometime I installed some of the directories as separate partitions including /home, /opt, and /usr/local. Then I can install FC4 while choosing to reformat the / root partition and install all the new stuff there. This leaves my custom partitions alone so the data is preserved. You have to choose the Manual Disk Druid partition configuration during the installation to get this degree of control though.


ColdFusion DevNet Edition - Not for Production Use

The Devnet Edition of Macromedia ColdFusion MX 7 Server produces a META tag as a "watermark" in the generated output to indicate that it is not for use in production although it has all the Enterprise features and no IP restrictions. This is useful for allowing a team of developers to work off a central CFMX server in a shop that chooses not to buy an Enterprise or Standard edition license for development/QA. The watermark is generated as the first line of generated output and will appear before any HTML markup in between the HEAD tags when outputting HTML, but its a problem for non-HTML content. If the generated content is, say, XML delivered via CFCONTENT then the XML will have the unclosed META tag as a watermark which breaks the well-formedness of the XML document.

"ColdFusionMXEdition" CONTENT="ColdFusion DevNet Edition - Not for Production Use.">

In ColdFusion MX 6.1 this watermark could be avoided by setting the content type with CFCONTENT in pages where the watermark broke the generated content, as blogged here, but in CFMX 7 there is no such workaround.

[More] Article on Optimizing ColdFusion Performance

Today's newsletter highlights an article published this month last year regarding tips and tricks on improving ColdFusion performance. Nothing very earth shattering here, but mostly the standard recommendations repackaged. You'll find many entries on this blog for the same topics.

  • Apply Updates and Hotfixes
  • Setting Simultaneous Requests
  • Load testing is best
  • Increase Cached Templates
  • Trusted Cache
  • Save Class Files
  • Turn off Debugging in production
  • Improving SQL statements
  • Using Prepared Statements via CFQUERYPARAM
  • CachedWithin
  • CF_Accelerate

The article recommends that you consider Sun JVM 1.5.0, however Macromedia has not stated support for this version with either CFMX 6.x or 7. The article doesn't address CFMX 7 at all.

Looks like a good generic review.

activeHandlerThreads or Simultaneous Requests: Less is More

I'm recycling this explanation which I just emailed to someone about why setting the JRun activeHandlerThreads value in jrun.xml to 500 is not a good idea. To ColdFusion users this setting is better known as Simultaneous Requests.

Current values that you've set for the ColdFusion server's JRunProxyService in jrun.xml are far from default

Maximum number of web threads that are actively running.

Maximum number of web threads queued + running

Minimum number of web threads to have around at all times

As a rule of thumb, I recommend that you set these to:


Simultaneous Requests in CFMX 7

Watch that setting! While ColdFusion MX 7 Server Configuration installs with a default value for Simultaneous Request at 8, the Multi-server configuration has a default setting of 25 for this parameter.

ColdFusion MX 7 has the same rule of thumb for starting values on this parameter, just 3 to 5 per CPU on the machine. The default Server Configuration setting falls into that range for a 2 CPU machine, but the Multiserver Configuration value of 25 Simultaneous Requests may be too high for your application.


Discussion on CFEXECUTE on Linux/Unix

Here are some excerpts from a discussion on CFTalk-Linux regarding memory utilization when using the CFEXECUTE tag on Linux/Unix. Many reported to have observed very high memory usage whlie using CFEXECUTE, and it suspected that ColdFusion (via the JVM and the System) calls fork().

This got me thinking, so I carried out some quick, but careful tests on Linux and Solaris while monitoring memory. I did not observe any significant impact on memory utilization, but that is not to say that the reports are wrong. The key is finding out what is different between the server behavior reported in the field and the server behavior observed in these tests.

I was wondering if anyone (Steve) could give me some more information about the performance of
> cfexecute on Linux with MX? I was told that the cfexecute tag is implemented using fork() and
> that each call can consume 100's of MB of memory? Is there any truth to this claim?


Server stability: Of Diligence, Anecdote, and Fallacy

Today I continue my previous post and the CF Server Stability thread on CFTalk in reply to Micha's comments.

I reiterate; I don't believe that casting a broad net for specious reports, incomplete data, and hyperbole will serve to solve whatever particular difficulty ails a given server. I think most every case is rather unique, although where common threads are drawn they get turned around into Technote advisories, documentation, or possibly bug reports. I think each case needs to be founded in contextual information. In other words... Show me the data!


Previous Entries / More Entries