2 Replies Latest reply on Aug 5, 2008 5:28 AM by julien1

    persistent setRenderParameters

    anton.evangelatov

      Hello,
      When I call response.setRenderParameter() in processAction, they are not cleared on the next request, even though in the javadoc it is said "These parameters will be accessible in all sub-sequent render calls via the PortletRequest.getParameter call until a request is targeted to the portlet."

      Is this the normal behaviour and I haven't correctly understood the javadoc, or it is a bug?

      If it is the normal behaviour, how can I clear them?

      I am using this method to pass parameters from processAction to doView, but I want to do it only once, meaning that I want the parameters to be cleared at the end of doView for example.

      Currently I am using the PortletSession to do that and I clear the attribute manually, but I don't think this is the right solution.

      Thank you very much in advance!

        • 1. Re: persistent setRenderParameters

          what is meant by request is a action or render URL.

          if the URL target the page of the portlet or another portlet on the same page, then the render parameters remain unchanged.

          "anton.evangelatov" wrote:
          Hello,
          When I call response.setRenderParameter() in processAction, they are not cleared on the next request, even though in the javadoc it is said "These parameters will be accessible in all sub-sequent render calls via the PortletRequest.getParameter call until a request is targeted to the portlet."

          Is this the normal behaviour and I haven't correctly understood the javadoc, or it is a bug?

          If it is the normal behaviour, how can I clear them?

          I am using this method to pass parameters from processAction to doView, but I want to do it only once, meaning that I want the parameters to be cleared at the end of doView for example.

          Currently I am using the PortletSession to do that and I clear the attribute manually, but I don't think this is the right solution.

          Thank you very much in advance!


          • 2. Re: persistent setRenderParameters

            Portlet session indeed is what you can use.

            With Portlet 2.0 you can are request attributes which are preserved by the portlet container on the next render only but it is also using the session underlyingly.

            "anton.evangelatov" wrote:
            Hello,
            When I call response.setRenderParameter() in processAction, they are not cleared on the next request, even though in the javadoc it is said "These parameters will be accessible in all sub-sequent render calls via the PortletRequest.getParameter call until a request is targeted to the portlet."

            Is this the normal behaviour and I haven't correctly understood the javadoc, or it is a bug?

            If it is the normal behaviour, how can I clear them?

            I am using this method to pass parameters from processAction to doView, but I want to do it only once, meaning that I want the parameters to be cleared at the end of doView for example.

            Currently I am using the PortletSession to do that and I clear the attribute manually, but I don't think this is the right solution.

            Thank you very much in advance!