Uploaded image for project: 'PUBLIC - Liferay Documentation'
  1. PUBLIC - Liferay Documentation
  2. LRDOCS-8204

Clarify copy-request-parameter default entry in 7.0.x breaking changes

Details

    Description

      The following breaking change documentation for entry  https://github.com/liferay/liferay-portal/blob/7.0.6-ga7/readme/BREAKING_CHANGES.markdown#changed-the-default-value-of-the-copy-request-parameters-init-parameter-for-mvc-portlets is ambiguous. It doesn't give reasons why you would want to keep or override the setting.

      Here are some background notes...

      When the copy-request-parameters init parameter is set to true, all of the MVCPortlet's current action parameters are copied directly as render parameters. It's described here:

      https://help.liferay.com/hc/en-us/articles/360017871332-Passing-Information-from-the-Action-Phase-to-the-Render-Phase

      Since 7.0, the parameter is set to true by default.

      If the developer is using copy-request-parameter in her 6.x MVCPortlet, she can remove her code that sets it true and rely on the default setting. Of course, for informative reasons she can always set it again explicitly (e.g., in a Component property).

      If the developer isn't using the parameter in 6.x, she must override the default setting by setting the parameter false. The best way to do that is using a Component property, like this:

      @Component (
          ...
          properties = {
              "javax.portlet.init-param.copy-request-parameter=false",
              ...
          }
          ...
      )
      

      Attachments

        Issue Links

          Activity

            People

              brian.chan Brian Chan
              james.hinkey James Hinkey (Inactive)
              Jürgen Kappler Jürgen Kappler
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Packages

                  Version Package
                  7.0.x