Thanks too for help. I'd like another advice while I'm in development.
Should my portlets inherit from AbstractPortletInstance now ? Is it better for performance / stability ? Why is there still two kinds of AbstractPortlet ? I don't really get it... Is it only for backward compatibility ? Aurelien. > -----Message d'origine----- > De : David Sean Taylor [mailto:[EMAIL PROTECTED]] > Envoyé : mercredi 16 octobre 2002 20:31 > À : Jetspeed Users List > Objet : RE: Getting Crazy... > > > I Don't recommend turning off caching except during development. > > There is support to handle how your portlets are cached. Just override > AbstractPortlet's getHandle: > > public static Object getHandle(Object config) > > or better yet, just have your portlet inherit from > AbstractInstancePortlet > instead of AbstractPortlet, which uses the instance id for > the cache handle: > > /** > * Construct the handle used for caching. > * @param config The config object, expected to be a PortletConfig. > */ > public static Object getHandle(Object config) > { > //this implementation expects a PortletConfig object as its > // configuration > PortletConfig pc = null; > > if (!(config instanceof PortletConfig)) > { > return null; > } > > // form the key from the current request's portal page profile > // and the portlet id in the config > pc = (PortletConfig)config; > > StringBuffer handle = new StringBuffer(256); > handle.append(pc.getPageId()); > handle.append('/'); > handle.append(pc.getPortletId()); > > return handle.toString(); > > } // getHandle > > There are two settings for Parameters in the registry for > controlling cache > handles, but to my surprise they are not used in the code: > > <field name="cachedOnName" type="boolean"> > <bind-xml name="cachedOnName" node="attribute"/> > </field> > <field name="cachedOnValue" type="boolean"> > <bind-xml name="cachedOnValue" node="attribute"/> > </field> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>