SlideShare uma empresa Scribd logo
1 de 26
Accessing ColdFusion
Services From Flex
Applications

Matt Gifford aka @coldfumonkeh



Adobe ColdFusion Developer Week 2011
Who?
Lead RIA Developer
Adobe Community Professional
User Group Manager - Hertfordshire, UK
Author
Coffee Lover


@coldfumonkeh
www.mattgifford.co.uk

www.fuzzyorange.co.uk
Integrating ColdFusion services into non-
        ColdFusion systems and applications



What?   Utilise powerful features whilst minimising
        coding and maximising functionality

        Improving workflow and developer
        collaboration across language divides
Because ColdFusion is incredibly powerful


Why?   Rapid Application Development

       It’s awesome fun
COLDFUSION CODE NINJAS // ALL OF YOU
Object-relational mapping (ORM)

             Enhanced Document Manipulation

             Enhanced AJAX controls


CF9          Sharepoint integration (portals)


gave us...   ColdFusion Builder

             Exposed Service Layer (CFaaS)

             and much more...
Remote Services
LET’S DEMONSTRATE // DATA CENTRIC DEVELOPMENT
Exposed Service Layer
WHAT IS AVAILABLE? // EXPOSED FUNCTIONALITY
ColdFusion
as a Service
(or how to share the awesome-ness with
other developers and other languages)
http://[server]:[port]/CFIDE/services/

   http://localhost:8500/CFIDE/services/mail.cfc?wsdl

   http://localhost:8500/CFIDE/services/document.cfc?wsdl

   http://localhost:8500/CFIDE/services/chart.cfc?wsdl




ACCESSING SERVICES // WEB SERVICE
Chart             Mail
           generate          send

           Document          PDF
           generate          addWatermark
                             convertArrayOfStructToPDFPageDetailArray [private]
                             deletepages
           Image             extractImage
           AddBorder
                             extractPages
           batchOperation
                             extractText
           Blur
                             getInfo
           Crop
                             mergeFiles
           Flip
                             mergespecificpages
           GetEXIFMetaData
                             processDDX
           GetEXIFTAG
                             protect
           GetHeight
                             removewatermark
           GetIPTCMetaData
                             setinfo
           GetIPTCTag
                             thumbnail
           GetWidth
           GrayScale
           Info              POP
           Negative          delete
           Overlay           getAll
           Resize            getHeaderOnly
           Rotate
           ScaletoFit
           Sharpen
           Shear




AVAILABLE SERVICES // WHAT YOU CAN DO WITH IT
Restricted
Access
to exposed services through the
ColdFusion Administrator
ActionScript Proxy Classes
ColdFusion:


        <cfmail to="requests@guitar-hero.com"
        	 from="me@my_email_address.com"
        	 subject="More Kenny Loggins" />


AS Proxy in Flex:


        <cf:Mail to="requests@guitar-hero.com"
        	 from="me@my_email_address.com"
        	 subject="More Kenny Loggins" />
Import the cfservices.swc file (from ColdFusion 9 install):

                             typically in /CFIDE/scripts/AIR/ directory


   Add ColdFusion namespace to your Flex application

                             xmlns:cf=”coldfusion.service.mxml.*”


   Write some code

                             That bit’s over to you...




HOW EASY IS IT? // VERY
LET’S DEMONSTRATE // BUILDING AN APPLICATION
USEFUL REMINDERS

  ColdFusion Connection:

                      <cf:Config id="conf"
                      	   	    cfServer="localhost"
                      	   	    cfPort="8500"
                      	   	    serviceUserName="demoUser"
                      	   	    servicePassword="demoPassword" />



        Define a Method:
                      <cf:Image id="getImageInfo"
                      	   	    action="info"
                      	   	    source="{dragImage.source}"
                      	   	    result="imageInfoResult(event)"
                      	   	    fault="onFault(event)" />	



  Execute (in a nice way):
                             getImageInfo.execute();
STRESS-FREE UPLOADS // UTIL CLASS MAGIC
USEFUL REMINDERS

  Upload URL:
   uploadUrl.url = "http://"+conf.cfServer+":"+conf.cfPort+"/"+Util.UPLOAD_URL;
   uploadUrl.method = "POST";
   uploadUrl.contentType = "multipart/form-data";




  Util Class Generates:

   http://localhost:8500/CFIDE/services/upload.cfc?METHOD=uploadForm




  Get Remote Location:

   uploadedFileUrl = Util.extractURLFromUploadResponse(event.data.toString());
WHY SHOULD YOU CARE? // BECAUSE YOU’RE AWESOME
Full code on github:


           https://github.com/coldfumonkeh/ColdFusion-Dev-Week-Demos




 CFaaS method cheat sheet:



           http://www.mattgifford.co.uk/updated-cfaas-method-cheat-sheet




TRY IT YOURSELF // THINGS TO HELP YOU
Accessing ColdFusion Services From Flex Applications
Matt Gifford aka @coldfumonkeh        Adobe ColdFusion Developer Week 2011

Mais conteúdo relacionado

Semelhante a Accessing ColdFusion Services From Flex Applications

ColdFusion as a Service
ColdFusion as a ServiceColdFusion as a Service
ColdFusion as a Service
Matt Gifford
 
Spring Cairngorm
Spring CairngormSpring Cairngorm
Spring Cairngorm
devaraj ns
 
A Microsoft Silverlight User Group Starter Kit Made Available for Everyone to...
A Microsoft Silverlight User Group Starter Kit Made Available for Everyone to...A Microsoft Silverlight User Group Starter Kit Made Available for Everyone to...
A Microsoft Silverlight User Group Starter Kit Made Available for Everyone to...
DataLeader.io
 
WebLogic Administration und Deployment mit WLST
WebLogic Administration und Deployment mit WLSTWebLogic Administration und Deployment mit WLST
WebLogic Administration und Deployment mit WLST
enpit GmbH & Co. KG
 

Semelhante a Accessing ColdFusion Services From Flex Applications (20)

ColdFusion as a Service
ColdFusion as a ServiceColdFusion as a Service
ColdFusion as a Service
 
Spring Cairngorm
Spring CairngormSpring Cairngorm
Spring Cairngorm
 
Camel on Cloud by Christina Lin
Camel on Cloud by Christina LinCamel on Cloud by Christina Lin
Camel on Cloud by Christina Lin
 
Consul: Service Mesh for Microservices
Consul: Service Mesh for MicroservicesConsul: Service Mesh for Microservices
Consul: Service Mesh for Microservices
 
Simplify Cloud Applications using Spring Cloud
Simplify Cloud Applications using Spring CloudSimplify Cloud Applications using Spring Cloud
Simplify Cloud Applications using Spring Cloud
 
A Microsoft Silverlight User Group Starter Kit Made Available for Everyone to...
A Microsoft Silverlight User Group Starter Kit Made Available for Everyone to...A Microsoft Silverlight User Group Starter Kit Made Available for Everyone to...
A Microsoft Silverlight User Group Starter Kit Made Available for Everyone to...
 
BlazeDS
BlazeDSBlazeDS
BlazeDS
 
Implementing New Web
Implementing New WebImplementing New Web
Implementing New Web
 
Implementing new WebAPIs
Implementing new WebAPIsImplementing new WebAPIs
Implementing new WebAPIs
 
Ato2019 weave-services-istio
Ato2019 weave-services-istioAto2019 weave-services-istio
Ato2019 weave-services-istio
 
All Things Open 2019 weave-services-istio
All Things Open 2019 weave-services-istioAll Things Open 2019 weave-services-istio
All Things Open 2019 weave-services-istio
 
Weave Your Microservices with Istio
Weave Your Microservices with IstioWeave Your Microservices with Istio
Weave Your Microservices with Istio
 
From Zero to Cloud in 12 Easy Factors
From Zero to Cloud in 12 Easy FactorsFrom Zero to Cloud in 12 Easy Factors
From Zero to Cloud in 12 Easy Factors
 
Deploying Spring Boot applications with Docker (east bay cloud meetup dec 2014)
Deploying Spring Boot applications with Docker (east bay cloud meetup dec 2014)Deploying Spring Boot applications with Docker (east bay cloud meetup dec 2014)
Deploying Spring Boot applications with Docker (east bay cloud meetup dec 2014)
 
Automated integration testing of distributed systems with Docker Compose and ...
Automated integration testing of distributed systems with Docker Compose and ...Automated integration testing of distributed systems with Docker Compose and ...
Automated integration testing of distributed systems with Docker Compose and ...
 
Porting legacy apps to Griffon
Porting legacy apps to GriffonPorting legacy apps to Griffon
Porting legacy apps to Griffon
 
Zaragoza dev ops-activiti-khd-20181212
Zaragoza dev ops-activiti-khd-20181212Zaragoza dev ops-activiti-khd-20181212
Zaragoza dev ops-activiti-khd-20181212
 
WebLogic Administration und Deployment mit WLST
WebLogic Administration und Deployment mit WLSTWebLogic Administration und Deployment mit WLST
WebLogic Administration und Deployment mit WLST
 
Docker and Cloud - Enables for DevOps - by ACA-IT
Docker and Cloud - Enables for DevOps - by ACA-ITDocker and Cloud - Enables for DevOps - by ACA-IT
Docker and Cloud - Enables for DevOps - by ACA-IT
 
'DOCKER' & CLOUD: ENABLERS For DEVOPS
'DOCKER' & CLOUD:  ENABLERS For DEVOPS'DOCKER' & CLOUD:  ENABLERS For DEVOPS
'DOCKER' & CLOUD: ENABLERS For DEVOPS
 

Mais de Matt Gifford

Mais de Matt Gifford (6)

Get Grulping with JavaScript Task Runners
Get Grulping with JavaScript Task RunnersGet Grulping with JavaScript Task Runners
Get Grulping with JavaScript Task Runners
 
Swing when you're winning - an introduction to Ruby and Sinatra
Swing when you're winning - an introduction to Ruby and SinatraSwing when you're winning - an introduction to Ruby and Sinatra
Swing when you're winning - an introduction to Ruby and Sinatra
 
Automating PhoneGap Build
Automating PhoneGap BuildAutomating PhoneGap Build
Automating PhoneGap Build
 
Let jQuery Rock Your World
Let jQuery Rock Your WorldLet jQuery Rock Your World
Let jQuery Rock Your World
 
OAuth: demystified (hopefully)
OAuth: demystified (hopefully)OAuth: demystified (hopefully)
OAuth: demystified (hopefully)
 
Darwin Development
Darwin DevelopmentDarwin Development
Darwin Development
 

Último

CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
giselly40
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Último (20)

[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 

Accessing ColdFusion Services From Flex Applications

  • 1. Accessing ColdFusion Services From Flex Applications Matt Gifford aka @coldfumonkeh Adobe ColdFusion Developer Week 2011
  • 2. Who? Lead RIA Developer Adobe Community Professional User Group Manager - Hertfordshire, UK Author Coffee Lover @coldfumonkeh www.mattgifford.co.uk www.fuzzyorange.co.uk
  • 3. Integrating ColdFusion services into non- ColdFusion systems and applications What? Utilise powerful features whilst minimising coding and maximising functionality Improving workflow and developer collaboration across language divides
  • 4. Because ColdFusion is incredibly powerful Why? Rapid Application Development It’s awesome fun
  • 5. COLDFUSION CODE NINJAS // ALL OF YOU
  • 6. Object-relational mapping (ORM) Enhanced Document Manipulation Enhanced AJAX controls CF9 Sharepoint integration (portals) gave us... ColdFusion Builder Exposed Service Layer (CFaaS) and much more...
  • 8.
  • 9.
  • 10. LET’S DEMONSTRATE // DATA CENTRIC DEVELOPMENT
  • 12. WHAT IS AVAILABLE? // EXPOSED FUNCTIONALITY
  • 13. ColdFusion as a Service (or how to share the awesome-ness with other developers and other languages)
  • 14. http://[server]:[port]/CFIDE/services/ http://localhost:8500/CFIDE/services/mail.cfc?wsdl http://localhost:8500/CFIDE/services/document.cfc?wsdl http://localhost:8500/CFIDE/services/chart.cfc?wsdl ACCESSING SERVICES // WEB SERVICE
  • 15. Chart Mail generate send Document PDF generate addWatermark convertArrayOfStructToPDFPageDetailArray [private] deletepages Image extractImage AddBorder extractPages batchOperation extractText Blur getInfo Crop mergeFiles Flip mergespecificpages GetEXIFMetaData processDDX GetEXIFTAG protect GetHeight removewatermark GetIPTCMetaData setinfo GetIPTCTag thumbnail GetWidth GrayScale Info POP Negative delete Overlay getAll Resize getHeaderOnly Rotate ScaletoFit Sharpen Shear AVAILABLE SERVICES // WHAT YOU CAN DO WITH IT
  • 16. Restricted Access to exposed services through the ColdFusion Administrator
  • 18. ColdFusion: <cfmail to="requests@guitar-hero.com" from="me@my_email_address.com" subject="More Kenny Loggins" /> AS Proxy in Flex: <cf:Mail to="requests@guitar-hero.com" from="me@my_email_address.com" subject="More Kenny Loggins" />
  • 19. Import the cfservices.swc file (from ColdFusion 9 install): typically in /CFIDE/scripts/AIR/ directory Add ColdFusion namespace to your Flex application xmlns:cf=”coldfusion.service.mxml.*” Write some code That bit’s over to you... HOW EASY IS IT? // VERY
  • 20. LET’S DEMONSTRATE // BUILDING AN APPLICATION
  • 21. USEFUL REMINDERS ColdFusion Connection: <cf:Config id="conf" cfServer="localhost" cfPort="8500" serviceUserName="demoUser" servicePassword="demoPassword" /> Define a Method: <cf:Image id="getImageInfo" action="info" source="{dragImage.source}" result="imageInfoResult(event)" fault="onFault(event)" /> Execute (in a nice way): getImageInfo.execute();
  • 22. STRESS-FREE UPLOADS // UTIL CLASS MAGIC
  • 23. USEFUL REMINDERS Upload URL: uploadUrl.url = "http://"+conf.cfServer+":"+conf.cfPort+"/"+Util.UPLOAD_URL; uploadUrl.method = "POST"; uploadUrl.contentType = "multipart/form-data"; Util Class Generates: http://localhost:8500/CFIDE/services/upload.cfc?METHOD=uploadForm Get Remote Location: uploadedFileUrl = Util.extractURLFromUploadResponse(event.data.toString());
  • 24. WHY SHOULD YOU CARE? // BECAUSE YOU’RE AWESOME
  • 25. Full code on github: https://github.com/coldfumonkeh/ColdFusion-Dev-Week-Demos CFaaS method cheat sheet: http://www.mattgifford.co.uk/updated-cfaas-method-cheat-sheet TRY IT YOURSELF // THINGS TO HELP YOU
  • 26. Accessing ColdFusion Services From Flex Applications Matt Gifford aka @coldfumonkeh Adobe ColdFusion Developer Week 2011