architecting jsf based web applications for the real world...
TRANSCRIPT
![Page 1: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/1.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 1
Building JSF ApplicationsArchitecting JSF Based Web Applications for the Real World
Bill DudneyObject Systems [email protected]
![Page 2: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/2.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 2
AgendaJSF Overview
Patterns & Architecture of JSFJSF Request/Response LifecycleComponents
Separation of ConcernsJSF User InterfaceServicesConnecting
![Page 3: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/3.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 3
What Is JSF?Standard Web Application Framework
Defines the Programming ModelReusable ComponentsBuilds HTML from ComponentsValidation & ConversionComponent Tree
![Page 4: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/4.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 4
Goals of JSFEase/Simplify DevelopmentSupport from/by toolsEvents easily tied to server side codeEase of extensionManage UI state
![Page 5: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/5.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 5
AgendaJSF Overview
Patterns & Architecture of JSFJSF Request/Response LifecycleComponents
Separation of ConcernsJSF User InterfaceServicesConnecting
![Page 6: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/6.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 6
Patterns & Architecture of JSFModel-View-ControllerComposite Component TreeServer Side Events
![Page 7: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/7.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 7
Standard MVCMajor Benefits
Separation of ConcernsLoose coupling
Won’t work on the webBrowsers don’t listen to server eventsWhat objects would observe models?
So what to do to get the benifits?
![Page 8: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/8.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 8
Enter JSF Web MVC
![Page 9: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/9.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 9
JSF Provides Web MVCController
FacesServletLifeCycleApplicationNavaigationHandlerActionListenerConversion and Validation
![Page 10: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/10.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 10
JSF Provides Web MVCView
RenderKitRenderers
ModelJavaBeansEJB’s
Extension PointsView & Controller are extensible
![Page 11: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/11.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 11
Typical Implementation
![Page 12: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/12.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 12
Composite Component TreeClient view is simple
Whole tree looks like one
ImplementationSimplified
![Page 13: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/13.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 13
Server Side EventsEvents are cued & consumed server side
Typically from user actions (button clicks, etc.)
Possible to add programatically
Observer Pattern
![Page 14: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/14.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 14
AgendaJSF Overview
Patterns & Architecture of JSFJSF Request/Response LifecycleComponents
Separation of ConcernsJSF User InterfaceServicesConnecting
![Page 15: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/15.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 15
JSF Request/Response LifecycleRestore ViewApply Request ValuesProcess ValidationsUpdate Model ValuesInvoke ApplicationRender Response
![Page 16: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/16.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 16
AgendaJSF Overview
Patterns & Architecture of JSFJSF Request/Response LifecycleComponents
Separation of ConcernsJSF User InterfaceServicesConnecting
![Page 17: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/17.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 17
UIComponentHub of the frameworkTypically Delegate
RenderingValidatingConverting
![Page 18: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/18.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 18
AgendaJSF Overview
Patterns & Architecture of JSFJSF Request/Response LifecycleComponents
Separation of ConcernsJSF User InterfaceServicesConnecting
![Page 19: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/19.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 19
Running Example
![Page 20: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/20.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 20
UIComponent Instances
![Page 21: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/21.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 21
Implementation
![Page 22: Architecting JSF Based Web Applications for the Real World ...softwaresummit.com/2004/speakers/DudneyJSFApplications.pdf · Bill Dudney — Building JSF Applications Page 13 Server](https://reader031.vdocuments.site/reader031/viewer/2022011800/5ad967a77f8b9aee348b615f/html5/thumbnails/22.jpg)
Colorado Software Summit: October 24 – 29, 2004 © Copyright 2004, Object Systems Group
Bill Dudney — Building JSF Applications Page 22
To the Code!