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

NPE is thrown when upgrades from 7.3.10.1 to master

    Details

      Description

      Steps to reproduce:

      1. Add a site template named as Site Template Name.
      2. Add a new site based on Site Template Name named as Site Name
      3. Navigate to the site template page.
      4. Add an AP widget to home page
      5. Stop portal(Or you can import the attached 7.3.10.1 database dump into MySQL instead of Step1-5)
      6. Upgrade to Master

      Actual result:
      NPE is thrown during upgrade process:

       [java] 2022-04-21 01:32:09.675 ERROR [liferay/background_task-2][LoggerExportImportLifecycleListener:399] Staged model {class: com.liferay.layout.set.model.adapter.StagedLayoutSet, groupId: 37168, uuid: false} import failed
           [java] java.lang.NullPointerException: null
           [java] 	at com.liferay.layout.internal.exportimport.data.handler.StagedLayoutSetStagedModelDataHandler._updateLayoutSetSettingsProperties(StagedLayoutSetStagedModelDataHandler.java:916) ~[?:?]
           [java] 	at com.liferay.layout.internal.exportimport.data.handler.StagedLayoutSetStagedModelDataHandler.doImportStagedModel(StagedLayoutSetStagedModelDataHandler.java:245) ~[?:?]
           [java] 	at com.liferay.layout.internal.exportimport.data.handler.StagedLayoutSetStagedModelDataHandler.doImportStagedModel(StagedLayoutSetStagedModelDataHandler.java:93) ~[?:?]
           [java] 	at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:367) ~[portal-kernel.jar:?]
           [java] 	at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:389) ~[portal-kernel.jar:?]
           [java] 	at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:375) ~[portal-kernel.jar:?]
           [java] 	at com.liferay.site.internal.exportimport.data.handler.StagedGroupStagedModelDataHandler.doImportStagedModel(StagedGroupStagedModelDataHandler.java:295) ~[?:?]
           [java] 	at com.liferay.site.internal.exportimport.data.handler.StagedGroupStagedModelDataHandler.doImportStagedModel(StagedGroupStagedModelDataHandler.java:78) ~[?:?]
           [java] 	at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:367) ~[portal-kernel.jar:?]
           [java] 	at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:389) ~[portal-kernel.jar:?]
           [java] 	at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:375) ~[portal-kernel.jar:?]
           [java] 	at com.liferay.exportimport.internal.controller.LayoutImportController._importFile(LayoutImportController.java:948) ~[?:?]
           [java] 	at com.liferay.exportimport.internal.controller.LayoutImportController.importFile(LayoutImportController.java:220) ~[?:?]
           [java] 	at com.liferay.portlet.exportimport.service.impl.ExportImportLocalServiceImpl.importLayouts(ExportImportLocalServiceImpl.java:189) ~[portal-impl.jar:?]
           [java] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_121]
           [java] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_121]
           [java] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_121]
           [java] 	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_121]
           [java] 	at com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:50) ~[portal-impl.jar:?]
           [java] 	at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:69) ~[portal-impl.jar:?]
           [java] 	at com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:57) ~[portal-impl.jar:?]
           [java] 	at com.liferay.change.tracking.internal.aop.CTTransactionAdvice.invoke(CTTransactionAdvice.java:80) ~[?:?]
           [java] 	at com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:57) ~[portal-impl.jar:?]
           [java] 	at com.liferay.portal.spring.aop.AopInvocationHandler.invoke(AopInvocationHandler.java:49) ~[portal-impl.jar:?]
           [java] 	at com.sun.proxy.$Proxy227.importLayouts(Unknown Source) ~[?:?]
           [java] 	at com.liferay.exportimport.kernel.service.ExportImportLocalServiceUtil.importLayouts(ExportImportLocalServiceUtil.java:107) ~[portal-kernel.jar:?]
           [java] 	at com.liferay.exportimport.internal.background.task.LayoutSetPrototypeImportBackgroundTaskExecutor$LayoutImportCallable.call(LayoutSetPrototypeImportBackgroundTaskExecutor.java:164) ~[?:?]
           [java] 	at com.liferay.exportimport.internal.background.task.LayoutSetPrototypeImportBackgroundTaskExecutor$LayoutImportCallable.call(LayoutSetPrototypeImportBackgroundTaskExecutor.java:147) ~[?:?]
           [java] 	at com.liferay.portal.spring.transaction.BaseTransactionExecutor.execute(BaseTransactionExecutor.java:37) [portal-impl.jar:?]
           [java] 	at com.liferay.portal.spring.transaction.TransactionInvokerImpl.invoke(TransactionInvokerImpl.java:39) [portal-impl.jar:?]
           [java] 	at com.liferay.portal.kernel.transaction.TransactionInvokerUtil.invoke(TransactionInvokerUtil.java:28) [portal-kernel.jar:?]
           [java] 	at com.liferay.exportimport.internal.background.task.LayoutSetPrototypeImportBackgroundTaskExecutor.execute(LayoutSetPrototypeImportBackgroundTaskExecutor.java:95) [bundleFile:?]
           [java] 	at com.liferay.portal.background.task.internal.SerialBackgroundTaskExecutor.execute(SerialBackgroundTaskExecutor.java:63) [bundleFile:?]
           [java] 	at com.liferay.portal.kernel.backgroundtask.DelegatingBackgroundTaskExecutor.execute(DelegatingBackgroundTaskExecutor.java:41) [portal-kernel.jar:?]
           [java] 	at com.liferay.portal.background.task.internal.ThreadLocalAwareBackgroundTaskExecutor.execute(ThreadLocalAwareBackgroundTaskExecutor.java:72) [bundleFile:?]
           [java] 	at com.liferay.portal.background.task.internal.messaging.BackgroundTaskMessageListener.doReceive(BackgroundTaskMessageListener.java:136) [bundleFile:?]
           [java] 	at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java:31) [portal-kernel.jar:?]
           [java] 	at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener.java:74) [portal-kernel.jar:?]
           [java] 	at com.liferay.portal.messaging.internal.ParallelDestination$1.run(ParallelDestination.java:56) [bundleFile:?]
           [java] 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_121]
           [java] 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_121]
           [java] 	at java.lang.Thread.run(Thread.java:745) [?:1.8.0_121]
      

      Effected test case
      LocalFile.StagingUpgrade#TemplatePropagationShouldWorkAfterUpgrade73101

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              gabor.lovas Gábor Lovas
              Reporter:
              joyce.wang Joyce Wang
              Participants of an Issue:
              Recent user:
              Felipe Lins
              Engineering Assignee:
              Eudaldo Alonso
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Days since last comment:
                14 weeks, 6 days ago

                  Packages

                  Version Package
                  7.4.3.23 CE GA23
                  Master