Details

      Description

      Reproduction Steps:

      1. Create a blank site named as Site Name.
      2. Create a page Site Page.
      3. Create a child page for Site Page, called Site Child Page.
      4. Create a child page for Site Child Page, called Site Child Child Page.
      5. Create a Web Content structure which has a link to a page element.
      6. Create a Template for this structure.
      7. Create a Journal Article: Web Content Title A, its link-to-layout field points to Site Child Page.
      8. Create a Journal Article: Web Content Title B, its link-to-layout field points to Site Child Child Page.
      9. Put a Web Content Display portlet to Site Page and set Web Content to Web Content Title B.
      10. Export the whole site Site Name.
      11. Create a new site and try to import the lar.

      Expected result: Import is successful

      Actual result: Import fails with PortletDataException:

      2021-06-07 08:09:20.120 ERROR [liferay/background_task-7][BackgroundTaskMessageListener:182] Unable to execute background task
      com.liferay.exportimport.kernel.lar.PortletDataException: No Layout exists with the key {groupId=39913, privateLayout=false, layoutId=1}
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:408) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:381) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:367) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.doImportReferenceStagedModel(StagedModelDataHandlerUtil.java:454) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importReferenceStagedModel(StagedModelDataHandlerUtil.java:244) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.internal.portlet.preferences.processor.capability.ReferencedStagedModelImporterCapability.process(ReferencedStagedModelImporterCapability.java:119) ~[?:?]
              at com.liferay.exportimport.internal.controller.PortletImportControllerImpl.importPortletPreferences(PortletImportControllerImpl.java:599) ~[?:?]
              at com.liferay.layout.admin.web.internal.exportimport.data.handler.LayoutStagedModelDataHandler.importLayoutPortlets(LayoutStagedModelDataHandler.java:1747) ~[?:?]
              at com.liferay.layout.admin.web.internal.exportimport.data.handler.LayoutStagedModelDataHandler.doImportStagedModel(LayoutStagedModelDataHandler.java:971) ~[?:?]
              at com.liferay.layout.admin.web.internal.exportimport.data.handler.LayoutStagedModelDataHandler.doImportStagedModel(LayoutStagedModelDataHandler.java:152) ~[?:?]
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:367) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:381) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:367) ~[portal-kernel.jar:?]
              at com.liferay.layout.admin.web.internal.exportimport.data.handler.LayoutStagedModelDataHandler.doImportStagedModel(LayoutStagedModelDataHandler.java:822) ~[?:?]
              at com.liferay.layout.admin.web.internal.exportimport.data.handler.LayoutStagedModelDataHandler.doImportStagedModel(LayoutStagedModelDataHandler.java:152) ~[?:?]
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:367) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:381) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:367) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.doImportReferenceStagedModel(StagedModelDataHandlerUtil.java:438) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importReferenceStagedModel(StagedModelDataHandlerUtil.java:296) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importReferenceStagedModels(BaseStagedModelDataHandler.java:863) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:365) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:381) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:367) ~[portal-kernel.jar:?]
              at com.liferay.journal.internal.exportimport.data.handler.JournalPortletDataHandler.doImportData(JournalPortletDataHandler.java:394) ~[?:?]
              at com.liferay.exportimport.kernel.lar.BasePortletDataHandler.importData(BasePortletDataHandler.java:390) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.internal.controller.PortletImportControllerImpl.importPortletData(PortletImportControllerImpl.java:419) ~[?:?]
              at com.liferay.exportimport.internal.controller.PortletImportControllerImpl.importPortletData(PortletImportControllerImpl.java:348) ~[?:?]
              at com.liferay.site.internal.exportimport.data.handler.StagedGroupStagedModelDataHandler.importSitePortlets(StagedGroupStagedModelDataHandler.java:599) ~[?:?]
              at com.liferay.site.internal.exportimport.data.handler.StagedGroupStagedModelDataHandler.doImportStagedModel(StagedGroupStagedModelDataHandler.java:327) ~[?:?]
              at com.liferay.site.internal.exportimport.data.handler.StagedGroupStagedModelDataHandler.doImportStagedModel(StagedGroupStagedModelDataHandler.java:78) ~[?:?]
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:367) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:381) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:367) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.internal.controller.LayoutImportController.doImportFile(LayoutImportController.java:592) ~[?:?]
              at com.liferay.exportimport.internal.controller.LayoutImportController.importFile(LayoutImportController.java:221) ~[?:?]
              at com.liferay.portlet.exportimport.service.impl.ExportImportLocalServiceImpl.importLayouts(ExportImportLocalServiceImpl.java:189) ~[portal-impl.jar:?]
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_91]
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_91]
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_91]
              at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_91]
              at com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:50) ~[portal-impl.jar:?]
              at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:69) ~[portal-impl.jar:?]
              at com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:57) ~[portal-impl.jar:?]
              at com.liferay.change.tracking.internal.aop.CTTransactionAdvice.invoke(CTTransactionAdvice.java:80) ~[?:?]
              at com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:57) ~[portal-impl.jar:?]
              at com.liferay.portal.spring.aop.AopInvocationHandler.invoke(AopInvocationHandler.java:49) ~[portal-impl.jar:?]
              at com.sun.proxy.$Proxy165.importLayouts(Unknown Source) ~[?:?]
              at com.liferay.exportimport.kernel.service.ExportImportLocalServiceUtil.importLayouts(ExportImportLocalServiceUtil.java:107) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.internal.background.task.LayoutImportBackgroundTaskExecutor$LayoutImportCallable.call(LayoutImportBackgroundTaskExecutor.java:133) ~[?:?]
              at com.liferay.exportimport.internal.background.task.LayoutImportBackgroundTaskExecutor$LayoutImportCallable.call(LayoutImportBackgroundTaskExecutor.java:119) ~[?:?]
              at com.liferay.portal.spring.transaction.BaseTransactionExecutor.execute(BaseTransactionExecutor.java:37) ~[portal-impl.jar:?]
              at com.liferay.portal.spring.transaction.TransactionInvokerImpl.invoke(TransactionInvokerImpl.java:39) ~[portal-impl.jar:?]
              at com.liferay.portal.kernel.transaction.TransactionInvokerUtil.invoke(TransactionInvokerUtil.java:28) ~[portal-kernel.jar:?]
              at com.liferay.exportimport.internal.background.task.LayoutImportBackgroundTaskExecutor.execute(LayoutImportBackgroundTaskExecutor.java:85) ~[?:?]
              at com.liferay.portal.background.task.internal.SerialBackgroundTaskExecutor.execute(SerialBackgroundTaskExecutor.java:63) ~[bundleFile:?]
              at com.liferay.portal.kernel.backgroundtask.DelegatingBackgroundTaskExecutor.execute(DelegatingBackgroundTaskExecutor.java:41) ~[portal-kernel.jar:?]
              at com.liferay.portal.background.task.internal.ThreadLocalAwareBackgroundTaskExecutor.execute(ThreadLocalAwareBackgroundTaskExecutor.java:72) ~[bundleFile:?]
              at com.liferay.portal.background.task.internal.messaging.BackgroundTaskMessageListener.doReceive(BackgroundTaskMessageListener.java:136) [bundleFile:?]
              at com.liferay.portal.kernel.messaging.BaseMessageListener.doReceive(BaseMessageListener.java:48) [portal-kernel.jar:?]
              at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java:34) [portal-kernel.jar:?]
              at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener.java:74) [portal-kernel.jar:?]
              at com.liferay.portal.messaging.internal.ParallelDestination$1.run(ParallelDestination.java:56) [bundleFile:?]
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_91]
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_91]
              at java.lang.Thread.run(Thread.java:745) [?:1.8.0_91]
      Caused by: com.liferay.portal.kernel.exception.NoSuchLayoutException: No Layout exists with the key {groupId=39913, privateLayout=false, layoutId=1}
              at com.liferay.portal.service.persistence.impl.LayoutPersistenceImpl.findByG_P_L(LayoutPersistenceImpl.java:8849) ~[portal-impl.jar:?]
              at com.liferay.portal.service.impl.LayoutLocalServiceImpl.getLayout(LayoutLocalServiceImpl.java:1277) ~[portal-impl.jar:?]
              at sun.reflect.GeneratedMethodAccessor668.invoke(Unknown Source) ~[?:?]
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_91]
              at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_91]
              at com.liferay.portal.service.impl.LayoutLocalServiceStagingAdvice$LayoutLocalServiceStagingInvocationHandler._invoke(LayoutLocalServiceStagingAdvice.java:830) ~[portal-impl.jar:?]
              at com.liferay.portal.service.impl.LayoutLocalServiceStagingAdvice$LayoutLocalServiceStagingInvocationHandler.invoke(LayoutLocalServiceStagingAdvice.java:681) ~[portal-impl.jar:?]
              at com.sun.proxy.$Proxy162.getLayout(Unknown Source) ~[?:?]
              at sun.reflect.GeneratedMethodAccessor668.invoke(Unknown Source) ~[?:?]
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_91]
              at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_91]
              at com.liferay.portal.kernel.bean.ClassLoaderBeanHandler.invoke(ClassLoaderBeanHandler.java:66) ~[portal-kernel.jar:?]
              at com.sun.proxy.$Proxy787.getLayout(Unknown Source) ~[?:?]
              at com.liferay.portal.kernel.service.LayoutLocalServiceWrapper.getLayout(LayoutLocalServiceWrapper.java:832) ~[portal-kernel.jar:?]
              at sun.reflect.GeneratedMethodAccessor668.invoke(Unknown Source) ~[?:?]
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_91]
              at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_91]
              at com.liferay.portal.kernel.bean.ClassLoaderBeanHandler.invoke(ClassLoaderBeanHandler.java:66) ~[portal-kernel.jar:?]
              at com.sun.proxy.$Proxy789.getLayout(Unknown Source) ~[?:?]
              at sun.reflect.GeneratedMethodAccessor668.invoke(Unknown Source) ~[?:?]
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_91]
              at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_91]
              at com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:50) ~[portal-impl.jar:?]
              at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:69) ~[portal-impl.jar:?]
              at com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:57) ~[portal-impl.jar:?]
              at com.liferay.portal.spring.aop.AopInvocationHandler.invoke(AopInvocationHandler.java:49) ~[portal-impl.jar:?]
              at com.sun.proxy.$Proxy162.getLayout(Unknown Source) ~[?:?]
              at com.liferay.portal.kernel.service.LayoutLocalServiceUtil.getLayout(LayoutLocalServiceUtil.java:787) ~[portal-kernel.jar:?]
              at com.liferay.portal.model.impl.LayoutImpl.getAncestors(LayoutImpl.java:288) ~[portal-impl.jar:?]
              at com.liferay.dynamic.data.mapping.internal.exportimport.content.processor.DDMFormValuesExportImportContentProcessor$LayoutImportDDMFormFieldValueTransformer._getLayoutBreadcrumb(DDMFormValuesExportImportContentProcessor.java:758) ~[?:?]
              at com.liferay.dynamic.data.mapping.internal.exportimport.content.processor.DDMFormValuesExportImportContentProcessor$LayoutImportDDMFormFieldValueTransformer.toJSON(DDMFormValuesExportImportContentProcessor.java:745) ~[?:?]
              at com.liferay.dynamic.data.mapping.internal.exportimport.content.processor.DDMFormValuesExportImportContentProcessor$LayoutImportDDMFormFieldValueTransformer.transform(DDMFormValuesExportImportContentProcessor.java:684) ~[?:?]
              at com.liferay.dynamic.data.mapping.util.DDMFormValuesTransformer.performTransformation(DDMFormValuesTransformer.java:58) ~[?:?]
              at com.liferay.dynamic.data.mapping.util.DDMFormValuesTransformer.traverse(DDMFormValuesTransformer.java:78) ~[?:?]
              at com.liferay.dynamic.data.mapping.util.DDMFormValuesTransformer.transform(DDMFormValuesTransformer.java:47) ~[?:?]
              at com.liferay.dynamic.data.mapping.internal.exportimport.content.processor.DDMFormValuesExportImportContentProcessor.replaceImportContentReferences(DDMFormValuesExportImportContentProcessor.java:122) ~[?:?]
              at com.liferay.dynamic.data.mapping.internal.exportimport.content.processor.DDMFormValuesExportImportContentProcessor.replaceImportContentReferences(DDMFormValuesExportImportContentProcessor.java:69) ~[?:?]
              at com.liferay.journal.internal.exportimport.content.processor.JournalArticleExportImportContentProcessor.replaceImportContentReferences(JournalArticleExportImportContentProcessor.java:198) ~[?:?]
              at com.liferay.journal.internal.exportimport.content.processor.JournalArticleExportImportContentProcessor.replaceImportContentReferences(JournalArticleExportImportContentProcessor.java:78) ~[?:?]
              at com.liferay.adaptive.media.journal.web.internal.exportimport.content.processor.AMJournalArticleExportImportContentProcessor.replaceImportContentReferences(AMJournalArticleExportImportContentProcessor.java:79) ~[?:?]
              at com.liferay.adaptive.media.journal.web.internal.exportimport.content.processor.AMJournalArticleExportImportContentProcessor.replaceImportContentReferences(AMJournalArticleExportImportContentProcessor.java:35) ~[?:?]
              at com.liferay.journal.internal.exportimport.data.handler.JournalArticleStagedModelDataHandler.doImportStagedModel(JournalArticleStagedModelDataHandler.java:659) ~[?:?]
              at com.liferay.journal.internal.exportimport.data.handler.JournalArticleStagedModelDataHandler.doImportStagedModel(JournalArticleStagedModelDataHandler.java:124) ~[?:?]
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:367) ~[portal-kernel.jar:?]
              ... 65 more
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              joyce.wang Joyce Wang
              Reporter:
              joyce.wang Joyce Wang
              Participants of an Issue:
              Recent user:
              Sophia Zhang
              Engineering Assignee:
              Vendel Töreki
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

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

                  Packages

                  Version Package
                  7.4.1 CE GA2 DXP 7,4
                  Master