SlideShare ist ein Scribd-Unternehmen logo
1 von 29
RESThub What is RESThub ? Three independant layers Security Hosting Demos
What is RESThub ? http://resthub.org
What is RESThub ? Javascript Stack Java WebserviceStack Security & Identity  Generic Tests Documentation Java Middle Stack
Keywords behind RESThub
Generic DAO & Business Services HadesDao TESTED Generic Tested Extendable « extends » GenericDao GenericService Specific Testable Customized « extends » « extends » myDao myService
Generic DAO & Business Services Provides… CRUD methods (Create, Retrieve, Update, Delete) Allows… Save time (↘ copy-paste-adjust) on technical layers Improve efficiency on the development of business layers
Basic Example How to… obtain a complete DAO layer for my POJO? @Named("plopDao") publicclass PlopJpaDao extends GenericJpaDao<Plop> implements PlopDao { // Nothing } What else ?
DAO & Business Services stack Out of the box configuration Identity manager Multi-modules JPA entities scanning Generic DAO & ServicesGeneric tests Embeded database JSR 303 Bean validation Validator 1.2 Dependency injection Generic DAO Hades 2 3 3.5 Build system 3 JPA2 Persistenceengine
Generic REST Web Services Provides… Generic methods to access business services XML and JSON objects serialization Allows… Easily build applications REST-based architecture GenericController « extends » myController
Basic Example How to… retrieve a persisted object in database ? @GET @Path("/{id}") @Produces({MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON}) public Response getResource(@PathParam("id") ID id) { 	T entity = this.service.findById(id); if(entity == null) { return Response.status(Status.NOT_FOUND).build(); 	} return Response.ok(entity).build(); }
Webservices stack JSON Serialization OAuth2 based security Jackson 1.5 7.1 Run/Debug/Tests web application Generic webservices Generic tests JAX-RS REST Webservices Project templates (archetypes) Jersey 1.2
Generic Tests Provides Generic methods to test your DAO, Business services and Webservices Better protection against side effects caused by code changes Allows Focus on testing your project functionnalities
Basic Example How to… entirely test my DAO layer ? publicclass PlopDaoTest extends AbstractDaoTest<Plop, PlopDao> { 	@Inject 	@Named("plopDao") publicvoid setResourceDao(PlopDao resourceDao) { 		super.setResourceDao(resourceDao); 	} }
Use case 1 : RESThub + MVC Framework         Tapestry5    website Webservices Server side DAO and Services
Use case 2 : RESThub full stack JavaScript stackbasedWebsite Client side Webservices Server side DAOandServices
Javascript Stack for RIA WebApps Provides… Script loader Route manager Templating language Allows… Use the latest web technologies consistently Create lightweight RIA WebApps based on jQuery Reduce traffic and server load
Wellknownwebapp software design Web browser Reloading page for each action Dynamic pages Application server SOAP proxytoJSON HTTP server Images SOAPWeb Services MVC framework based Web GUI session CSS Business Services Webservice  SOAP Javascript DAO
RESThub based webapp software design Web browser Changing the state of one widget on each action Script loader HTML 5 based session MVC Framework  HTTP credentials JSON/XML Data Static pages Application server HTTP server OtherRESTWebservices Images REST Web Services CSS Business Services Javascript DAO HTML
JavaScript stack JavaScript library 1.4 Client side templating JavaScript stack core RESThub controller JavaScript loading on route event Route & session manager Sammy WADL explorer jQuery plugin Script loader JavaScript compressor
Consequences on the architecture Server is stateless Can change just a small part of the page Each part is independent (jQuery widget) URL are semantic (example.com/product/list) Client is statefull Recent browser provides « session storage » Each widget should knows his status Manage the reloading of the page (F5)
RESThub on hostingside Clear separation between static and dynamic Static: interface HTML5, JS, CSS Dynamic: stateless secure webservices Out of the box caching compliancy Even when pages are user-customized More operations are computed on client side Better scalability thanks to stateless servers
Security based on OAuth2 OAuth 2.0 basedauthentication Work in progress IETF standard Tokenbased Used on Facebook and Twitter Maybenext version of OpenIDwill use ittoo Different profiles User Agent profile Webserver profile Single Sign On
OAuth2 use case
Current flow
Demos Bookingdemo Hotelbooking Web application Hotelsearchengine Consult & cancel bookings Roundtabledemo Doodlelike Pollsearchengine Dev console
RESThub sample : Roundtable
RESThub sample : Booking
JavaScript HTML Route 1 Controller A View A Route 2 Controller B View B Route 3 Controller C View C URL Sammy Client side Route 4 Controller D View D Controller E View E Route 5 Resthub controller Events Web services Business services Server side DAO DB
Booking example (2) booking/book.js mode=edit hotel/view.js click(proceed) booking/edit.js booking/book.js booking/book.js mode=view mode=edit hotel/view.js click(revise) booking/view.js click(confirm) resthub.controller.js Ajax request home.js

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (20)

Berlin.JAR: Web future without web frameworks
Berlin.JAR: Web future without web frameworksBerlin.JAR: Web future without web frameworks
Berlin.JAR: Web future without web frameworks
 
Session 39 - Hibernate - Part 1
Session 39 - Hibernate - Part 1Session 39 - Hibernate - Part 1
Session 39 - Hibernate - Part 1
 
Session 30 - Servlets - Part 6
Session 30 - Servlets - Part 6Session 30 - Servlets - Part 6
Session 30 - Servlets - Part 6
 
Session 33 - Session Management using other Techniques
Session 33 - Session Management using other TechniquesSession 33 - Session Management using other Techniques
Session 33 - Session Management using other Techniques
 
Session 29 - Servlets - Part 5
Session 29 - Servlets - Part 5Session 29 - Servlets - Part 5
Session 29 - Servlets - Part 5
 
Session 31 - Session Management, Best Practices, Design Patterns in Web Apps
Session 31 - Session Management, Best Practices, Design Patterns in Web AppsSession 31 - Session Management, Best Practices, Design Patterns in Web Apps
Session 31 - Session Management, Best Practices, Design Patterns in Web Apps
 
Session 34 - JDBC Best Practices, Introduction to Design Patterns
Session 34 - JDBC Best Practices, Introduction to Design PatternsSession 34 - JDBC Best Practices, Introduction to Design Patterns
Session 34 - JDBC Best Practices, Introduction to Design Patterns
 
Session 28 - Servlets - Part 4
Session 28 - Servlets - Part 4Session 28 - Servlets - Part 4
Session 28 - Servlets - Part 4
 
Overview of atg framework
Overview of atg frameworkOverview of atg framework
Overview of atg framework
 
Uniface Lectures Webinar - Building Responsive Applications with Uniface: Dep...
Uniface Lectures Webinar - Building Responsive Applications with Uniface: Dep...Uniface Lectures Webinar - Building Responsive Applications with Uniface: Dep...
Uniface Lectures Webinar - Building Responsive Applications with Uniface: Dep...
 
Spring and DWR
Spring and DWRSpring and DWR
Spring and DWR
 
Session 26 - Servlets Part 2
Session 26 - Servlets Part 2Session 26 - Servlets Part 2
Session 26 - Servlets Part 2
 
ATG Framework,Formhandlers,Pricing
ATG Framework,Formhandlers,PricingATG Framework,Formhandlers,Pricing
ATG Framework,Formhandlers,Pricing
 
Oracle JET CRUD and ADF BC REST
Oracle JET CRUD and ADF BC RESTOracle JET CRUD and ADF BC REST
Oracle JET CRUD and ADF BC REST
 
Session 35 - Design Patterns
Session 35 - Design PatternsSession 35 - Design Patterns
Session 35 - Design Patterns
 
Session 37 - JSP - Part 2 (final)
Session 37 - JSP - Part 2 (final)Session 37 - JSP - Part 2 (final)
Session 37 - JSP - Part 2 (final)
 
JavaEE6 my way
JavaEE6 my wayJavaEE6 my way
JavaEE6 my way
 
JavaCro'14 - Drools Decision tables – form of human-readable rules – Dragan J...
JavaCro'14 - Drools Decision tables – form of human-readable rules – Dragan J...JavaCro'14 - Drools Decision tables – form of human-readable rules – Dragan J...
JavaCro'14 - Drools Decision tables – form of human-readable rules – Dragan J...
 
Java Microservices with DropWizard
Java Microservices with DropWizardJava Microservices with DropWizard
Java Microservices with DropWizard
 
Introduction to asp .net
Introduction to asp .netIntroduction to asp .net
Introduction to asp .net
 

Ähnlich wie Resthub

Dh2 Apps Training Part2
Dh2   Apps Training Part2Dh2   Apps Training Part2
Dh2 Apps Training Part2
jamram82
 

Ähnlich wie Resthub (20)

Resthub lyonjug
Resthub lyonjugResthub lyonjug
Resthub lyonjug
 
Jsp Comparison
 Jsp Comparison Jsp Comparison
Jsp Comparison
 
Introduction to Alfresco Surf Platform
Introduction to Alfresco Surf PlatformIntroduction to Alfresco Surf Platform
Introduction to Alfresco Surf Platform
 
Sun Web Server Brief
Sun Web Server BriefSun Web Server Brief
Sun Web Server Brief
 
ASPNET Roadmap
ASPNET RoadmapASPNET Roadmap
ASPNET Roadmap
 
JSF 2.0 Preview
JSF 2.0 PreviewJSF 2.0 Preview
JSF 2.0 Preview
 
Sun Web Server Brief
Sun Web Server BriefSun Web Server Brief
Sun Web Server Brief
 
Mashups
MashupsMashups
Mashups
 
Cloud State of the Union for Java Developers
Cloud State of the Union for Java DevelopersCloud State of the Union for Java Developers
Cloud State of the Union for Java Developers
 
CloudConnect 2011 - Building Highly Scalable Java Applications on Windows Azure
CloudConnect 2011 - Building Highly Scalable Java Applications on Windows AzureCloudConnect 2011 - Building Highly Scalable Java Applications on Windows Azure
CloudConnect 2011 - Building Highly Scalable Java Applications on Windows Azure
 
AJppt.pptx
AJppt.pptxAJppt.pptx
AJppt.pptx
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
 
Dh2 Apps Training Part2
Dh2   Apps Training Part2Dh2   Apps Training Part2
Dh2 Apps Training Part2
 
Customizing Oracle EBS OA Framework
Customizing Oracle EBS OA FrameworkCustomizing Oracle EBS OA Framework
Customizing Oracle EBS OA Framework
 
An Introduction to Websphere sMash for PHP Programmers
An Introduction to Websphere sMash for PHP ProgrammersAn Introduction to Websphere sMash for PHP Programmers
An Introduction to Websphere sMash for PHP Programmers
 
Java one 2010
Java one 2010Java one 2010
Java one 2010
 
Clojure Web Development
Clojure Web DevelopmentClojure Web Development
Clojure Web Development
 
Widget Platform
Widget PlatformWidget Platform
Widget Platform
 
Advanced JavaScript
Advanced JavaScriptAdvanced JavaScript
Advanced JavaScript
 
JavaScript on the server - Node.js
JavaScript on the server - Node.jsJavaScript on the server - Node.js
JavaScript on the server - Node.js
 

Mehr von Sébastien Deleuze (8)

Dart JUG 2013
Dart JUG 2013Dart JUG 2013
Dart JUG 2013
 
Dart : one language to rule them all - MixIT 2013
Dart : one language to rule them all - MixIT 2013Dart : one language to rule them all - MixIT 2013
Dart : one language to rule them all - MixIT 2013
 
Resthub framework presentation
Resthub framework presentationResthub framework presentation
Resthub framework presentation
 
Presentation DVCS - Git - Mercurial au LyonJug
Presentation DVCS - Git - Mercurial au LyonJugPresentation DVCS - Git - Mercurial au LyonJug
Presentation DVCS - Git - Mercurial au LyonJug
 
Openscales Foss4g 2010 presentation
Openscales Foss4g 2010 presentationOpenscales Foss4g 2010 presentation
Openscales Foss4g 2010 presentation
 
02 create first-map
02 create first-map02 create first-map
02 create first-map
 
01 configure your-project
01 configure your-project01 configure your-project
01 configure your-project
 
03 add markers
03 add markers03 add markers
03 add markers
 

Kürzlich hochgeladen

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 

Kürzlich hochgeladen (20)

Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
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
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
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
 
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
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
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
 
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
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 

Resthub

  • 1. RESThub What is RESThub ? Three independant layers Security Hosting Demos
  • 2. What is RESThub ? http://resthub.org
  • 3. What is RESThub ? Javascript Stack Java WebserviceStack Security & Identity Generic Tests Documentation Java Middle Stack
  • 5. Generic DAO & Business Services HadesDao TESTED Generic Tested Extendable « extends » GenericDao GenericService Specific Testable Customized « extends » « extends » myDao myService
  • 6. Generic DAO & Business Services Provides… CRUD methods (Create, Retrieve, Update, Delete) Allows… Save time (↘ copy-paste-adjust) on technical layers Improve efficiency on the development of business layers
  • 7. Basic Example How to… obtain a complete DAO layer for my POJO? @Named("plopDao") publicclass PlopJpaDao extends GenericJpaDao<Plop> implements PlopDao { // Nothing } What else ?
  • 8. DAO & Business Services stack Out of the box configuration Identity manager Multi-modules JPA entities scanning Generic DAO & ServicesGeneric tests Embeded database JSR 303 Bean validation Validator 1.2 Dependency injection Generic DAO Hades 2 3 3.5 Build system 3 JPA2 Persistenceengine
  • 9. Generic REST Web Services Provides… Generic methods to access business services XML and JSON objects serialization Allows… Easily build applications REST-based architecture GenericController « extends » myController
  • 10. Basic Example How to… retrieve a persisted object in database ? @GET @Path("/{id}") @Produces({MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON}) public Response getResource(@PathParam("id") ID id) { T entity = this.service.findById(id); if(entity == null) { return Response.status(Status.NOT_FOUND).build(); } return Response.ok(entity).build(); }
  • 11. Webservices stack JSON Serialization OAuth2 based security Jackson 1.5 7.1 Run/Debug/Tests web application Generic webservices Generic tests JAX-RS REST Webservices Project templates (archetypes) Jersey 1.2
  • 12. Generic Tests Provides Generic methods to test your DAO, Business services and Webservices Better protection against side effects caused by code changes Allows Focus on testing your project functionnalities
  • 13. Basic Example How to… entirely test my DAO layer ? publicclass PlopDaoTest extends AbstractDaoTest<Plop, PlopDao> { @Inject @Named("plopDao") publicvoid setResourceDao(PlopDao resourceDao) { super.setResourceDao(resourceDao); } }
  • 14. Use case 1 : RESThub + MVC Framework Tapestry5 website Webservices Server side DAO and Services
  • 15. Use case 2 : RESThub full stack JavaScript stackbasedWebsite Client side Webservices Server side DAOandServices
  • 16. Javascript Stack for RIA WebApps Provides… Script loader Route manager Templating language Allows… Use the latest web technologies consistently Create lightweight RIA WebApps based on jQuery Reduce traffic and server load
  • 17. Wellknownwebapp software design Web browser Reloading page for each action Dynamic pages Application server SOAP proxytoJSON HTTP server Images SOAPWeb Services MVC framework based Web GUI session CSS Business Services Webservice SOAP Javascript DAO
  • 18. RESThub based webapp software design Web browser Changing the state of one widget on each action Script loader HTML 5 based session MVC Framework HTTP credentials JSON/XML Data Static pages Application server HTTP server OtherRESTWebservices Images REST Web Services CSS Business Services Javascript DAO HTML
  • 19. JavaScript stack JavaScript library 1.4 Client side templating JavaScript stack core RESThub controller JavaScript loading on route event Route & session manager Sammy WADL explorer jQuery plugin Script loader JavaScript compressor
  • 20. Consequences on the architecture Server is stateless Can change just a small part of the page Each part is independent (jQuery widget) URL are semantic (example.com/product/list) Client is statefull Recent browser provides « session storage » Each widget should knows his status Manage the reloading of the page (F5)
  • 21. RESThub on hostingside Clear separation between static and dynamic Static: interface HTML5, JS, CSS Dynamic: stateless secure webservices Out of the box caching compliancy Even when pages are user-customized More operations are computed on client side Better scalability thanks to stateless servers
  • 22. Security based on OAuth2 OAuth 2.0 basedauthentication Work in progress IETF standard Tokenbased Used on Facebook and Twitter Maybenext version of OpenIDwill use ittoo Different profiles User Agent profile Webserver profile Single Sign On
  • 25. Demos Bookingdemo Hotelbooking Web application Hotelsearchengine Consult & cancel bookings Roundtabledemo Doodlelike Pollsearchengine Dev console
  • 26. RESThub sample : Roundtable
  • 27. RESThub sample : Booking
  • 28. JavaScript HTML Route 1 Controller A View A Route 2 Controller B View B Route 3 Controller C View C URL Sammy Client side Route 4 Controller D View D Controller E View E Route 5 Resthub controller Events Web services Business services Server side DAO DB
  • 29. Booking example (2) booking/book.js mode=edit hotel/view.js click(proceed) booking/edit.js booking/book.js booking/book.js mode=view mode=edit hotel/view.js click(revise) booking/view.js click(confirm) resthub.controller.js Ajax request home.js