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

After upgrade from 6.0 publishing to live can result in NoSuchTemplateException

    Details

    • Fix Priority:
      3

      Description

      Steps to reproduce:
      1) Open a clean 6.0 portal and enable staging (any type).
      2) Change the default portal language form English (en_US) to e.g. French
      3) Create an arbitrary structure (with a belonging template) and a web content based on it. Do not publish to live.
      4) Observe that the sturcture in the database ('journalstructure' table)is unlocalized, the 'name' and the 'description' fields are stored as plaintext.
      5) Shut down the portal and upgrade to Master.
      6) Make sure the portal default language is still set to French.
      7) Attempt to publish the article to live.

      Expected Result: Publish to Live successfully.
      Actual Result: Error showed in the console

      06:22:59,881 ERROR [liferay/background_task-1][BackgroundTaskMessageListener:164] Unable to execute background task
      com.liferay.exportimport.kernel.lar.PortletDataException: com.liferay.dynamic.data.mapping.exception.NoSuchTemplateException: No DDMTemplate exists with the template key 10307 in the ancestor groups
      	at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.exportStagedModel(BaseStagedModelDataHandler.java:141)
      	at com.liferay.exportimport.lar.BaseStagedModelDataHandler.exportStagedModel(BaseStagedModelDataHandler.java:76)
      	at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.exportStagedModel(StagedModelDataHandlerUtil.java:153)
      	at com.liferay.journal.service.base.JournalArticleLocalServiceBaseImpl$3.performAction(JournalArticleLocalServiceBaseImpl.java:408)
      	at com.liferay.journal.service.base.JournalArticleLocalServiceBaseImpl$3.performAction(JournalArticleLocalServiceBaseImpl.java:404)
      	at com.liferay.portal.kernel.dao.orm.DefaultActionableDynamicQuery.performAction(DefaultActionableDynamicQuery.java:396)
      	at com.liferay.portal.kernel.dao.orm.DefaultActionableDynamicQuery$1.call(DefaultActionableDynamicQuery.java:305)
      	at com.liferay.portal.kernel.dao.orm.DefaultActionableDynamicQuery$1.call(DefaultActionableDynamicQuery.java:269)
      	at com.liferay.portal.kernel.dao.orm.DefaultActionableDynamicQuery.doPerformActions(DefaultActionableDynamicQuery.java:325)
      	at com.liferay.portal.kernel.dao.orm.DefaultActionableDynamicQuery.performActions(DefaultActionableDynamicQuery.java:85)
      	at com.liferay.journal.lar.JournalPortletDataHandler.doExportData(JournalPortletDataHandler.java:235)
      	at com.liferay.exportimport.kernel.lar.BasePortletDataHandler.exportData(BasePortletDataHandler.java:139)
      	at com.liferay.exportimport.controller.PortletExportController.exportPortletData(PortletExportController.java:254)
      	at com.liferay.exportimport.controller.PortletExportController.exportPortlet(PortletExportController.java:718)
      	at com.liferay.exportimport.controller.LayoutExportController.doExport(LayoutExportController.java:527)
      	at com.liferay.exportimport.controller.LayoutExportController.export(LayoutExportController.java:152)
      	at com.liferay.portlet.exportimport.service.impl.ExportImportLocalServiceImpl.exportLayoutsAsFile(ExportImportLocalServiceImpl.java:62)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:497)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:153)
      	at com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:85)
      	at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:58)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.RetryAdvice.invoke(RetryAdvice.java:46)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.service.ServiceContextAdvice.invoke(ServiceContextAdvice.java:40)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.java:173)
      	at com.sun.proxy.$Proxy157.exportLayoutsAsFile(Unknown Source)
      	at com.liferay.exportimport.kernel.service.ExportImportLocalServiceUtil.exportLayoutsAsFile(ExportImportLocalServiceUtil.java:80)
      	at com.liferay.exportimport.background.task.LayoutStagingBackgroundTaskExecutor.execute(LayoutStagingBackgroundTaskExecutor.java:131)
      	at com.liferay.portal.kernel.backgroundtask.SerialBackgroundTaskExecutor.execute(SerialBackgroundTaskExecutor.java:54)
      	at com.liferay.portal.kernel.backgroundtask.DelegatingBackgroundTaskExecutor.execute(DelegatingBackgroundTaskExecutor.java:43)
      	at com.liferay.portal.kernel.backgroundtask.ThreadLocalAwareBackgroundTaskExecutor.execute(ThreadLocalAwareBackgroundTaskExecutor.java:56)
      	at com.liferay.portal.background.task.internal.messaging.BackgroundTaskMessageListener.doReceive(BackgroundTaskMessageListener.java:124)
      	at com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java:26)
      	at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener.java:74)
      	at com.liferay.portal.kernel.messaging.ParallelDestination$1.run(ParallelDestination.java:52)
      	at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExecutor.java:756)
      	at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor.java:667)
      	at java.lang.Thread.run(Thread.java:745)
      Caused by: com.liferay.dynamic.data.mapping.exception.NoSuchTemplateException: No DDMTemplate exists with the template key 10307 in the ancestor groups
      	at com.liferay.dynamic.data.mapping.service.impl.DDMTemplateLocalServiceImpl.getTemplate(DDMTemplateLocalServiceImpl.java:647)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:497)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:153)
      	at com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:85)
      	at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:58)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.RetryAdvice.invoke(RetryAdvice.java:46)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.service.ServiceContextAdvice.invoke(ServiceContextAdvice.java:40)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
      	at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      	at com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.java:173)
      	at com.sun.proxy.$Proxy385.getTemplate(Unknown Source)
      	at com.liferay.journal.lar.JournalArticleStagedModelDataHandler.doExportStagedModel(JournalArticleStagedModelDataHandler.java:283)
      	at com.liferay.journal.lar.JournalArticleStagedModelDataHandler.doExportStagedModel(JournalArticleStagedModelDataHandler.java:78)
      	at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.exportStagedModel(BaseStagedModelDataHandler.java:105)
      	... 60 more
      

      Upgrade From: 6.0.12 EE SP2.
      Tomcat 8.0.32 + MySQL 5.6. Portal master GIT ID:16370f7af07f2a41a91f751ed24c82c5f06651be.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                support-lep@liferay.com SE Support
                Reporter:
                joyce.wang Joyce Wang
                Participants of an Issue:
                Recent user:
                Mária Kispál (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  4 years, 7 weeks, 6 days ago

                  Packages

                  Version Package