SlideShare uma empresa Scribd logo
1 de 35
Unleash the full power ofRESTful communication with FLEXChristian JunkESRI Developer Summit 2010, Palm Springs
RESTful communication with FLEXChristian JunkESRI Developer Summit 2010, Palm Springs
Who am I? Senior Software Developer @ http://www.alta4.com, Germany Developingbackendsfor web-basedapplicationsprimarilywithJavatechnologies Who areyou? Java and/orFlex Developer (Beginner) Just interested/curious Prerequisites: Basic Knowledgeof Java, REST, BlazeDS, Flex (haveheardofit)
What‘sit all about?
Whatyou (hopefully) will learn Cover the Basics (no 101) REST BlazeDS Jersey EnableFlextousethefullcapabilitiesof REST See someofourdailyroutinesduringthesoftwaredevelopmentprocess
Agenda REST CRUDelySummarized Can FLEX do REST? BlazeDS in 5 Minutes Puttingit all together (demo)
REST(RepresentationalState Transfer)CRUDelySummarized
REST Concepts Architectural style, not technology ! Client/server + Request/response approach. Stateless by nature (excellent for distributed systems) Cacheable (naturally supported !) Well known (HTTP) Easy Cool
HTTP Client REST Resource HTTP Request RESPONSE CODE 200 (OK) + BODY GET REQUEST
HTTP Client REST Resource HTTP Request RESPONSE CODE 200 (OK) + BODY GET REQUEST
REST Concepts Resources (nouns)Everythingis a resource ,identified by a URI:- http://www.flickr.com/photos/christianjunk- http://twitter.com/ESRI/favorites
HTTP Client REST Resource HTTP Request RESPONSE CODE 200 (OK) + BODY GET REQUEST
REST Concepts Uniform interface (verbs)REST reduces the syntax of web servicesto a small fixed set of database-derivedverbs
REST Concepts [1] The HEAD method is identical to GET except that the server MUST NOT return a message-body in the response.
HTTP Client REST Resource HTTP Request RESPONSE CODE 200 (OK) + BODY GET REQUEST
REST Concepts State RepresentationsData and state transferred between client and server:- XML, JSON, Atom, XHTML, etc.
http://api.twitter.com/ESRI/favorites.json
http://api.twitter.com/ESRI/favorites.xml
Google AJAX Search API http://code.google.com/apis/ajaxsearch/ Amazon S3 http://aws.amazon.com/s3 flickr http://www.flickr.com/services/api/ twitter http://apiwiki.twitter.com/ del.icio.us http://delicious.com/help/api
Can FLEX do REST?
With the HTTPServiceComponent you can only do a GET or a POST, no PUT or DELETE the HTTP status code returned in the response is not available (so you can’t get the id of a newly created resource from the ‘Location’ header and you can’t tell the difference between a ‘500 Internal Server Error’, a ‘404 Not Found’ or a ‘422 Validation Error’) there’s also no way to get the response body for anything not in the 2xx range (it fires a fault event for any HTTP response that does not have a status code of 200)
DEMO
BlazeDS
Whatisit? “BlazeDS is a server-based Java remoting and web messaging technology”
Remoting Messaging Proxying Servlet Container Database BlazeDS AMF/HTTP YourApplication
Without BlazeDS Flex applications can access back-end data using either the HTTPService or WebService components BlazeDS is a series of data services that provide your Flex applications with additional dataconnectivity options: Remoting Service (directly invoke methods of Java objects deployed in your application server) Message Service (provides a complete publish/subscribe infrastructure allowing Flex clients and the server to exchange messages in real time) HTTP Proxy Service (makecross-domain(!) servicerequests)
HTTP Proxy Service Servlet Container BlazeDS YourApplication
Alternatives?
Puttingit all together
Technologies/Tools for Development Flex + BlazeDS (RIA) Java Jersey (JAX-RS/JSR 311) -> Annotation + POJO = REST Apache Maven (Build Manager for Java Projects) IntelliJIdea / MyEclipse (Java IDEs)  Adobe FlexBuilder (Flex IDE) Apache Tomcat (Server/Servlet Container)
DEMO
QUESTIONS?
THANK YOU!

Mais conteúdo relacionado

Mais procurados

Flex And Java Integration
Flex And Java IntegrationFlex And Java Integration
Flex And Java Integration
ravinxg
 
Interoperability and Windows Communication Foundation (WCF) Overview
Interoperability and Windows Communication Foundation (WCF) OverviewInteroperability and Windows Communication Foundation (WCF) Overview
Interoperability and Windows Communication Foundation (WCF) Overview
Jorgen Thelin
 
1. WCF Services - Exam 70-487
1. WCF Services - Exam 70-4871. WCF Services - Exam 70-487
1. WCF Services - Exam 70-487
Bat Programmer
 
Xml web services
Xml web servicesXml web services
Xml web services
Raghu nath
 

Mais procurados (20)

Introduction to WCF
Introduction to WCFIntroduction to WCF
Introduction to WCF
 
Flex And Java Integration
Flex And Java IntegrationFlex And Java Integration
Flex And Java Integration
 
Flex And Java Integration
Flex And Java IntegrationFlex And Java Integration
Flex And Java Integration
 
WCF for begineers
WCF  for begineersWCF  for begineers
WCF for begineers
 
10 Tricks and Tips for WCF
10 Tricks and Tips for WCF10 Tricks and Tips for WCF
10 Tricks and Tips for WCF
 
Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)
 
WCF
WCFWCF
WCF
 
Interoperability and Windows Communication Foundation (WCF) Overview
Interoperability and Windows Communication Foundation (WCF) OverviewInteroperability and Windows Communication Foundation (WCF) Overview
Interoperability and Windows Communication Foundation (WCF) Overview
 
REST, JSON and RSS with WCF 3.5
REST, JSON and RSS with WCF 3.5REST, JSON and RSS with WCF 3.5
REST, JSON and RSS with WCF 3.5
 
WCF
WCFWCF
WCF
 
Introduction to web services and how to in php
Introduction to web services and how to in phpIntroduction to web services and how to in php
Introduction to web services and how to in php
 
Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0
 
WCF Fundamentals
WCF Fundamentals WCF Fundamentals
WCF Fundamentals
 
Webservices
WebservicesWebservices
Webservices
 
1. WCF Services - Exam 70-487
1. WCF Services - Exam 70-4871. WCF Services - Exam 70-487
1. WCF Services - Exam 70-487
 
Biz talk summit 2013 - The new cloud related adapters
Biz talk summit 2013 - The new cloud related adaptersBiz talk summit 2013 - The new cloud related adapters
Biz talk summit 2013 - The new cloud related adapters
 
FATC UK - Real time collaborative Flex apps
FATC UK - Real time collaborative Flex appsFATC UK - Real time collaborative Flex apps
FATC UK - Real time collaborative Flex apps
 
WCF Introduction
WCF IntroductionWCF Introduction
WCF Introduction
 
Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)
 
Xml web services
Xml web servicesXml web services
Xml web services
 

Destaque (9)

How Lucene Powers the LinkedIn Segmentation and Targeting Platform
How Lucene Powers the LinkedIn Segmentation and Targeting PlatformHow Lucene Powers the LinkedIn Segmentation and Targeting Platform
How Lucene Powers the LinkedIn Segmentation and Targeting Platform
 
Javaone 2010
Javaone 2010Javaone 2010
Javaone 2010
 
An introduction to Struts 2 and RESTful applications
An introduction to Struts 2 and RESTful applicationsAn introduction to Struts 2 and RESTful applications
An introduction to Struts 2 and RESTful applications
 
Building apps for multiple devices
Building apps for multiple devicesBuilding apps for multiple devices
Building apps for multiple devices
 
Making mobile flex apps blazing fast
Making mobile flex apps blazing fastMaking mobile flex apps blazing fast
Making mobile flex apps blazing fast
 
Qcon flex体系架构深度剖析
Qcon flex体系架构深度剖析Qcon flex体系架构深度剖析
Qcon flex体系架构深度剖析
 
FXG and Flex Mobile Development
FXG and Flex Mobile DevelopmentFXG and Flex Mobile Development
FXG and Flex Mobile Development
 
Deep Dive into Flex Mobile Item Renderers
Deep Dive into Flex Mobile Item RenderersDeep Dive into Flex Mobile Item Renderers
Deep Dive into Flex Mobile Item Renderers
 
LinkedIn Segmentation & Targeting Platform
LinkedIn Segmentation & Targeting PlatformLinkedIn Segmentation & Targeting Platform
LinkedIn Segmentation & Targeting Platform
 

Semelhante a Restful communication with Flex

Creating Web Services with Zend Framework - Matthew Turland
Creating Web Services with Zend Framework - Matthew TurlandCreating Web Services with Zend Framework - Matthew Turland
Creating Web Services with Zend Framework - Matthew Turland
Matthew Turland
 
Silverlight Document Search Engine
Silverlight Document Search EngineSilverlight Document Search Engine
Silverlight Document Search Engine
Mustata Bogdan
 

Semelhante a Restful communication with Flex (20)

REST Servers in Delphi XE Using DataSnap
REST Servers in Delphi XE Using DataSnapREST Servers in Delphi XE Using DataSnap
REST Servers in Delphi XE Using DataSnap
 
Rest overview briefing
Rest  overview briefingRest  overview briefing
Rest overview briefing
 
NET Event - Migrating WinForm
NET Event - Migrating WinFormNET Event - Migrating WinForm
NET Event - Migrating WinForm
 
HTML5: The Parts You Care About - 4/Nov/13 - PrDC Saskatoon, SK
HTML5: The Parts You Care About - 4/Nov/13 - PrDC Saskatoon, SKHTML5: The Parts You Care About - 4/Nov/13 - PrDC Saskatoon, SK
HTML5: The Parts You Care About - 4/Nov/13 - PrDC Saskatoon, SK
 
Experiences using CouchDB inside Microsoft's Azure team
Experiences using CouchDB inside Microsoft's Azure teamExperiences using CouchDB inside Microsoft's Azure team
Experiences using CouchDB inside Microsoft's Azure team
 
Creating Web Services with Zend Framework - Matthew Turland
Creating Web Services with Zend Framework - Matthew TurlandCreating Web Services with Zend Framework - Matthew Turland
Creating Web Services with Zend Framework - Matthew Turland
 
Adobe® Flex™
Adobe® Flex™Adobe® Flex™
Adobe® Flex™
 
What is Adobe Flex ?
What is Adobe Flex  ?What is Adobe Flex  ?
What is Adobe Flex ?
 
Silverlight Document Search Engine
Silverlight Document Search EngineSilverlight Document Search Engine
Silverlight Document Search Engine
 
ColdFusion 10
ColdFusion 10ColdFusion 10
ColdFusion 10
 
Vijay Oscon
Vijay OsconVijay Oscon
Vijay Oscon
 
Mike Taulty MIX10 Silverlight Frameworks and Patterns
Mike Taulty MIX10 Silverlight Frameworks and PatternsMike Taulty MIX10 Silverlight Frameworks and Patterns
Mike Taulty MIX10 Silverlight Frameworks and Patterns
 
A Microsoft primer for PHP devs
A Microsoft primer for PHP devsA Microsoft primer for PHP devs
A Microsoft primer for PHP devs
 
Introducing SOA and Oracle SOA Suite 11g for Database Professionals
Introducing SOA and Oracle SOA Suite 11g for Database ProfessionalsIntroducing SOA and Oracle SOA Suite 11g for Database Professionals
Introducing SOA and Oracle SOA Suite 11g for Database Professionals
 
Survey of restful web services frameworks
Survey of restful web services frameworksSurvey of restful web services frameworks
Survey of restful web services frameworks
 
PHP and Silverlight
PHP and SilverlightPHP and Silverlight
PHP and Silverlight
 
Flutter
FlutterFlutter
Flutter
 
Top 7 Skills PHP Developer Must Have
Top 7 Skills PHP Developer Must HaveTop 7 Skills PHP Developer Must Have
Top 7 Skills PHP Developer Must Have
 
Vijay Mix Presentation
Vijay Mix PresentationVijay Mix Presentation
Vijay Mix Presentation
 
Getting Started with Flex and PHP
Getting Started with Flex and PHPGetting Started with Flex and PHP
Getting Started with Flex and PHP
 

Último

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
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
 

Último (20)

CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
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...
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
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
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
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
 
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
 
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
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
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
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
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...
 

Restful communication with Flex

  • 1. Unleash the full power ofRESTful communication with FLEXChristian JunkESRI Developer Summit 2010, Palm Springs
  • 2. RESTful communication with FLEXChristian JunkESRI Developer Summit 2010, Palm Springs
  • 3. Who am I? Senior Software Developer @ http://www.alta4.com, Germany Developingbackendsfor web-basedapplicationsprimarilywithJavatechnologies Who areyou? Java and/orFlex Developer (Beginner) Just interested/curious Prerequisites: Basic Knowledgeof Java, REST, BlazeDS, Flex (haveheardofit)
  • 5. Whatyou (hopefully) will learn Cover the Basics (no 101) REST BlazeDS Jersey EnableFlextousethefullcapabilitiesof REST See someofourdailyroutinesduringthesoftwaredevelopmentprocess
  • 6. Agenda REST CRUDelySummarized Can FLEX do REST? BlazeDS in 5 Minutes Puttingit all together (demo)
  • 8. REST Concepts Architectural style, not technology ! Client/server + Request/response approach. Stateless by nature (excellent for distributed systems) Cacheable (naturally supported !) Well known (HTTP) Easy Cool
  • 9. HTTP Client REST Resource HTTP Request RESPONSE CODE 200 (OK) + BODY GET REQUEST
  • 10. HTTP Client REST Resource HTTP Request RESPONSE CODE 200 (OK) + BODY GET REQUEST
  • 11. REST Concepts Resources (nouns)Everythingis a resource ,identified by a URI:- http://www.flickr.com/photos/christianjunk- http://twitter.com/ESRI/favorites
  • 12. HTTP Client REST Resource HTTP Request RESPONSE CODE 200 (OK) + BODY GET REQUEST
  • 13. REST Concepts Uniform interface (verbs)REST reduces the syntax of web servicesto a small fixed set of database-derivedverbs
  • 14. REST Concepts [1] The HEAD method is identical to GET except that the server MUST NOT return a message-body in the response.
  • 15. HTTP Client REST Resource HTTP Request RESPONSE CODE 200 (OK) + BODY GET REQUEST
  • 16. REST Concepts State RepresentationsData and state transferred between client and server:- XML, JSON, Atom, XHTML, etc.
  • 19.
  • 20. Google AJAX Search API http://code.google.com/apis/ajaxsearch/ Amazon S3 http://aws.amazon.com/s3 flickr http://www.flickr.com/services/api/ twitter http://apiwiki.twitter.com/ del.icio.us http://delicious.com/help/api
  • 21. Can FLEX do REST?
  • 22. With the HTTPServiceComponent you can only do a GET or a POST, no PUT or DELETE the HTTP status code returned in the response is not available (so you can’t get the id of a newly created resource from the ‘Location’ header and you can’t tell the difference between a ‘500 Internal Server Error’, a ‘404 Not Found’ or a ‘422 Validation Error’) there’s also no way to get the response body for anything not in the 2xx range (it fires a fault event for any HTTP response that does not have a status code of 200)
  • 23. DEMO
  • 24.
  • 26. Whatisit? “BlazeDS is a server-based Java remoting and web messaging technology”
  • 27. Remoting Messaging Proxying Servlet Container Database BlazeDS AMF/HTTP YourApplication
  • 28. Without BlazeDS Flex applications can access back-end data using either the HTTPService or WebService components BlazeDS is a series of data services that provide your Flex applications with additional dataconnectivity options: Remoting Service (directly invoke methods of Java objects deployed in your application server) Message Service (provides a complete publish/subscribe infrastructure allowing Flex clients and the server to exchange messages in real time) HTTP Proxy Service (makecross-domain(!) servicerequests)
  • 29. HTTP Proxy Service Servlet Container BlazeDS YourApplication
  • 32. Technologies/Tools for Development Flex + BlazeDS (RIA) Java Jersey (JAX-RS/JSR 311) -> Annotation + POJO = REST Apache Maven (Build Manager for Java Projects) IntelliJIdea / MyEclipse (Java IDEs) Adobe FlexBuilder (Flex IDE) Apache Tomcat (Server/Servlet Container)
  • 33. DEMO