SlideShare ist ein Scribd-Unternehmen logo
1 von 15
Downloaden Sie, um offline zu lesen
Leveraging ColdFusion to build Java-EE applications
      Mike Nimer| Solution Architect at Universal Mind
      Elishia Dvorak | Solution Consultant at Adobe




© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
What is ColdFusion

       High level Java Application
       Both a language (CFML) and a web application platform (server)
       Provides seamless integration with existing Java applications.


       Available since 1995
             Reliable and mature, extensive feature set
             165+ JSP tags
             Hundreds of functions
             CF was ported from C++ to Java between CF5 and CF6

       Provides necessary services
             .Net integration, PDF generation, Image manipulation, etc…

© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Using ColdFusion (in Java)

        Use CFCProxy to treat CF like a large library and invoke
         ColdFusion tags and functions inside your java
         classes/servlets. (New in CF10)

        Use ColdFusion as the "View" layer in an existing Java
         Framework, such as Spring MVC.




© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
ColdFusion Parts

       .CFM Page “is like a” JSP Page
       .CFC File “is like a” Java Class / POJO
       Compiler
       CFMServlet
              Filters
       Extra Servlets
              REST support
              Flex Integration
              RDS (IDE integration)
              etc.
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Why ColdFusion (for Java developers)

        PDF Integration                                                         Event Gateways
              CFDOCUMENT
                                                                                     SMS / IM Gateway
                                                                                 Email
              CFPDF
                                                                                     CFMAIL (2million / hr)
        Virtual File System                                                         CFExchange
              In Memory, S3, ZIP, etc.                                              CFPOP/CFIMAP
        Query of Query                                                          CFPresentation
                                                                                 .NET integration
        Encryption
                                                                                 CFDUMP
              RSA B-Safe Crypto-J library                                       and more..
        OEM features




© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
CFCProxy

  String cfcPath =
     req.getRealPath("/demos-inf/components/" +
  "cfExample.cfc");


  CFCProxy myCFC = new CFCProxy(cfcPath, false);


  Object[] myArgs = {img};


  Object cfcResult =
             myCFC.invoke("convertImage", myArgs);




© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
CFCPROXY Demos

        Query-of-Query

        Html to PDF

        PDF Forms

        Dynamic Presentation Creation

        Excel Integration

        Image Manipulation




© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
ColdFusion Classloader & CFCProxy

       CFCProxy & the CF ClassLoader


  <servlet>
         <servlet-name>myServlet</servlet-name>
      <servlet-
  class>coldfusion.bootstrap.BootstrapServlet</servlet-class>
         <init-param>
             <param-name>servlet.class</param-name>
             <param-value>com.mikenimer.MyServlet</param-value>
         </init-param>
         <load-on-startup>1</load-on-startup>
  </servlet>

© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
SpringMVC

        MVC Java Framework

        Clear separation of roles - Controllers, models, view helpers,
         filters, Interceptors, validation, etc.

        View Helpers support multiple output formats from the same
         url


        return Web page to browser

        return JSON to IPhone version of site

© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
SpringMVC

        Why ColdFusion instead of JSP?
              CFTAGS feel right around HTML

              Raw power available in CF

              JSP Tags work in CF Pages too




© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
SpringMVC "palladium" ViewHelper

       Palladium will put the “model” properties into the ColdFusion
        request scope.

       Palladium allows you to pass Spring beans into ColdFusion.
        #request.palladium.beans.<name>#


       Palladium can auto convert java objects into CF Friendly types
        (default is off)

       Collections into CF Array (Vector)

       Convert NULL into default “”
© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Demo




© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
SpringMVC "palladium" Config

  <bean class="org.springframework.
  web.servlet.view.InternalResourceViewResolver">
  <property
           name="viewClass”
  value="com.mikenimer.palladium.spring.mvc.views.ColdFusionView"
  />


  <property
           name="prefix"
                     value="/kitchensink-inf/views/propertytest-views/" />
  <property
                     name="suffix" value=".cfm" />
  </bean>

© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Useful Links

       ColdFusion
              http://www.adobe.com/products/coldfusion-family.html

       Palladium project
              https://github.com/mnimer/palladium


       Blog: "ColdFusion (libraries) for Java Developers"
              http://www.mikenimer.com/?p=857

       Twitter
              @mnimer
              @elishdvorak

© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
Questions?


© 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.

Weitere ähnliche Inhalte

Andere mochten auch

The economies of scaling software - Abdel Remani
The economies of scaling software - Abdel RemaniThe economies of scaling software - Abdel Remani
The economies of scaling software - Abdel Remani
jaxconf
 

Andere mochten auch (9)

Future of the Web - Yehuda Katz
Future of the Web - Yehuda KatzFuture of the Web - Yehuda Katz
Future of the Web - Yehuda Katz
 
The Spring 4 Update - Josh Long
The Spring 4 Update - Josh LongThe Spring 4 Update - Josh Long
The Spring 4 Update - Josh Long
 
Multi Client Development with Spring - Josh Long
Multi Client Development with Spring - Josh Long Multi Client Development with Spring - Josh Long
Multi Client Development with Spring - Josh Long
 
What you need to know about Lambdas - Jamie Allen
What you need to know about Lambdas - Jamie AllenWhat you need to know about Lambdas - Jamie Allen
What you need to know about Lambdas - Jamie Allen
 
Getting started with Websocket and Server-sent Events using Java - Arun Gupta
Getting started with Websocket and Server-sent Events using Java - Arun Gupta Getting started with Websocket and Server-sent Events using Java - Arun Gupta
Getting started with Websocket and Server-sent Events using Java - Arun Gupta
 
The economies of scaling software - Abdel Remani
The economies of scaling software - Abdel RemaniThe economies of scaling software - Abdel Remani
The economies of scaling software - Abdel Remani
 
Building an Impenetrable ZooKeeper - Kathleen Ting
Building an Impenetrable ZooKeeper - Kathleen TingBuilding an Impenetrable ZooKeeper - Kathleen Ting
Building an Impenetrable ZooKeeper - Kathleen Ting
 
Java PaaS Comparisons - Khanderao Kand
Java PaaS Comparisons - Khanderao KandJava PaaS Comparisons - Khanderao Kand
Java PaaS Comparisons - Khanderao Kand
 
Apache Hadoop and its role in Big Data architecture - Himanshu Bari
Apache Hadoop and its role in Big Data architecture - Himanshu BariApache Hadoop and its role in Big Data architecture - Himanshu Bari
Apache Hadoop and its role in Big Data architecture - Himanshu Bari
 

Kürzlich hochgeladen

Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Kürzlich hochgeladen (20)

Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
AI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by AnitarajAI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by Anitaraj
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 

Leveraging ColdFusion to Build Java-EE Applications: Elishia Dvorak

  • 1. Leveraging ColdFusion to build Java-EE applications Mike Nimer| Solution Architect at Universal Mind Elishia Dvorak | Solution Consultant at Adobe © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 2. What is ColdFusion  High level Java Application  Both a language (CFML) and a web application platform (server)  Provides seamless integration with existing Java applications.  Available since 1995  Reliable and mature, extensive feature set  165+ JSP tags  Hundreds of functions  CF was ported from C++ to Java between CF5 and CF6  Provides necessary services  .Net integration, PDF generation, Image manipulation, etc… © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 3. Using ColdFusion (in Java)  Use CFCProxy to treat CF like a large library and invoke ColdFusion tags and functions inside your java classes/servlets. (New in CF10)  Use ColdFusion as the "View" layer in an existing Java Framework, such as Spring MVC. © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 4. ColdFusion Parts  .CFM Page “is like a” JSP Page  .CFC File “is like a” Java Class / POJO  Compiler  CFMServlet  Filters  Extra Servlets  REST support  Flex Integration  RDS (IDE integration)  etc. © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 5. Why ColdFusion (for Java developers)  PDF Integration  Event Gateways  CFDOCUMENT  SMS / IM Gateway  Email  CFPDF  CFMAIL (2million / hr)  Virtual File System  CFExchange  In Memory, S3, ZIP, etc.  CFPOP/CFIMAP  Query of Query  CFPresentation  .NET integration  Encryption  CFDUMP  RSA B-Safe Crypto-J library  and more..  OEM features © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 6. CFCProxy String cfcPath = req.getRealPath("/demos-inf/components/" + "cfExample.cfc"); CFCProxy myCFC = new CFCProxy(cfcPath, false); Object[] myArgs = {img}; Object cfcResult = myCFC.invoke("convertImage", myArgs); © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 7. CFCPROXY Demos  Query-of-Query  Html to PDF  PDF Forms  Dynamic Presentation Creation  Excel Integration  Image Manipulation © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 8. ColdFusion Classloader & CFCProxy  CFCProxy & the CF ClassLoader <servlet>    <servlet-name>myServlet</servlet-name>    <servlet- class>coldfusion.bootstrap.BootstrapServlet</servlet-class>    <init-param>        <param-name>servlet.class</param-name>        <param-value>com.mikenimer.MyServlet</param-value>    </init-param>    <load-on-startup>1</load-on-startup> </servlet> © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 9. SpringMVC  MVC Java Framework  Clear separation of roles - Controllers, models, view helpers, filters, Interceptors, validation, etc.  View Helpers support multiple output formats from the same url  return Web page to browser  return JSON to IPhone version of site © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 10. SpringMVC  Why ColdFusion instead of JSP?  CFTAGS feel right around HTML  Raw power available in CF  JSP Tags work in CF Pages too © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 11. SpringMVC "palladium" ViewHelper  Palladium will put the “model” properties into the ColdFusion request scope.  Palladium allows you to pass Spring beans into ColdFusion. #request.palladium.beans.<name>#  Palladium can auto convert java objects into CF Friendly types (default is off)  Collections into CF Array (Vector)  Convert NULL into default “” © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 12. Demo © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 13. SpringMVC "palladium" Config <bean class="org.springframework. web.servlet.view.InternalResourceViewResolver"> <property name="viewClass” value="com.mikenimer.palladium.spring.mvc.views.ColdFusionView" /> <property name="prefix"     value="/kitchensink-inf/views/propertytest-views/" /> <property     name="suffix" value=".cfm" /> </bean> © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 14. Useful Links  ColdFusion  http://www.adobe.com/products/coldfusion-family.html  Palladium project  https://github.com/mnimer/palladium  Blog: "ColdFusion (libraries) for Java Developers"  http://www.mikenimer.com/?p=857  Twitter  @mnimer  @elishdvorak © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.
  • 15. Questions? © 2012 Adobe Systems Incorporated. All Rights Reserved. Adobe Confidential.