Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Rob Spoor
  • Devaka Cooray
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
  • Tim Holloway
Bartenders:
  • Jj Roberts
  • Al Hobbs
  • Piet Souris

Q for Hans Bergsten : JSF & Struts integration

 
Ranch Hand
Posts: 146
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hans,

Do you cover how JSF and Struts will integrate with each other in your book? I haven't fully investigate the impact JSF will have on struts, but I'm curious to know how it being viewed by others in the development community. I do know that Craig McClanahan was the lead on the JSF project at Sun so it's probably going to integrate quite nicely. What do you think?

Thanks,
Dave
 
Author
Posts: 106
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Dave Knipp:
Hans,

Do you cover how JSF and Struts will integrate with each other in your book? I haven't fully investigate the impact JSF will have on struts, but I'm curious to know how it being viewed by others in the development community. I do know that Craig McClanahan was the lead on the JSF project at Sun so it's probably going to integrate quite nicely. What do you think?

Thanks,
Dave



I cover the architectual differences between JSF and Struts in detail in the book, which I consider vital background information that you need if you're going to integrate the two or migrate a Struts application to pure JSF.

When I wrote it, the Struts-JSF package wasn't ready, so I only cover it briefly. On the other hand, there's not much needed to use it; change a few class names in the Struts configuration file and use a few new Struts tags in the JSP pages, and Struts takes care of all the dirty work of getting user interface events handled by JSF and backend code invokations handled by Struts Actions.

What I cover in great detail is how to migrate a Struts application to pure JSF; that's what I feel is most important to cover in a JSF book.
 
Ranch Hand
Posts: 83
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi hans.

When I wrote it, the Struts-JSF package wasn't ready, so I only cover it briefly. On the other hand, there's not much needed to use it; change a few class names in the Struts configuration file and use a few new Struts tags in the JSP pages, and Struts takes care of all the dirty work of getting user interface events handled by JSF and backend code invokations handled by Struts Actions.

What I cover in great detail is how to migrate a Struts application to pure JSF; that's what I feel is most important to cover in a JSF book.



then wouldn't it be best to use the best of both worlds ? Use struts as the framework and use jsf for dynamics of gui ?
 
Hans Bergsten
Author
Posts: 106
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by bas duijzings:
hi hans.



then wouldn't it be best to use the best of both worlds ? Use struts as the framework and use jsf for dynamics of gui ?



Well, maybe if you need to take advantage of some Struts-specific features not found in JSF, for instance the more powerful validation feature. But I would rather develop a custom validation mechanism for JSF that uses some of the same ideas instead of using both, because JSF provides most of the same features as Struts but in a different way. If you mix them, you have to learn both and decide which features to use from each framework.

The Struts-JSF integration package is great for existing Struts applications, letting you migrate the application piece by piece or continue to use both. For a new application, it can be an option, but in most cases, a pure JSF application is probably an easier solution.
 
Dave Knipp
Ranch Hand
Posts: 146
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hans,

Great, i'll look forward to taking a look at your book. I agree that the most important aspect of struts' integration with jsf is how to migrate between the two.

Thanks,
Dave
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic