SlideShare a Scribd company logo
The web framework dream team Johan Eltes [email_address] www.callistaenterprise.se
Agenda Customer Case Background Requirements The reference architecture The frameworks and their contributions Lessons learned The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB
Strategic drivers behind reference architecture The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB … National IT strategi for healthcare Regional strategi Regional projects IT architecture Portal framework
IT Architecture for VGRegion Healthcare Core Healthcare interop infrastructure Legacy EPR 1 Legacy EPR 2 Internal log Internal log … Internal Workflow Internal Workflow Gradual adoption of legacy healthcare systems Unified Information View (portal) EPR My Tasks SOAPlatform Alarming and logging Portal framework People Directory Internal roles database LabProcess Internal roles database Adapters Adapters Workflow Engine YP Legacy Lab System Internal log Internal Workflow Internal roles database Adapters Taxonomy services New business process support (composite apps), utilizing service enabled back-ends  Native Services
Layered View Back-end enterprise resources Canonical (Enterprise) Services Composite Applications Business Model Workflow Presentation Composite Services Local development. Put together a development framework! SOA  Platform COTS and semi-COTS
Requirement: “Use-Case-as-service” The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Usecase  Process Service Data Service Business Value
Requirement: Portability The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Container portability (Java EE) Portability across Web app and Portlet Web-app Portlet
Requirement: Web designer friendly templating technology The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB NetWeaver Design in DreamWeaver Development in XML editor
Requirement: Support Verva web design requirements Graceful degradation Always functional Usability proportional to browser capabilities Example JavaScript disabled The web framework dream team , Slide  Copyright 2007, Callista Enterprise AB
Requirements: Agile Development environment No IDE / Developer set-up lock-in Portable builds IDE settings / projects generated from build files (“build file is master”) Reasonable hardware requirements Run well in VMWare on mid-range laptop Broad, practical availability of tooling Consultant-friendly Fast code-test-debug cycle Do not require deploy in WebSphere Portal for developer testing “ Remove” inherent web programming issues / cost drivers The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB
Major Challenge: Re-use at Use-Case-level The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Usecase  Process Service Data Service Business Value
How will Use-cases become components? The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Demo
Use-cases as Components The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Semantically equivalent to calling modal dialog in Swing! Composite Application «webcomp» :Edit Address Entry «webcomp» :NewCategory «webcomp» :AddressList 1: editAddressEntry(long) :entryId of new Entry 1.1: addNewCategory() :CategoryId 1.2: addNewCategory() :CategoryId
Web realization versus Rich Client Think ”Modal sub dialogs” Each dialog is tied to back-end logic The web framework dream team ,  Slide  Copyright 2008, Callista Enterprise AB Use-case logic Back-end services
Re-use in another composite application The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB
Adding portability… WEB-INF artifacts are not portable - nor composable We can’t depend on JSPs A use-case web component will have to be a jar files that works on WEB-INF/lib whether portlet or webapp (formulera om) The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Portlet WebApp «webcomp» :Edit Address Entry
“ Remove” inherent web programming issues  The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB public class Game extends Element { private static Random randomNumbers = new Random(); public void processElement() { Template template = getHtmlTemplate(&quot;game&quot;); int answer = 0, guesses = 0, guess = -1; answer = randomNumbers.nextInt(101); while (guess != answer) { print(template); pause(); template.clear(); guess = getParameterInt(&quot;guess&quot;, -1); if (guess < 0 || guess > 100) { template.setBlock(&quot;warning&quot;, &quot;invalid&quot;); continue; } guesses++; if (answer < guess)  template.setBlock(&quot;msg&quot;, &quot;lower&quot;); else if (answer > guess) template.setBlock(&quot;msg&quot;, &quot;higher&quot;); } ContinuationContext.getActiveContext().removeContextTree(); template = getHtmlTemplate(&quot;success&quot;); template.setValue(&quot;answer&quot;, answer); template.setValue(&quot;guesses&quot;, guesses); print(template); } } 0. Get a random number between 0 and 100 1. Show the guess-form 2. Repeat until successful guess: 2.1. The user enters a value and submits the form 2.2. Validate the guess. I error (not between 0 and 100), continue at 2. 2.3. Unless successful guess, show whether the guess was under or above the answer. 2.4. Display guess-form. 3.0 Show congratulations screen with number of guesses.
Reduce semantic gap: Flow of events Continuations  Code flow mirrors use-case flow Supporting technologies Code in Java The RIFE framework Code in XML Spring WebFlow The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB
The resulting reference architecture The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB
Systemnivå: Komponenthierarki Web Framework Dream Team, Slide  Copyright 2008, Callista Enterprise AB : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Entitetskomponent 1 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Processkomponent 1 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt
Logisk nivå (system-nivå): Beroenden vid återanvändning av web-dialog Web Framework Dream Team, Slide  Copyright 2008, Callista Enterprise AB : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Entitetskomponent 1 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Processkomponent 1 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt
Design-nivå: Beroenden vid återanvändning av web-komposit The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Hierakiskt beroende i systemmodellen
Logisk nivå (system-nivå): Beroenden vid återanvändning av komponenttjänst Web Framework Dream Team, Slide  Copyright 2008, Callista Enterprise AB : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Entitetskomponent 2 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Processkomponent 2 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt
Design-nivå: Beroenden vid återanvändning av service-komposit The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Hierakiskt beroende i systemmodellen
Dynamic view (runtime perspective) The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Business Component 1 Business Component 2 Composite Application <webcomp> Address List <webcomp> Add Category <webcomp> Address Entry
Selected frameworks Core requirements Complete workflow in composable archives (jar files) Empty web-inf (breaking the monolith web app) Continuations (remove semantic gap) Spring WebFlow – Use-case logic Clean separation of workflow logic Powerful, expressive, simple, continuation-based Facelets - Presentation None-intrusive to html Supports jar packaging! Made for JSF (unlike JSP) JSF – Request processing Standard and does support jar-packaging “ Hidden” by Spring WebFlow The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB
Anatomy of a web use-case component (web composite) The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Presentation Use-case logic Back-end integration Input / output parameters Context for use-case component instance state «webcomp» :Category
Anatomy of a web use-case component (web composite) The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Presentation Use-case logic Back-end integration Input / output parameters Context for use-case component instance state Spring WebFlow: category-flow.xml «webcomp» :Category
WebFlow – Sample – AddressEntryComposite Open ESB, Slide  Copyright 2007, Callista Enterprise AB «action» getNewOrExistingAddressEntity start «view» editAddressEntry «action» save «subflow» enterNewCategory «action» assignNewCategory exit «flow» «flow» «flow» ok «flow» cancel «flow» «flow» cancel add category
Anatomy of a web use-case component (web composite) The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Presentation Use-case logic Back-end integration Input / output parameters Context for use-case component instance state Facelets: Category.xhtml «webcomp» :Category
Facelets– Sample – Category Composite None-intrusive to html Supports jar packaging (loading of views from class-path) Made for JSF (unlike JSP) The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB <h:commandLink action=“viewAddressEntryAction” ..>
Anatomy of a web use-case component (web composite) The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Presentation Use-case logic Back-end integration Input / output parameters Context for use-case component instance state Java: CategoryFlowSupport.java Façade per use-case component. Additional model beans  when required «webcomp» :Category
Use-case façade The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB
But what about JSF? Just for bootstrapping Spring Webflow Generic faces-config in web-app No footprint in web composites The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB <?xml version=&quot;1.0&quot;?> <!DOCTYPE faces-config PUBLIC &quot;-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN&quot; &quot;http://java.sun.com/dtd/web-facesconfig_1_0.dtd&quot;> <faces-config> <application> <navigation-handler> org.springframework.webflow.executor.jsf.FlowNavigationHandler </navigation-handler> <variable-resolver> org.springframework.webflow.executor.jsf.DelegatingFlowVariableResolver </variable-resolver> <view-handler>com.sun.facelets.FaceletViewHandler</view-handler> </application> <lifecycle> <phase-listener> org.springframework.webflow.executor.jsf.FlowPhaseListener </phase-listener> </lifecycle> </faces-config>JSF
Environments Development Apache Tomcat with Apache Pluto Eclipse 3.3 (Europa) with WTP Deployment WebSphere Application Server 6.1 WebSphere Portal Server 6.0 Build system Maven 2 – manages the component architecture Generates Eclipse dependencies and project files Web Framework Dream Team, Slide  Copyright 2008, Callista Enterprise AB
Lessons learned Webflow Revolution for html centric web applications The foundation for use-case componentization WebFlow validation framework tied into SpringMVC On the agenda for next version… Facelets Momentum depends on Seam Servlet required for loading web resources (images etc) from jar files (web composites) Intuitive Portability Native JSF implementations are not fully portable. We ended up bundling MyFaces rather than deploying to WebSphere JSF implementation (Sun RI) The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB
Summary Re-usable Use-case Components Delivered! The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB Usecase  Process Service Data Service Business Value  … by the dream team: Spring WebFlow, Facelets, JSF, a reference architecture and some glue
Time (?) for Questions! The web framework dream team , Slide  Copyright 2008, Callista Enterprise AB

More Related Content

PDF
Java EE Revisits GoF Design Patterns
PPTX
Move from J2EE to Java EE
PDF
Integration patterns and practices for cloud and mobile computing
PDF
Laszlo PyCon 2005
PDF
Modern development paradigms
PDF
HTML5: the new frontier of the web
PDF
Programming-best practices( beginner) ADF_fusionapps
PPTX
Oracle JET overview
Java EE Revisits GoF Design Patterns
Move from J2EE to Java EE
Integration patterns and practices for cloud and mobile computing
Laszlo PyCon 2005
Modern development paradigms
HTML5: the new frontier of the web
Programming-best practices( beginner) ADF_fusionapps
Oracle JET overview

What's hot (20)

PPT
Oracle SOA Suite 11g Mediator vs. Oracle Service Bus (OSB)
PDF
Upcoming JDeveloper ADF Business Components REST support
PPTX
Oracle OpenWorld 2011 - Oracle Application Express within the Oracle SOA Suite
PPTX
Essential Kit for Oracle JET Programming
PDF
JavaOne 2011: Migrating Spring Applications to Java EE 6
PDF
Java EE 8 - An instant snapshot
PDF
Java EE 6 Adoption in One of the World’s Largest Online Financial Systems [Ja...
PDF
Getting your grips on Excel chaos
PPTX
A-Team Mobile Persistence Accelerator Overview
PDF
How Scala, Wicket, and Java EE Can Improve Web Development
PPSX
Oracle ADF Overview for Beginners
PDF
SAP NetWeaver Gateway - Gateway Service Consumption
PDF
How to choose the right Integration Framework - Apache Camel (JBoss, Talend),...
DOC
Alexander Zeng
PDF
Restful Services
PDF
Batch Applications for Java Platform 1.0: Java EE 7 and GlassFish
PPT
Have You Seen Java EE Lately?
PDF
Integrating SAP the Java EE Way - JBoss One Day talk 2012
PDF
Building beacon-enabled apps with Oracle MCS
PDF
NetWeaver Gateway- Gateway Service Consumption
Oracle SOA Suite 11g Mediator vs. Oracle Service Bus (OSB)
Upcoming JDeveloper ADF Business Components REST support
Oracle OpenWorld 2011 - Oracle Application Express within the Oracle SOA Suite
Essential Kit for Oracle JET Programming
JavaOne 2011: Migrating Spring Applications to Java EE 6
Java EE 8 - An instant snapshot
Java EE 6 Adoption in One of the World’s Largest Online Financial Systems [Ja...
Getting your grips on Excel chaos
A-Team Mobile Persistence Accelerator Overview
How Scala, Wicket, and Java EE Can Improve Web Development
Oracle ADF Overview for Beginners
SAP NetWeaver Gateway - Gateway Service Consumption
How to choose the right Integration Framework - Apache Camel (JBoss, Talend),...
Alexander Zeng
Restful Services
Batch Applications for Java Platform 1.0: Java EE 7 and GlassFish
Have You Seen Java EE Lately?
Integrating SAP the Java EE Way - JBoss One Day talk 2012
Building beacon-enabled apps with Oracle MCS
NetWeaver Gateway- Gateway Service Consumption
Ad

Viewers also liked (8)

PDF
Invånar styrd åtkomst av patientdata
PDF
2013 mobile health summit
PPT
Asynch Soa
PDF
OAuth2 in swedish healthcare
PPTX
Asynchronous Service Server
PPT
DCI with groovy
PDF
2013 10-16 sundsvall42 journaluppgifter i appar
PPTX
10 år av standarder med standarder i nationell ohälsa
Invånar styrd åtkomst av patientdata
2013 mobile health summit
Asynch Soa
OAuth2 in swedish healthcare
Asynchronous Service Server
DCI with groovy
2013 10-16 sundsvall42 journaluppgifter i appar
10 år av standarder med standarder i nationell ohälsa
Ad

Similar to The Web Framework Dream Team (20)

PPT
ASP.NET AJAX with Visual Studio 2008
PPT
Developing Java Web Applications
PPT
Mashups
PPT
Google App Engine for Java
PPT
Report From Oracle Open World 2008 AMIS 2 October2008
ODP
Caerusone
PPT
Atlas Php
PPT
Web II - 01 - Introduction to server-side development
PPTX
An Introduction to Web Components
PPT
D22 portlet development with open source frameworks
PPT
D22 Portlet Development With Open Source Frameworks
PPT
IBM WebSphere Portal
PPT
PDF
Dev309 from asgard to zuul - netflix oss-final
PPTX
J2EE PPT --CINTHIYA.M Krishnammal college for women
PDF
Google Web Toolkit
PPT
ASP_NET_Architecture_Interfgfgfgnals1.ppt
PDF
Integrating ASP.NET AJAX with SharePoint
PPT
2.J2EE_Overview.ppt
PPT
2.j2 ee overview
ASP.NET AJAX with Visual Studio 2008
Developing Java Web Applications
Mashups
Google App Engine for Java
Report From Oracle Open World 2008 AMIS 2 October2008
Caerusone
Atlas Php
Web II - 01 - Introduction to server-side development
An Introduction to Web Components
D22 portlet development with open source frameworks
D22 Portlet Development With Open Source Frameworks
IBM WebSphere Portal
Dev309 from asgard to zuul - netflix oss-final
J2EE PPT --CINTHIYA.M Krishnammal college for women
Google Web Toolkit
ASP_NET_Architecture_Interfgfgfgnals1.ppt
Integrating ASP.NET AJAX with SharePoint
2.J2EE_Overview.ppt
2.j2 ee overview

More from Johan Eltes (12)

PPTX
2018 04-25 vitalis refark telemedicin
PPTX
Sweden on fhir - status report
PPTX
The ehealth architecture of the Swedish public healthcare payers
PPTX
Presentation of a pre-study on a national ecosystem for a shared medication r...
PPTX
Nordic reference architecture personal connected health
PDF
Swedish Health Innovation Resources at Stanford Med-X
PPTX
2014 04-08 arkitektur för gemensam informationsförsörjning
PPTX
2016 04-06 vitalis nordic reference architecture personal connected health
PDF
How Sweden improved patient self service with ehealth
PPT
PPT
Reference Architecture
PDF
Java EE6 CDI
2018 04-25 vitalis refark telemedicin
Sweden on fhir - status report
The ehealth architecture of the Swedish public healthcare payers
Presentation of a pre-study on a national ecosystem for a shared medication r...
Nordic reference architecture personal connected health
Swedish Health Innovation Resources at Stanford Med-X
2014 04-08 arkitektur för gemensam informationsförsörjning
2016 04-06 vitalis nordic reference architecture personal connected health
How Sweden improved patient self service with ehealth
Reference Architecture
Java EE6 CDI

Recently uploaded (20)

PDF
Machine learning based COVID-19 study performance prediction
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PDF
Modernizing your data center with Dell and AMD
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
KodekX | Application Modernization Development
PDF
Review of recent advances in non-invasive hemoglobin estimation
PDF
Electronic commerce courselecture one. Pdf
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
cuic standard and advanced reporting.pdf
PPT
Teaching material agriculture food technology
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
Empathic Computing: Creating Shared Understanding
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Approach and Philosophy of On baking technology
PDF
Encapsulation_ Review paper, used for researhc scholars
PPTX
Understanding_Digital_Forensics_Presentation.pptx
Machine learning based COVID-19 study performance prediction
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
CIFDAQ's Market Insight: SEC Turns Pro Crypto
Modernizing your data center with Dell and AMD
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Per capita expenditure prediction using model stacking based on satellite ima...
KodekX | Application Modernization Development
Review of recent advances in non-invasive hemoglobin estimation
Electronic commerce courselecture one. Pdf
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
cuic standard and advanced reporting.pdf
Teaching material agriculture food technology
Diabetes mellitus diagnosis method based random forest with bat algorithm
Digital-Transformation-Roadmap-for-Companies.pptx
Empathic Computing: Creating Shared Understanding
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Approach and Philosophy of On baking technology
Encapsulation_ Review paper, used for researhc scholars
Understanding_Digital_Forensics_Presentation.pptx

The Web Framework Dream Team

  • 1. The web framework dream team Johan Eltes [email_address] www.callistaenterprise.se
  • 2. Agenda Customer Case Background Requirements The reference architecture The frameworks and their contributions Lessons learned The web framework dream team , Slide Copyright 2008, Callista Enterprise AB
  • 3. Strategic drivers behind reference architecture The web framework dream team , Slide Copyright 2008, Callista Enterprise AB … National IT strategi for healthcare Regional strategi Regional projects IT architecture Portal framework
  • 4. IT Architecture for VGRegion Healthcare Core Healthcare interop infrastructure Legacy EPR 1 Legacy EPR 2 Internal log Internal log … Internal Workflow Internal Workflow Gradual adoption of legacy healthcare systems Unified Information View (portal) EPR My Tasks SOAPlatform Alarming and logging Portal framework People Directory Internal roles database LabProcess Internal roles database Adapters Adapters Workflow Engine YP Legacy Lab System Internal log Internal Workflow Internal roles database Adapters Taxonomy services New business process support (composite apps), utilizing service enabled back-ends Native Services
  • 5. Layered View Back-end enterprise resources Canonical (Enterprise) Services Composite Applications Business Model Workflow Presentation Composite Services Local development. Put together a development framework! SOA Platform COTS and semi-COTS
  • 6. Requirement: “Use-Case-as-service” The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Usecase Process Service Data Service Business Value
  • 7. Requirement: Portability The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Container portability (Java EE) Portability across Web app and Portlet Web-app Portlet
  • 8. Requirement: Web designer friendly templating technology The web framework dream team , Slide Copyright 2008, Callista Enterprise AB NetWeaver Design in DreamWeaver Development in XML editor
  • 9. Requirement: Support Verva web design requirements Graceful degradation Always functional Usability proportional to browser capabilities Example JavaScript disabled The web framework dream team , Slide Copyright 2007, Callista Enterprise AB
  • 10. Requirements: Agile Development environment No IDE / Developer set-up lock-in Portable builds IDE settings / projects generated from build files (“build file is master”) Reasonable hardware requirements Run well in VMWare on mid-range laptop Broad, practical availability of tooling Consultant-friendly Fast code-test-debug cycle Do not require deploy in WebSphere Portal for developer testing “ Remove” inherent web programming issues / cost drivers The web framework dream team , Slide Copyright 2008, Callista Enterprise AB
  • 11. Major Challenge: Re-use at Use-Case-level The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Usecase Process Service Data Service Business Value
  • 12. How will Use-cases become components? The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Demo
  • 13. Use-cases as Components The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Semantically equivalent to calling modal dialog in Swing! Composite Application «webcomp» :Edit Address Entry «webcomp» :NewCategory «webcomp» :AddressList 1: editAddressEntry(long) :entryId of new Entry 1.1: addNewCategory() :CategoryId 1.2: addNewCategory() :CategoryId
  • 14. Web realization versus Rich Client Think ”Modal sub dialogs” Each dialog is tied to back-end logic The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Use-case logic Back-end services
  • 15. Re-use in another composite application The web framework dream team , Slide Copyright 2008, Callista Enterprise AB
  • 16. Adding portability… WEB-INF artifacts are not portable - nor composable We can’t depend on JSPs A use-case web component will have to be a jar files that works on WEB-INF/lib whether portlet or webapp (formulera om) The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Portlet WebApp «webcomp» :Edit Address Entry
  • 17. “ Remove” inherent web programming issues The web framework dream team , Slide Copyright 2008, Callista Enterprise AB public class Game extends Element { private static Random randomNumbers = new Random(); public void processElement() { Template template = getHtmlTemplate(&quot;game&quot;); int answer = 0, guesses = 0, guess = -1; answer = randomNumbers.nextInt(101); while (guess != answer) { print(template); pause(); template.clear(); guess = getParameterInt(&quot;guess&quot;, -1); if (guess < 0 || guess > 100) { template.setBlock(&quot;warning&quot;, &quot;invalid&quot;); continue; } guesses++; if (answer < guess) template.setBlock(&quot;msg&quot;, &quot;lower&quot;); else if (answer > guess) template.setBlock(&quot;msg&quot;, &quot;higher&quot;); } ContinuationContext.getActiveContext().removeContextTree(); template = getHtmlTemplate(&quot;success&quot;); template.setValue(&quot;answer&quot;, answer); template.setValue(&quot;guesses&quot;, guesses); print(template); } } 0. Get a random number between 0 and 100 1. Show the guess-form 2. Repeat until successful guess: 2.1. The user enters a value and submits the form 2.2. Validate the guess. I error (not between 0 and 100), continue at 2. 2.3. Unless successful guess, show whether the guess was under or above the answer. 2.4. Display guess-form. 3.0 Show congratulations screen with number of guesses.
  • 18. Reduce semantic gap: Flow of events Continuations Code flow mirrors use-case flow Supporting technologies Code in Java The RIFE framework Code in XML Spring WebFlow The web framework dream team , Slide Copyright 2008, Callista Enterprise AB
  • 19. The resulting reference architecture The web framework dream team , Slide Copyright 2008, Callista Enterprise AB
  • 20. Systemnivå: Komponenthierarki Web Framework Dream Team, Slide Copyright 2008, Callista Enterprise AB : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Entitetskomponent 1 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Processkomponent 1 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt
  • 21. Logisk nivå (system-nivå): Beroenden vid återanvändning av web-dialog Web Framework Dream Team, Slide Copyright 2008, Callista Enterprise AB : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Entitetskomponent 1 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Processkomponent 1 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt
  • 22. Design-nivå: Beroenden vid återanvändning av web-komposit The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Hierakiskt beroende i systemmodellen
  • 23. Logisk nivå (system-nivå): Beroenden vid återanvändning av komponenttjänst Web Framework Dream Team, Slide Copyright 2008, Callista Enterprise AB : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Entitetskomponent 2 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt : Entitetskomponent Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt : Processkomponent 2 Resursskikt Verksamhetsskikt Komponenttjänst Anslutningsskikt Integrationstjänst Webgränssnitt
  • 24. Design-nivå: Beroenden vid återanvändning av service-komposit The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Hierakiskt beroende i systemmodellen
  • 25. Dynamic view (runtime perspective) The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Business Component 1 Business Component 2 Composite Application <webcomp> Address List <webcomp> Add Category <webcomp> Address Entry
  • 26. Selected frameworks Core requirements Complete workflow in composable archives (jar files) Empty web-inf (breaking the monolith web app) Continuations (remove semantic gap) Spring WebFlow – Use-case logic Clean separation of workflow logic Powerful, expressive, simple, continuation-based Facelets - Presentation None-intrusive to html Supports jar packaging! Made for JSF (unlike JSP) JSF – Request processing Standard and does support jar-packaging “ Hidden” by Spring WebFlow The web framework dream team , Slide Copyright 2008, Callista Enterprise AB
  • 27. Anatomy of a web use-case component (web composite) The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Presentation Use-case logic Back-end integration Input / output parameters Context for use-case component instance state «webcomp» :Category
  • 28. Anatomy of a web use-case component (web composite) The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Presentation Use-case logic Back-end integration Input / output parameters Context for use-case component instance state Spring WebFlow: category-flow.xml «webcomp» :Category
  • 29. WebFlow – Sample – AddressEntryComposite Open ESB, Slide Copyright 2007, Callista Enterprise AB «action» getNewOrExistingAddressEntity start «view» editAddressEntry «action» save «subflow» enterNewCategory «action» assignNewCategory exit «flow» «flow» «flow» ok «flow» cancel «flow» «flow» cancel add category
  • 30. Anatomy of a web use-case component (web composite) The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Presentation Use-case logic Back-end integration Input / output parameters Context for use-case component instance state Facelets: Category.xhtml «webcomp» :Category
  • 31. Facelets– Sample – Category Composite None-intrusive to html Supports jar packaging (loading of views from class-path) Made for JSF (unlike JSP) The web framework dream team , Slide Copyright 2008, Callista Enterprise AB <h:commandLink action=“viewAddressEntryAction” ..>
  • 32. Anatomy of a web use-case component (web composite) The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Presentation Use-case logic Back-end integration Input / output parameters Context for use-case component instance state Java: CategoryFlowSupport.java Façade per use-case component. Additional model beans when required «webcomp» :Category
  • 33. Use-case façade The web framework dream team , Slide Copyright 2008, Callista Enterprise AB
  • 34. But what about JSF? Just for bootstrapping Spring Webflow Generic faces-config in web-app No footprint in web composites The web framework dream team , Slide Copyright 2008, Callista Enterprise AB <?xml version=&quot;1.0&quot;?> <!DOCTYPE faces-config PUBLIC &quot;-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN&quot; &quot;http://java.sun.com/dtd/web-facesconfig_1_0.dtd&quot;> <faces-config> <application> <navigation-handler> org.springframework.webflow.executor.jsf.FlowNavigationHandler </navigation-handler> <variable-resolver> org.springframework.webflow.executor.jsf.DelegatingFlowVariableResolver </variable-resolver> <view-handler>com.sun.facelets.FaceletViewHandler</view-handler> </application> <lifecycle> <phase-listener> org.springframework.webflow.executor.jsf.FlowPhaseListener </phase-listener> </lifecycle> </faces-config>JSF
  • 35. Environments Development Apache Tomcat with Apache Pluto Eclipse 3.3 (Europa) with WTP Deployment WebSphere Application Server 6.1 WebSphere Portal Server 6.0 Build system Maven 2 – manages the component architecture Generates Eclipse dependencies and project files Web Framework Dream Team, Slide Copyright 2008, Callista Enterprise AB
  • 36. Lessons learned Webflow Revolution for html centric web applications The foundation for use-case componentization WebFlow validation framework tied into SpringMVC On the agenda for next version… Facelets Momentum depends on Seam Servlet required for loading web resources (images etc) from jar files (web composites) Intuitive Portability Native JSF implementations are not fully portable. We ended up bundling MyFaces rather than deploying to WebSphere JSF implementation (Sun RI) The web framework dream team , Slide Copyright 2008, Callista Enterprise AB
  • 37. Summary Re-usable Use-case Components Delivered! The web framework dream team , Slide Copyright 2008, Callista Enterprise AB Usecase Process Service Data Service Business Value … by the dream team: Spring WebFlow, Facelets, JSF, a reference architecture and some glue
  • 38. Time (?) for Questions! The web framework dream team , Slide Copyright 2008, Callista Enterprise AB