Comparing Java Web Frameworks

Similar documents
Comparing Web Frameworks JSF, Spring MVC, Stripes, Struts 2, Tapestry and Wicket

Improve and Expand JavaServer Faces Technology with JBoss Seam

Web Frameworks MMIS 2 VU SS Denis Helic. March 10, KMI, TU Graz. Denis Helic (KMI, TU Graz) Web Frameworks March 10, / 18

JSF: Introduction, Installation, and Setup

Migrating from Struts 1 to Struts 2

Seam 3. Pete Muir JBoss, a Division of Red Hat

Java Training Center, Noida - Java Expert Program

Java EE 6: Develop Web Applications with JSF

Jakarta Struts: An MVC Framework

A Quick Introduction to Struts

Webservices In Java Tutorial For Beginners Using Netbeans Pdf

(p t y) lt d. 1995/04149/07. Course List 2018

ADVANCED JAVA COURSE CURRICULUM

Using Data Science to deliver Workforce & Labour Market Insights. Gary Gan Co-Founder, JobKred

Tutorial Point Servlets Pdf

An update on the latest strategies for building Ajax applications with JavaServer Faces

THIS IS ONLY SAMPLE RESUME - DO NOT COPY AND PASTE INTO YOUR RESUME. WE ARE NOT RESPONSIBLE Name: xxxxxx

Type of Classes Nested Classes Inner Classes Local and Anonymous Inner Classes

Ajax and JSF: Natural Synergy

Java Advance Frameworks

In this Tutorial we present tips and trick for the development enviroment eclipse and the extension MyEclipse.

Building Rich Applications with Appcelerator

Tooling for Ajax-Based Development. Craig R. McClanahan Senior Staff Engineer Sun Microsystems, Inc.

ECLIPSE TUTORIAL HOW TO WRITE JAVA PROGRAM IN ECLIPSE STEP BY STEP ECLIPSE TUTORIAL FOR BEGINNERS JAVA

JSF 2.0: Insight and Opinion

CORE JAVA. Saying Hello to Java: A primer on Java Programming language

Oracle Fusion Middleware 11g: Build Applications with ADF I

Tapestry. Code less, deliver more. Rayland Jeans

Full Stack Java Developer Course

COURSE DETAILS: CORE AND ADVANCE JAVA Core Java

FILE - JAVA WEB SERVICE TUTORIAL

Oracle Developer Day

PGT T3CHNOLOGY SCOUTING. Google Webtoolkit. JSF done right?

Groovy & Grails Scripting for Modern Web Applications. Rohit Nayak Talentica Software

DVS WEB INFOTECH DEVELOPMENT TRAINING RESEARCH CENTER

Eclipse Java Ejb 3.0 Tutorial For Beginners With Examples Pdf

Oracle Forms and Oracle APEX The Odd Couple

Seeking a Java design and coding position with some technical management responsibilities.

Developing Applications with Java EE 6 on WebLogic Server 12c

Introduction to Web Application Development Using JEE, Frameworks, Web Services and AJAX

Oracle Fusion Middleware 11g: Build Applications with ADF I

Soap Based Web Services In Java Tutorial Eclipse Jboss

Environment: Java, J2EE, JSP, Servlet, Struts, Spring IoC, Hibernate, XML, Maven, JUnit, Eclipse, Oracle, tomcat, perforce.

Specialized - Mastering JEE 7 Web Application Development

/ / JAVA TRAINING

Java Spring Hibernate Interview Questions And Answers For

Java Internationalization: Creating International Applications (Java Series) By Andy Deitsch, David Czarnecki READ ONLINE

E-BOOK JAVA DIAGRAM FRAMEWORK ARCHIVE

Google Web Toolkit (GWT)

JavaServer Faces Programming By Budi Kurniawan READ ONLINE

Tutorial Point On Html5 Pdf

Migrating traditional Java EE applications to mobile

Free Downloads Java Servlet & JSP Cookbook

LTBP INDUSTRIAL TRAINING INSTITUTE

GUJARAT TECHNOLOGICAL UNIVERSITY

Contents. 1. JSF overview. 2. JSF example

JSF 2.0: Insight and Opinion

What s new in Spring Web Flow 2.0

PDF / JAVA EE 7 ESSENTIALS ENTERPRISE DEVELOPER HANDBOOK EBOOK

Spring Web Flow: Enabling High Level, Low Effort Web Conversations

pages Jason Chambers AJUG February 2005

of making things look better with CSS, and you have a much better platform for interface development.

Sun Java Studio Creator. Ken Paulsen Staff Engineer Sun Microsystems, Incorporated (Slides by: Craig R. McClanahan)

com Spring + Spring-MVC + Spring-Boot + Design Pattern + XML + JMS Hibernate + Struts + Web Services = 8000/-

Android Programming: Overview

open source community experience distilled

Extreme Java Productivity Enterprise Applications in Just Minutes

Professional JSP : Using JavaServer Pages, Servlets, EJB, JNDI, JDBC, XML, XSLT, And WML By Karl Avedal, Danny Ayers

Spring Web Flow. Colin Sampaleanu Interface21

CSE 336. Introduction to Programming. for Electronic Commerce. Why You Need CSE336

Sitesbay.com. A Perfect Place for All Tutorials Resources. Java Projects C C++ DS Interview Questions JavaScript

AN ISO 9001:2008 CERTIFIED COMPANY ADVANCED. Java TRAINING.

Getting Started with the Stripes Framework Emerging Technologies for the Enterprise Michael P. Redlich March 27, 2009

Grails, Trails, and Sails: Rails Through a Coffee Filter

JAVA COURSES. Empowering Innovation. DN InfoTech Pvt. Ltd. H-151, Sector 63, Noida, UP

Page 1

JAVA. Duration: 2 Months

Struts: Struts 1.x. Introduction. Enterprise Application

Introducing Struts 2

JAVA For Beginner's Crash Course: Java For Beginners Guide To Program Java, JQuery, & Java Programming (Java For Beginners, Learn Java, JQuery,...

Course Content for Java J2EE

JVA-117A. Spring-MVC Web Applications

Spring Web Flow Reference Guide

JSR-286: Portlet Specification 2.0

Open Source Library Developer & IT Pro

Web Application Development Using Spring, Hibernate and JPA

Etanova Enterprise Solutions

If you wish to make an improved product, you must already be engaged in making an inferior one.

JAVA SYLLABUS FOR 6 MONTHS

Remote Health Service System based on Struts2 and Hibernate

FreeMarker in Spring Web. Marin Kalapać

Groovy & Grails in Depth

JAVA SERVLET PROGRAMMING HELP FOR SERVER SIDE JAVA DEVELOPERS JAVA SERIES

Extreme Java Productivity with Spring Roo and Spring 3.0

Architectural patterns

WebSphere Portal Application Development Best Practices using Rational Application Developer IBM Corporation

LTBP INDUSTRIAL TRAINING INSTITUTE

Writing Servlets and JSPs p. 1 Writing a Servlet p. 1 Writing a JSP p. 7 Compiling a Servlet p. 10 Packaging Servlets and JSPs p.

Overview. Principal Product Manager Oracle JDeveloper & Oracle ADF

Spring Web Services Tutorial With Example In

Transcription:

Comparing Java Web Frameworks JSF, Spring MVC, Stripes, Struts 2, Tapestry and Wicket Matt Raible matt@raibledesigns.com http://raibledesigns.com

Today's Agenda Introductions Pros and Cons Smackdown Conclusion Q and A

Introductions Your experience with webapps? Your experience with Java EE? What do you want to get from this session? Experience with Maven, Tomcat, Hibernate, Spring? Web Framework Experience: Spring MVC, Struts 2, Stripes, JSF, Tapestry, Wicket

Who is Matt Raible? Power user of Java Web Frameworks Author of Spring Live and Pro JSP 2.0 Founder of AppFuse (http://appfuse.org) Member of Java EE 5, JSF 1.2 and Bean Validation Expert Groups Java Blogger since 2002

My Experience

Pros and Cons

JSF Pros: Java EE Standard - lots of demand and jobs Fast and easy to develop with initially Lots of component libraries Cons: Tag soup for JSPs Doesn't play well with REST or Security No single source for implementation

Pros: Cons: Spring MVC Lifecyle for overriding binding, validation, etc. Integrates with many view options seamlessly: JSP/JSTL, Tiles, Velocity, FreeMarker, Excel, PDF Inversion of Control makes it easy to test Configuration intensive - lots of XML Almost too flexible - no common parent Controller No built-in Ajax support

Stripes Pros: No XML - Convention over Configuration Good documentation (easy to learn) Enthusiastic community Cons: Small Community Not as actively developed as other projects Hard-coded URLs in ActionBeans

Pros: Cons: Struts 2 Simple architecture - easy to extend Tag Library is easy to customize with FreeMarker or Velocity Controller-based or page-based navigation Documentation is poorly organized No feedback for missing properties or invalid OGNL expressions Googling results in Struts 1.x documentation

Tapestry Pros: Cons: Very productive once you learn it Templates are HTML - great for designers Lots of innovation between releases Documentation very conceptual, rather than pragmatic Steep learning curve Long release cycles - major upgrades every year

Wicket Pros: Great for Java developers, not web developers Tight binding between pages and views Active community - support from the creators Cons: HTML templates live next to Java code Need to have a good grasp of OO The Wicket Way - everything done in Java

The Smackdown

Evaluation Criteria Ajax Support: Is it built-in and easy to use? Bookmark-ability: Can users bookmark pages and return to them easily? Validation: How easy is it to use and does it support client-side (JavaScript) validation? Testability: How easy is it to test Controllers out of container?

Evaluation Criteria, cont. Post and Redirect: How does the framework handle the duplicate post problem? Internationalization: How is i18n supported and how easy is it to get messages in Controllers? Page Decoration: What sort of page decoration/ composition mechanisms does the framework support? Community and Support: Can you get questions answered quickly (and respectfully)?

Evaluation Criteria, cont. Tools: Is there good tool (particularly IDE) support for the framework? Marketability of Skills: If you learn the framework, will it help you get a job? Job Count: What is the demand for framework skills on dice.com and indeed.com?

Ajax Support Is Ajax support built-in and easy to use? JSF: No Ajax support, use ICEfaces and Ajax4JSF Stripes: No libraries, supports streaming results Struts 2: Dojo built-in, plugins for GWT, JSON Spring MVC: No libraries, use DWR & Spring MVC Extras Tapestry: Dojo built-in in 4.1 Wicket: Dojo and Script.aculo.us (Wicket Stuff)

Bookmarking and URLs JSF does a POST for everything - URLs not even considered Stripes uses conventions, but you can override Struts 2 has namespaces - makes it easy Spring MVC allows full URL control Tapestry still has somewhat ugly URLs Wicket allows pages/urls to be mounted

Validation JSF has ugly default messages, but easiest to configure Spring MVC allows you to use Commons Validator - a mature solution Struts 2 uses OGNL for powerful expressions - client-side only works when specifying rules on Actions Tapestry has very robust validation - good messages without need to customize Stripes and Wicket do validation in Java - no client-side

Testability Spring and Struts 2 allow easy testing with mocks (e.g. EasyMock, jmock, Spring Mocks) Tapestry appears difficult to test because page classes are abstract, Creator class simplifies JSF page classes can be easily tested and actually look a lot like Struts 2 actions Wicket has WicketTester, a powerful solution Stripes has Servlet API Mocks and MockRoundtrip

Post and Redirect The duplicate-post problem, what is it? Easiest way to solve: redirect after POST Is there support for allowing success messages to live through a redirect? Spring MVC allows you to add parameters to a redirect Stripes, Tapestry and Wicket all have "flash" support Struts 2 requires a custom solution JSF requires a custom solution, i18n messages difficult to get in page beans

Internationalization JSTL s <fmt:message> tag makes it easy No standard for getting i18n messages in controller classes Stripes, Spring MVC and JSF use a single ResourceBundle per locale Struts 2, Tapestry and Wicket advocate separate files for each page/action JSF requires resource bundle to be declared on each page Tapestry's <span key="key.name"> is awesome

Page Decoration Tiles Experience: used since it first came out SiteMesh is much easier to setup and use Tiles can be used in Struts 2, Spring and JSF Requires configuration for each page SiteMesh can be used with all frameworks Requires very little maintenance after setup SiteMesh not supported or recommended for use with JSF, Tapestry or Wicket

Tools Spring has Spring IDE - only does XML validation, not a UI/web tool Struts 2 has EclipseWork Tapestry has Spindle - great for coders JSF has many, and they're getting better and better Stripes and Wicket don't have any official tools NetBeans has support for: Struts *, JSF (+Facelets), Tapestry and Wicket (no Stripes or Spring MVC)

Tools Available 15.00 11.25 7.50 12 7 Struts 2 Spring MVC Stripes Wicket JSF Tapestry 3.75 4 3 3 0 May 2007

Marketability of Skills Struts 1 is still in high-demand and widely-used Spring is getting more press, but mostly due to the framework s other features JSF is quickly becoming popular Struts 2 is gaining ground, but very scarce on job boards Tapestry has increased in popularity in last couple years Wicket and Stripes are virtually unknown

Dice Job Count 600 450 574 Struts 2 Spring MVC Stripes JSF Wicket Tapestry 300 150 190 0 52 68 6 May 3, 2006 10

Dice Job Count w/ Struts 3,000 2,250 1,500 2,063 Struts 2 Spring MVC Stripes JSF Wicket Tapestry Struts 1 750 574 0 52 68 6 May 3, 2006 10 190

Job Trends

Job Trends vs. Struts

Job Trends vs. J2EE

Job Trends vs. Java

Employer Search on Monster.com Resumes posted 4/3-5/3/2007 900 720 540 360 896 Struts 2 Spring MVC Stripes Wicket JSF Tapestry 180 0 55 87 16 16 108

Mailing List Traffic Struts Stripes MyFaces Tapestry Wicket 0 500 1,000 1,500 2,000 * Spring MVC is not listed here because they have a forum instead of a mailing list and I couldn t figure out a way to count the number of messages for each month.

Mailing List Traffic GWT Struts Stripes MyFaces Tapestry Wicket 0 750 1,500 2,250 3,000 * Spring MVC is not listed here because they have a forum instead of a mailing list and I couldn t figure out a way to count the number of messages for each month.

Releases in 2007 5.00 3.75 2.50 3 5 Struts 2 Spring MVC Stripes MyFaces Wicket Tapestry 2 2 1.25 1 1 0

Books on Amazon 15.00 11.25 7.50 7 11 Struts 2 Spring MVC Stripes JSF Wicket Tapestry 3.75 3 3 0 May 2007 1

Which would I choose?

What do others think? 30.0 22.5 Struts 2 Struts 1 Spring MVC JSF Tapestry 15.0 7.5 0 AppFuse Usage - March 2007

Resources Download this presentation http://static.raibledesigns.com/repository/presentations Struts - http://struts.apache.org StrutsTestCase: http://strutstestcase.sf.net Spring MVC - http://www.springframework.org Spring IDE: http://www.springide.org Gaijin Studio: http://gaijin-studio.sf.net Struts 2 - http://opensymphony.org/webwork Eclipse Plugin: http://sf.net/projects/eclipsework IDEA Plugin: http://wiki.opensymphony.com/display/ww/ IDEA+Plugin

Resources, cont. Tapestry - http://tapestry.apache.org Spindle: http://spindle.sourceforge.net JSF - http://java.sun.com/j2ee/javaserverfaces and http:// myfaces.apache.org Java Studio Creator: http://sun.com/software/products/ jscreator MyEclipse: http://myeclipseide.com IDEA: http://www.jetbrains.com/idea SiteMesh: http://opensymphony.com/sitemesh

Resources, cont. Testing Frameworks JUnit: http://junit.org EasyMock: http://easymock.org jmock: http://jmock.org jwebunit: http://jwebunit.sourceforge.net Canoo WebTest: http://webtest.canoo.com Tapestry Test Assist: http://howardlewisship.com/blog/ 2004/05/tapestry-test-assist.html AppFuse - http://appfuse.org

Books Starting Struts 2, Ian Roughly (free on InfoQ.com) The Spring Primer, Matt Raible Pro Spring, Rob Harrop and Jan Machacek Spring in Action, Craig Walls and Ryan Breidenbach Professional Java Development with Spring, Rod Johnson, Juergen Hoeller and Team

Books, cont. WebWork in Action, Patrick Lightbody and Team Tapestry 101, Warner Onstine Tapestry in Action, Howard Lewis Ship Core JSF, David Geary and Cay Horstmann JSF in Action, Kito Mann Pro Wicket, Karthik Gurumurthy

Grails Flex Seam GWT Django What s Next? Ruby on Rails OpenLaszlo Trails

Who cares? "If it works, use it!"

Questions? matt@raibledesigns.com http://raibledesigns.com Download presentation from: http://static.raibledesigns.com/repository/presentations