> > Please could someone please let me know the life cycle of a > portlet, ie what
I started writing about this in the tutorial a while back, and realized the portlet lifecycle wasn't easily explained due to the nature of the api, and abruptly stopped working on the tutorial as you can see here: http://www.bluesunrise.com/jetspeed-docs/PortletHowTo.htm Since we've formally added portlet instances in 1.4, and better defined the life cycle in 1.4, I'll try again to continue on the tutorial for the Nov.11 release. Quickly: A portlet has its init() method called once. Thats very much like the servlet api. There is no destroy() method however, not sure why that is, but it seems like bad api design not to have it. The life cycle of a portlet can be controlled by JR.p settings: // automatically create all portlets at system startup, alternative is to create on first access autocreate.portlets=false // controls how long portlets stay in memory (for all portlets) in seconds refresh.portlet.default = 3600 Programmatically you can control how long portlets are kept alive by setting the expiration time, see AbstractPortlet Another way to control the instancing of portlets is thru the cache handle which uniquely identifies the portlet in the cache See AbstractInstancePortlet for how to have different instances of a portlet created based on the PSML page and instance id > events/methods get call when a portlet is created shut down etc.. There is no real eventing framework. In a request, actions are called before the getContent phase, 'actions' are not portlet event-based actions, but are Turbine Actions, thus actions are not methods on the portlet interface. -- To unsubscribe, e-mail: <mailto:jetspeed-user-unsubscribe@;jakarta.apache.org> For additional commands, e-mail: <mailto:jetspeed-user-help@;jakarta.apache.org>
