Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-73282 Implement Portlet 3.0
  3. LPS-81525

Portlet 3.0: Require javax.portlet.version=3.0 opt-in for portlets configured via @Component

    Details

    • Type: Technical Task
    • Status: Closed
    • Priority: Minor
    • Resolution: Completed
    • Affects Version/s: None
    • Fix Version/s: Master
    • Component/s: None
    • Labels:
      None

      Description

      This issue serves as a task for requiring portlets that are configured via the OSGi @Component annotation to specify "javax.portlet.version=3.0" in order to opt-in to Portlet 3.0 runtime functionality. If the property is omitted, then the default will be version 2.0 which will enable existing portlets to run in a backward-compatible manner.

      For example:

      TestPortlet.java
      @Component(
      	immediate = true,
      	property = {
      		"com.liferay.portlet.add-default-resource=true",
      		"com.liferay.portlet.instanceable=true",
      		"com.liferay.portlet.preferences-owned-by-group=true",
      		"com.liferay.portlet.scopeable=true", "javax.portlet.display-name=Test",
      		"javax.portlet.expiration-cache=0",
      		"javax.portlet.name=" + PortletKeys.TEST,
      		"javax.portlet.supports.mime-type=text/html",
      		"javax.portlet.version=3.0"
      	},
      	service = Portlet.class
      )
      public class TestPortlet {
      }
      

      For more information, see: LRDOCS-5208.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                brian.chan Brian Chan
                Reporter:
                neil.griffin Neil Griffin
                Recent user:
                Brian Chan
                Participants of an Issue:
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  1 year, 17 weeks, 2 days ago

                  Packages

                  Version Package
                  Master