Wednesday, March 10, 2010    
Home My Books Blog ColdFusion About Me Back    

Calendar
<< Dec 2008 >>
S M T W T F S
  1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31      

Search

Categories
 • Acrobat (3) [RSS]
 • Adobe (88) [RSS]
 • AdobeMAX06 (45) [RSS]
 • AdobeMAX07 (59) [RSS]
 • AdobeMAX08 (66) [RSS]
 • AdobeMAX09 (39) [RSS]
 • AdobeMAX10 (1) [RSS]
 • AIR (219) [RSS]
 • Appearances (191) [RSS]
 • Books (72) [RSS]
 • CFEclipse (15) [RSS]
 • ColdFusion (1378) [RSS]
 • Data Services (34) [RSS]
 • Fish Tank (4) [RSS]
 • Flash (196) [RSS]
 • Flex (496) [RSS]
 • Home Automation (4) [RSS]
 • Jobs (116) [RSS]
 • JRun (14) [RSS]
 • Labs (43) [RSS]
 • LiveCycle (34) [RSS]
 • MAX (232) [RSS]
 • Mobile (119) [RSS]
 • Regular Expressions (17) [RSS]
 • RIA (21) [RSS]
 • SQL (40) [RSS]
 • Stuff (535) [RSS]
 • Tips (CF Studio) (80) [RSS]
 • Tips (CF) (795) [RSS]
 • Tips (Dreamweaver) (91) [RSS]
 • Tips (Flex Builder) (2) [RSS]
 • Using CF (162) [RSS]

Other BLOGs
 • Charlie Arehart
 • Lee Brimelow
 • Ray Camden
 • Christophe Coenraets
 • Sean Corfield
 • Mihai Corlan
 • Cornel Creanga
 • Mark Doherty
 • John Dowdell
 • Danny Dura
 • Enrique Duvos
 • Steven Erat
 • Kevin Hoyt
 • Serge Jespers
 • Adam Lehman
 • Duane Nickull
 • Miti Pricope
 • Andrew Shorten
 • Ryan Stewart
 • James Ward
 • Greg Wilson
 • Full As A Goog

RSS Feeds
 • Feed
 • Subscribe

Join my mailing list and find out about new books and other topics of interest.

Thoughts, ideas, tips, musings, and pontifications (not necessarily in that order) by Ben Forta ...
NOTE: This is my personal blog, and the opinions and statements voiced here are my own.

Viewing By Day : December 14, 2008 / Main
December 14, 2008

ColdFusion Per Application Settings v2

ColdFusion users have long wanted a way to define settings per application, rather than server-wide, even within a shared instance. ColdFusion 8 introduced the beginnings of per application settings via Application.cfc (which we introduced in CF7).

To set application settings using Application.cfc, variables are set in the THIS scope. THIS.name to set the application name, THIS.sessionManagement to enable session state management, and so on. In CF8, Application.cfc and the THIS scope can be used to define per application settings. For example, THIS.mappings is a structure which can be used to define ColdFusion mappings. To set a mapping you just modify that structure like this:

<cfset THIS.mappings["/MyStuff"]="c:\inetpub\MyStuff">

To set the Custom Tag path you can update THIS.customtagpaths which is a simple ColdFusion list. You can set the path like this:

<cfset THIS.customtagpaths="c:\inetpub\wwwroot\ben\tags">

Or use ListAppend() to add a path, like this:

<cfset THIS.customtagpaths=ListAppend(THIS.customtagpaths, "c:\inetpub\wwwroot\ben\tags")>

It's clean, simple, highly intuitive, and in CF8, limited to just those two settings - mappings and customtagpaths.

In CF9 (aka Centaur) we may have the opportunity to enhance this functionality. And actually, we've already started doing so. For example, at MAX in Europe I mentioned that CF9 allows for THIS.datasource to be defined as a default datasource, eliminating the need to specify the datasource for each and every query. And that's just an example.

There are others I'd like to see, starting with THIS.logdirectory to set a log file location per application. But, rather than my list of settings, I am interested in yours.

Now, this should go without saying, but I'll say it anyway. When discussing a future product there is no firm commitment being made about any features. Stuff can, and usually does, change. But, having said that ...

What are the settings you'd like to see us support per application in CF9? Feel free to list multiple, but be sure to define them in the order of priority.

(Oh, and before the thread goes off on a tangent, yes, I know we need a way to define on-the-fly datasources as you could in CF5. But no, these are not technically application settings, and are out of scope for this thread).

Related Blog Entries

TrackBacks
There are no trackbacks for this entry.

No trackback URL. Trackbacks are only allowed via interactive form.

Comments

  © Copyright 1997-2009 Ben Forta, All Rights Reserved