Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-101963

Asset renderer JSPs from a portlet web module that opts-in to Portlet 3.0 cannot use the Portlet 3.0 JSP taglib



      Problem Background

      The portlets provided by the asset-publisher-web module utilize Portlet 2.0 API. Because of this, it is not possible for a JSP provided by a portlet web module (either a .jar or .war module) to use the Portlet 3.0 JSP taglib. In order to fix the problem, the following portlets must opt-in to Portlet 3.0 by specifying the "javax.portlet.version=3.0" service property:

      • AssetPublisherPortlet.java
      • HighestRatedAssetsPortlet.java
      • MostViewedAssetsPortlet.java
      • RecentContentPortlet.java
      • RelatedAssetsPortlet.java

      Note that this problem is similar to LPS-87974.

      Steps to Reproduce

      1. Start Liferay Portal 7.2.0 CE GA 1 and copy the attached artifacts $LIFERAY_HOME/osgi/modules:

      • com.liferay.training.gradebook.api.jar
      • com.liferay.training.gradebook.service.jar
      • gradebook.web.jar

      2. Add the "GradebookWeb" portlet to a page

      3. Click on the "Create Asset" button and verify that the list of assets includes a new row:

      My Assignment Title

      4. Add the Asset Publisher to a page

      Expected Results

      The asset publisher should show the following AND there are no errors in the console log:

      My Assignment Title
      Test Test
      Modified x Minutes ago.
      abstract.jsp DESCRIPTION=My Assignment Description

      Actual Results

      The asset publisher does not show abstract.jsp, but rather shows the default content:

      My Assignment Title
      Test Test
      Modified x Minutes ago.
      My Assignment Description

      AND the following stacktrace appears in the console log:

      Caused by: java.lang.UnsupportedOperationException: Requires 3.0 opt-in
      	at com.liferay.portlet.internal.PortletRequestImpl.getRenderParameters(PortletRequestImpl.java:520)
      	at com.liferay.taglib.portlet.DefineObjectsTag3.doStartTag(DefineObjectsTag3.java:91)
      	at org.apache.jsp.asset.abstract_jsp._jspService(abstract_jsp:90)
      	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:111)
      	at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
      	at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:411)
      	... 254 more


          Issue Links



              • Assignee:
                neil.griffin Neil Griffin
                neil.griffin Neil Griffin
                Participants of an Issue:
                Recent user:
                Pavel Savinov
                Engineering Assignee:
                Neil Griffin
              • Votes:
                0 Vote for this issue
                1 Start watching this issue


                • Created:
                  Days since last comment:
                  36 weeks ago


                  Version Package
                  7.2.10 DXP FP2
         DXP SP1