Status/Resolution/Reason: Closed/Withdrawn/Duplicate
Reporter/Name(from Bugbase): / Sathish Kumar (External User)
Created: 03/09/2016
Components: Language, CF Component
Versions: 2016
Failure Type: Unspecified
Found In Build/Fixed In Build: RC1_v12 /
Priority/Frequency: Trivial / Unknown
Locale/System: English / Win All
Vote Count: 0
Duplicate ID: CF-4126378
Hi,
I would like to submit a request for ColdFusion12 to have additional attributes for CFCOMPONENT and also for CFFUNCTION tags when it is used inside CFCOMPONENT to declare methods of the components. Basically, it would be good to have 2 additional methods namely OnBeforeExecution, OnAfterExecution that could be given a valid coldfusion expression including a closure expression, function call, cfinclude etc. Basically, given the new age architecture of MVC where most apps are build around either webservices or controllers, the facility to specify a piece of code to run before and after every method in a component or specific methods in a component will come hand to format output, verify some connections to external resources, do method level execution time logging/ tracking, etc. This method will probably simplify develop CF apps even without a MVC framework etc or even make life easeier for frameworks to provide plugin architecture with ease and without having to write their own parsing/discovery mechanisms to invoke plugin code etc before or after various service calls and so forth. I can possibly have a CFC that returns data for a view and based on the client device which my OnBeforeExecution will establish, I can wrap the whole output of each method in my CFC with a header and footer which my OnAfterExecution expression will be able to handle. All local variables , arguments passed to the methods will be available in both these OnBeforeExecution, OnAfterExecution code expressions. I think this will be a game changer for ColdFusion much similar to CFSAVECONTENT which does not have an equivalent yet in ASP.net, PHP etc easily.
----------------------------- Additional Watson Details -----------------------------
Watson Bug ID: 4126373
External Customer Info:
External Company:
External Customer Name: Sathish Kumar
External Customer Email: sathish@carboncubes.biz
External Test Config: Friendly Name: CC-LAPTOP004
System Type: Laptop
Brand: Dell
Model: XPS15
Processor Type: Intel Core i5
Processor Speed: 2GHz to 3GHz
Memory: 2GB to 4GB
Hard Drive Storage: 500GB-1TB
Peripherals:
Connectivity: Wireless 802.11 N
Interfaces: Parallel
Interfaces: USB 1.x
Interfaces: USB 2.x
Media: DVD+R
Primary Operating System: Windows 7 64
Secondary Operating System:
System Location: Office
Time Owned: 1 to 2 Years
Attachments:
Comments: