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

Undeployed portlets cannot be removed from page

    Details

      Description

      Steps to reproduce:
      1. Add a Web Content Display portlet to a page
      2. Undeploy the Web Content Display module (journal/journal-content-web)
      3. Assert that the portlet is now shown with the message "This portlet has been undeployed..."

      Expected Result: The portlet can be removed from the page through the delete option in the portlet header menu.

      Actual Result: The portlet header menu is not shown and there's no way to remove the portlet from the page.

      12:02:35,402 ERROR [http-nio-8080-exec-8][IncludeTag:128] Current URL / generates exception: null
      java.lang.NullPointerException
      	at com.liferay.portal.kernel.model.PortletInstance._getPortletName(PortletInstance.java:198)
      	at com.liferay.portal.kernel.model.PortletInstance.fromPortletInstanceKey(PortletInstance.java:40)
      	at com.liferay.portal.kernel.model.PortletConstants.getRootPortletId(PortletConstants.java:176)
      	at com.liferay.portal.service.impl.PortletLocalServiceImpl.fetchPortletById(PortletLocalServiceImpl.java:406)
      	at com.liferay.portal.service.impl.PortletLocalServiceImpl.getPortletById(PortletLocalServiceImpl.java:524)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:163)
      	at com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.java:169)
      	at com.liferay.portal.kernel.service.PortletLocalServiceUtil.getPortletById(PortletLocalServiceUtil.java:173)
      	at com.liferay.portlet.PortletURLImpl.getPortlet(PortletURLImpl.java:251)
      	at com.liferay.portlet.PortletURLImpl.setPortletMode(PortletURLImpl.java:607)
      	at com.liferay.portlet.PortletResponseImpl.doCreateLiferayPortletURL(PortletResponseImpl.java:708)
      	at com.liferay.portlet.PortletResponseImpl$LiferayPortletURLPrivilegedAction.run(PortletResponseImpl.java:787)
      	at com.liferay.portlet.PortletResponseImpl$LiferayPortletURLPrivilegedAction.run(PortletResponseImpl.java:772)
      	at com.liferay.portal.security.lang.DoPrivilegedUtil$NoPACL.wrap(DoPrivilegedUtil.java:64)
      	at com.liferay.portal.security.lang.DoPrivilegedUtil.wrap(DoPrivilegedUtil.java:26)
      	at com.liferay.portlet.PortletResponseImpl.createLiferayPortletURL(PortletResponseImpl.java:269)
      	at com.liferay.portlet.PortletResponseImpl.createLiferayPortletURL(PortletResponseImpl.java:261)
      	at com.liferay.portlet.PortletResponseImpl.createLiferayPortletURL(PortletResponseImpl.java:283)
      	at com.liferay.portlet.PortletResponseImpl.createRenderURL(PortletResponseImpl.java:293)
      	at com.liferay.portlet.PortletResponseImpl.createRenderURL(PortletResponseImpl.java:288)
      

      Reproduced on:
      Tomcat 8.0.32 + MySQL 5.7.17
      Portal Master Git Hash: a5624351f040e01d7af823edfbda9093e01155e2
      Portal ee-7.0.x Git Hash: 2c7c6ba4cbdcb0cf56332d82ffa9fd38f92064ab

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  2 years, 16 weeks, 4 days ago

                  Packages

                  Version Package
                  7.0.0 DXP FP14
                  7.0.0 DXP SP3
                  7.0.3 CE GA4
                  7.0.X EE
                  7.0.0 DXP FP36
                  7.0.0 DXP SP7
                  7.0.5 CE GA6
                  7.0.X
                  7.1.X
                  Master