Table Of ContentICEfaces 1.8
Next Generation Enterprise Web Development
Build Web 2.0 Applications using Ajax Push, JSF,
Facelets, Spring, and JPA
Rainer Eschen
BIRMINGHAM - MUMBAI
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
ICEfaces 1.8
Next Generation Enterprise Web Development
Copyright © 2009 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval
system, or transmitted in any form or by any means, without the prior written
permission of the publisher, except in the case of brief quotations embedded in
critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of
the information presented. However, the information contained in this book is sold
without warranty, either express or implied. Neither the author, Packt Publishing,
nor its dealers or distributors will be held liable for any damages caused or alleged to
be caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all the
companies and products mentioned in this book by the appropriate use of capitals.
However, Packt Publishing cannot guarantee the accuracy of this information.
First published: November 2009
Production Reference: 1261009
Published by Packt Publishing Ltd.
32 Lincoln Road
Olton
Birmingham, B27 6PA, UK.
ISBN 978-1-847197-24-5
www.packtpub.com
Cover Image by Filippo Sarti ([email protected])
Download at WoweBook.Com
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
Credits
Author Editorial Team Leader
Rainer Eschen Abhijeet Deobhakta
Reviewers Project Team Leader
Dhrubojyoti Kayal Priya Mukherji
Ted Goddard
Project Coordinator
Zainab Bagasrawala
Acquisition Editor
Sarah Cullington
Proofreader
Sandra Hopper
Development Editor
Darshana Shinde
Production Coordinator
Adline Swetha Jesuthas
Technical Editor
Tarun Singh
Cover Work
Adline Swetha Jesuthas
Copy Editor
Sneha Kulkarni
Indexer
Hemangini Bari
Download at WoweBook.Com
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
About the Author
Rainer Eschen has a degree in computer science. He looks back on more than 20
years of programming experience. Since 1994, he works as an IT professional with a
focus on consulting and architecture. He has also been part of "the source" for three
years, working as Sun Sales Support Engineer and Sun Java Center Architect at Sun
Microsystems, Germany.
Today, he is focused on architectures using the Spring framework in conjunction
with the Java Persistence API (JPA). ICEfaces is a central part of the web
development for several years now. Meanwhile, the development of the Facelets
components takes up a lot of space.
Besides ICEfaces, the use of Flex has become increasingly important to him. After a
successful integration of ICEfaces, Flex, and Spring using Spring BlazeDS,
he currently designs pure Flex and AIR clients with Spring backends. His design
allows the ICEfaces and Flex/AIR clients to use the same Spring backend.
User experience and software ergonomics are constant companions in all his
decisions. If possible, he uses multimedia technologies to improve the user
experience of web applications. For this, he had a deeper look at semiprofessional
audio, video, and 3D production concepts over the last years. According to him,
the most promising are humanoid avatars with lip-sync animations using
computer-generated voices. They are a cheap but efficient tool for an optimal
user acceptance.
Download at WoweBook.Com
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
Acknowledgments
First of all, a big thank you to my wife Silvia Regina, my son Lucas Eric, and my
daughter Lisa Estelle. A lot of evenings and weekends were blocked for writing this
book. Many thanks for the support, understanding, and love. I love you all.
This book exists because I won the ICEfaces Technical Blog Award in October 2008.
I got a nice T-shirt and my first Apple gear, an iPod Touch, from ICEsoft. Thanks to
Tracy Gulka for the hard work to get it right before Christmas.
In November 2008, my editor—Sarah Cullington—asked me to "develop a book that
shows readers how to create and deploy rich Internet applications with ICEFaces." I
never thought about writing a book on ICEfaces. Although ICEfaces got momentum
in 2008, a useful introduction was still missing. Actually, it was a good opportunity
to gain more experience in writing and to have my first book on the market. So, I
took the chance of writing the first ICEfaces book. Sarah was a great help to get all
this done. A special thanks to the rest of the Packt Publishing team that helped me
realize this book. You did a great job. I am pretty happy with the result. It was a
pleasure to work with you on this book.
Actually, this book is a documentation of a full-blown ICEfaces web application
example, which I have named ICEcube. So, for two-thirds of my scheduled time,
I was a developer. It was a very tough schedule because the result had to be
something really useful for the Enterprise AJAX developer. Micha Kiener, Head
of Research & Innovation, mimacom, and Ted Goddard, Senior Software Architect,
ICEsoft, put in ideas that helped to get things running. Thanks for your time
(despite the heavy project load).
I also want to thank Wilbur Turner, VP of Sales and Customer Support, ICEsoft, as
well as Robert Lepack, VP of Marketing and Product Management, ICEsoft, and also
David Krebs, CTO, mimacom, for the open communication and their willingness to
support the book.
Download at WoweBook.Com
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
Last but not least, I thank the ICEfaces community for its support over the past few
years. Although I was not a very active forum member, I hope the book can give
something back. Special thanks to all the members who made suggestions for the
outline. A lot of your suggestions were pretty interesting and worth writing about.
Sadly, this is a beginner's book and the number of pages is limited. I will keep all
this in mind for my future projects.
Download at WoweBook.Com
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
About the Reviewers
Dhrubojyoti Kayal works as an Agile developer architect for Capgemini
Consulting. He has more than eight years of experience designing and developing
Enterprise Java applications and products. He is an open source evangelist and
author of the book Pro Java™ EE Spring Patterns: Best Practices and Design Strategies
Implementing Java EE Patterns with the Spring Framework—Apress (Aug 2008).
Prior to Capgemini, Dhrubojyoti worked with Cognizant Technology Solutions,
Oracle, and TATA Consultancy Services.
Ted Goddard is the Chief Software Architect at ICEsoft Technologies and is
the technical lead for the JavaServer Faces Ajax framework, ICEfaces. Following
a PhD in Mathematics from Emory University, which answered open problems
in complexity theory and infinite colorings for ordered sets, he proceeded with
post-doctoral research in component and web-based collaborative technologies.
He has held positions at Sun Microsystems, AudeSi Technologies, and Wind
River Systems, and currently participates in the Servlet and JavaServer Faces
expert groups.
Download at WoweBook.Com
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
Download at WoweBook.Com
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
Table of Contents
Preface 1
Chapter 1: Next Generation Java Development 7
Past problems 7
State of the art 9
Frontend development 9
Struts 9
JSF 10
AJAX 10
Rich Internet Applications (RIA) 11
ICEfaces features 12
JSF reference implementation support 12
Interoperability 13
Framework integration challenges 13
IDE plugins 15
Application server support 15
Portal server support 16
Components for ergonomic interface design 16
Customer-specific skins 17
Server-initiated client updates 17
Optimized page updates 17
Community 18
Summary 19
Chapter 2: Development Environment 21
Tools 21
Java Development Kit (JDK) 21
Installation 22
Eclipse IDE 23
Customized distributions 23
Pulse download service 24
Download at WoweBook.Com
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
Table of Contents
Yoxos download service 25
The ICEfaces book profile at Yoxos 25
Installation 26
Customization of the ICEfaces book profile 26
Maven 2 build system 26
Installation 27
Jetty web container 27
Use in Maven 2 Environments 28
Installation 28
MySQL Database Management System 28
Installation of Community Server 28
Installation of GUI Tools 32
Additional Eclipse configurations 32
ICEfaces plugin 33
Installation 33
Maven 2 and the JDK 35
Jetty server support 36
The Eclipse web project samples 37
ICEfaces 37
The Run on server configuration 40
ICEfaces and Facelets 40
The JEE development stack 42
AppFuse 43
The edoras framework 43
ICEfusion 43
ICEcube 44
The Spring framework 45
Hibernate 45
Apache Tomahawk 45
JSP Standard Tag Library (JSTL) 46
Summary 46
Chapter 3: User Interface Design 47
Revival of the desktop 47
Software ergonomics 48
Challenges 49
Apply Occam's razor 49
Reduction 49
Oversimplification 50
User interface design principles 50
Suitability for the task 50
Self-descriptiveness 51
Controllability 51
Conformity with user expectations 51
Error tolerance 52
Suitability for individualization 53
[ ii ]
Download at WoweBook.Com
This material is copyright and is licensed for the sole use by andrew mayo on 7th November 2009
2406 W. 16th Street, , Wilmington, , 19806
Description:If you are an enterprise developer who wants to add the latest Web 2.0 features to a JSF project this book is for you. You need a basic knowledge of the Spring Framework configuration through annotations and the usage of JPA annotations. Build Web 2.0 Applications using AJAX Push, JSF, Facelets, Spr