portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Sean Taylor" <da...@bluesunrise.com>
Subject RE: why do portlets inherit from servlets?
Date Thu, 31 Oct 2002 05:54:30 GMT


> -----Original Message-----
> From: Jason Novotny [mailto:jdnovotny@lbl.gov]
> Sent: Wednesday, October 30, 2002 9:02 PM
> To: Jetspeed Developers List
> Cc: david@bluesunrise.com
> Subject: Re: why do portlets inherit from servlets?
>
>
>
> Hi David,
>
> 	Thanks for the information. In trying to implement
> something similar
> myself, I'm confused as to how to manage the portlet lifecycle if
> portlets are servlets. For instance, the only method a "manger"
> servlet, or portlet container, can access of a portlet is the service
> method thru the RequestDispatcher.include call. How would the
> init(PortletConfig) or initConcrete(PortletSettings), login and other
> methods get called?
> In the other case, where portlets are their own objects and not
> necessarily servlets, then what about the PortletConfig object, which
> seems to get its params from the web.xml? Will that be a part of the
> standard?

Well wouldn't the servlet interface be just one of the interfaces that a
portlet may implement, so the container can make standardized calls such as
init on the Portlet (extended) interface.

IMO, there are too many differences between a portlet and servlet. The
servlet api should be mimicked where needed.
I personally wouldn't extend a Portlet interface from Servlet. A portlet has
a different lifecycle and request phases. Some Servlet API methods would be
not applicable (or stale) on the Portlet api. Portlets render fragments,
servlets the entire page.

David



--
To unsubscribe, e-mail:   <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:jetspeed-dev-help@jakarta.apache.org>


Mime
View raw message