What Request Data Does ColdFusion Builder Post To Extension Handlers?

Posted November 19, 2009 at 2:12 PM

Tags: ColdFusion

Last night, I started playing around with ColdFusion Builder extensions, creating an extension that could encrypt and decrypt CFM and CFC files. The main reason ColdFusion Builder extensions are so attractive as a means to extend the Eclipse platform is that they are powered by actual ColdFusion files (our bread and butter). When you invoke a ColdFusion Builder extension, the IDE gathers data about your request and then posts it as an HTTP form post to your CFML-based handlers. Inside these handlers, you can then do whatever you want, ColdFusion-style, and return an XML result (back to the IDE).

As with any HTTP request, it is important to know what kind of data is available in order to get a handle on what functionality might be leveraged. To explore the ColdFusion Builder extension request context, I decided to CFDump out the CGI and HTTP Request objects to a log file:

CGI


 
 
 

 
ColdFusion Builder Posts CGI Information To Extension Handlers.  
 
 
 

GetHTTPRequestData()


 
 
 

 
ColdFusion Builder Posts HTTP Request Information To Extension Handlers.  
 
 
 

As you can see, not much of anything is posted to the action handlers; not even cookies.

Mostly, this post was just for my understanding and for my own future reference.

Post Comment  |  Ask Ben  |  Other Searches  |  Print Page





Reader Comments

Nov 19, 2009 at 2:19 PM // reply »
222 Comments

The lack of cookies becomes critical when you build multi-step extensions. I've taken to using urlSessionFormat() for all my links.


Nov 19, 2009 at 2:21 PM // reply »
7,212 Comments

@Raymond,

Ahh, good point! It's been so long since I've passed tokens via a URL, I forgot you could even do that. Awesome tip!


Nov 19, 2009 at 3:49 PM // reply »
14 Comments

I _think_ each extension also has an application scope you can use to store persistent data as you navigate from step to step (I could be mistaken; it's been awhile since I've played with extensions and I don't have my notes with me).


Nov 19, 2009 at 3:52 PM // reply »
222 Comments

It does. For solo dev it would be fine to use, but you would need to ensure that step 1 clears the previous data. Not sure I'd feel comfortable using it - but I reserve the right to change my mind later. ;)


Nov 19, 2009 at 5:17 PM // reply »
7,212 Comments

@Brian,

I assume you right (and @Ray confirms). Really, these extensions are just running as ColdFusion applications, so they should have all of the amenities available.


Post Comment  |  Ask Ben

Recent Blog Comments
Feb 9, 2010 at 8:09 AM
Creating A "Remember Me" Login System In ColdFusion
@Nikos, Heck yeah! Glad you got things working smoothly. ... read »
Feb 9, 2010 at 8:05 AM
Creating A "Remember Me" Login System In ColdFusion
No probs :) anyway , Im good now :) ... read »
Feb 9, 2010 at 8:02 AM
Creating A "Remember Me" Login System In ColdFusion
@Nikos, I've seen people use the J2EE sessions, but I have not used them myself... yet. ... read »
Feb 9, 2010 at 7:57 AM
Ask Ben: Converting a Query to an Array
@Stju, Did you actually test this? I ask because there is a fatal flaw in it - you are using the same Row struct for every row. Since Structs are passed by reference, every subsequent update you ma ... read »
Feb 9, 2010 at 7:50 AM
Using jQuery's SlideUp() and SlideDown() Methods With Bottom-Positioned Elements
@Thomas, Not bad. I suppose you could do the same with Top as well as margin. ... read »
Feb 9, 2010 at 7:47 AM
Ask Ben: Creating A PDF And Attaching It To An Email Using ColdFusion
@Johan, I don't think I have one off hand. Basically, you'd just want to use the File attribute of CFDocument to save the PDF to disk. Then, you'd want to use the File attribute of CFMailParam to a ... read »
Feb 9, 2010 at 5:34 AM
Creating A "Remember Me" Login System In ColdFusion
Any change you could show how to take advantage how the J2ee session stuff in your code? http://kb2.adobe.com/cps/182/tn_18232.html ... read »
Feb 9, 2010 at 5:32 AM
Creating A "Remember Me" Login System In ColdFusion
This may help: http://bugs.farcrycms.org/browse/FC-79 Its the session variables' option being selected in the CF Admin ... read »