Thoughts? - Websphere

This is a discussion on Thoughts? - Websphere ; Hi: I new to Portal Server, so excuse me if my questions do not make sense. I was wondering if Portlet Applications are based of MVC, then why do we even need Struts Portlet Framework? What is the added advantage ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: Thoughts?

  1. Thoughts?

    Hi:

    I new to Portal Server, so excuse me if my questions do not make sense.
    I was wondering if Portlet Applications are based of MVC, then why do we
    even need Struts Portlet Framework? What is the added advantage of
    having Struts (which essentially is a MVC framework) and comboing it
    with Portlets as they are already kinda MVC implementations. To add to
    it, Should we really use tiles. B'coz portal aggregates all the HTMLs
    spitted by a portlets in a Portal Page. And essentially the portlets
    just spit out HTML (or whatever markup) that belongs to a portlet
    window. For most of the webapps there isn't much of reusable UI
    fragments within a Portlet Window, so it it worth adding Tiles to
    already complex gamut of technologies.


    I read best practices for Portal Development. It says if I have two
    portlets accessing same kinda database or backend and are related I
    should have the portlest in same portlet application. Where as I also
    read in red books that each portlet is essentially a MVC based Web App
    in itself and hence should be separate portlet projects.

    Thought???

    Thank you all in advance,
    -RM

  2. Re: Thoughts?

    On Feb 28, 1:06 pm, Ravi Mittal wrote:
    > Hi:
    >
    > I new to Portal Server, so excuse me if my questions do not make sense.
    > I was wondering if Portlet Applications are based of MVC, then why do we
    > even need Struts Portlet Framework? What is the added advantage of
    > having Struts (which essentially is a MVC framework) and comboing it
    > with Portlets as they are already kinda MVC implementations. To add to
    > it, Should we really use tiles. B'coz portal aggregates all the HTMLs
    > spitted by a portlets in a Portal Page. And essentially the portlets
    > just spit out HTML (or whatever markup) that belongs to a portlet
    > window. For most of the webapps there isn't much of reusable UI
    > fragments within a Portlet Window, so it it worth adding Tiles to
    > already complex gamut of technologies.
    >
    > I read best practices for Portal Development. It says if I have two
    > portlets accessing same kinda database or backend and are related I
    > should have the portlest in same portlet application. Where as I also
    > read in red books that each portlet is essentially a MVC based Web App
    > in itself and hence should be separate portlet projects.
    >
    > Thought???
    >
    > Thank you all in advance,
    > -RM




    Portlets are indeed MVC, with the class extending GenericPortlet being
    the controller, the JSP representing the view, and model components
    being used appropriately.

    But, MVC isn't an entire framework. Page navigation, state management
    and input validation are not out of the box from the Portlet API. This
    is why we need Java Server Faces (JSF) and Struts portlets.

    For some free tutorials on creating Struts and JSF portlets, check out
    these links:

    http://studyguides.scja.com/jsr168/i...8strutsportlet

    http://studyguides.scja.com/jsr168/i...r168jsfportlet

    Cheers!

    -Cameron McKenzie

    Author of What is WebSphere? and the SCJA Certification Study Guides
    Free Mock SCJA Exams: http://www.scja.com
    Free WebSphere Tutorials: http://studyguides.scja.com/j2ee/index.jsp
    Free Portlet Development Tutorials: http://studyguides.scja.com/jsr168/index.jsp


+ Reply to Thread