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

DuplicateFriendlyURLEntryException when importing Blogs data

    Details

      Description

      Steps to reproduce:

      1. Activate Local Staging for Blogs
      2. Add Blogs portlet to page
      3. Add Blogs entry via portlet
      4. Publish to Live
      5. Go to Staging
      6. Edit title of the blog entry
      7. Publish to Live

      Expected result: Publication is successful
      Actual result: Publication fails with the following error:

      An unexpected error occurred with the publication process. Please check your portal and publishing configuration.
      
      The following error in Blogs while importing its data has stopped the process: com.liferay.friendly.url.exception.DuplicateFriendlyURLEntryException
      

      The following console errors also display:

      19:53:37,698 ERROR [liferay/background_task-5][BackgroundTaskMessageListener:165] Unable to execute background task
      com.liferay.exportimport.kernel.lar.PortletDataException: com.liferay.friendly.url.exception.DuplicateFriendlyURLEntryException
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:421)
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:433)
              at com.liferay.blogs.internal.exportimport.data.handler.BlogsEntryStagedModelDataHandler._importFriendlyURLEntries(BlogsEntryStagedModelDataHandler.java:608)
              at com.liferay.blogs.internal.exportimport.data.handler.BlogsEntryStagedModelDataHandler.doImportStagedModel(BlogsEntryStagedModelDataHandler.java:371)
              at com.liferay.blogs.internal.exportimport.data.handler.BlogsEntryStagedModelDataHandler.doImportStagedModel(BlogsEntryStagedModelDataHandler.java:74)
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:370)
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:433)
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:419)
              at com.liferay.blogs.web.internal.exportimport.data.handler.BlogsPortletDataHandler.doImportData(BlogsPortletDataHandler.java:152)
              at com.liferay.exportimport.kernel.lar.BasePortletDataHandler.importData(BasePortletDataHandler.java:378)
              at com.liferay.exportimport.controller.PortletImportController.importPortletData(PortletImportController.java:328)
              at com.liferay.exportimport.controller.PortletImportController.importPortletData(PortletImportController.java:277)
              at com.liferay.site.internal.exportimport.data.handler.StagedGroupStagedModelDataHandler.importSitePortlets(StagedGroupStagedModelDataHandler.java:594)
              at com.liferay.site.internal.exportimport.data.handler.StagedGroupStagedModelDataHandler.doImportStagedModel(StagedGroupStagedModelDataHandler.java:328)
              at com.liferay.site.internal.exportimport.data.handler.StagedGroupStagedModelDataHandler.doImportStagedModel(StagedGroupStagedModelDataHandler.java:87)
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:370)
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:433)
              at com.liferay.exportimport.kernel.lar.StagedModelDataHandlerUtil.importStagedModel(StagedModelDataHandlerUtil.java:419)
              at com.liferay.exportimport.controller.LayoutImportController.doImportFile(LayoutImportController.java:575)
              at com.liferay.exportimport.controller.LayoutImportController.importFile(LayoutImportController.java:217)
              at com.liferay.portlet.exportimport.service.impl.ExportImportLocalServiceImpl.importLayouts(ExportImportLocalServiceImpl.java:185)
              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:163)
              at com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:54)
              at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:58)
              at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:137)
              at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
              at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:137)
              at com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.java:169)
              at com.sun.proxy.$Proxy101.importLayouts(Unknown Source)
              at com.liferay.exportimport.kernel.service.ExportImportLocalServiceUtil.importLayouts(ExportImportLocalServiceUtil.java:202)
              at com.liferay.exportimport.internal.background.task.LayoutStagingBackgroundTaskExecutor$LayoutStagingImportCallable.call(LayoutStagingBackgroundTaskExecutor.java:282)
              at com.liferay.exportimport.internal.background.task.LayoutStagingBackgroundTaskExecutor$LayoutStagingImportCallable.call(LayoutStagingBackgroundTaskExecutor.java:255)
              at com.liferay.portal.spring.transaction.TransactionInvokerImpl$CallableMethodInvocation.proceed(TransactionInvokerImpl.java:101)
              at com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:54)
              at com.liferay.portal.spring.transaction.TransactionInvokerImpl.invoke(TransactionInvokerImpl.java:47)
              at com.liferay.portal.kernel.transaction.TransactionInvokerUtil.invoke(TransactionInvokerUtil.java:28)
              at com.liferay.exportimport.internal.background.task.LayoutStagingBackgroundTaskExecutor.execute(LayoutStagingBackgroundTaskExecutor.java:141)
              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.friendly.url.exception.DuplicateFriendlyURLEntryException
              at com.liferay.friendly.url.service.impl.FriendlyURLEntryLocalServiceImpl.validate(FriendlyURLEntryLocalServiceImpl.java:305)
              at com.liferay.friendly.url.service.impl.FriendlyURLEntryLocalServiceImpl.addFriendlyURLEntry(FriendlyURLEntryLocalServiceImpl.java:61)
              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:163)
              at com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:54)
              at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:58)
              at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:137)
              at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:56)
              at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:137)
              at com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.java:169)
              at com.sun.proxy.$Proxy485.addFriendlyURLEntry(Unknown Source)
              at com.liferay.friendly.url.internal.exportimport.staged.model.repository.FriendlyURLEntryStagedModelRepository.addStagedModel(FriendlyURLEntryStagedModelRepository.java:52)
              at com.liferay.friendly.url.internal.exportimport.staged.model.repository.FriendlyURLEntryStagedModelRepository.addStagedModel(FriendlyURLEntryStagedModelRepository.java:36)
              at com.liferay.friendly.url.internal.exportimport.data.handler.FriendlyURLEntryStagedModelDataHandler.doImportStagedModel(FriendlyURLEntryStagedModelDataHandler.java:122)
              at com.liferay.friendly.url.internal.exportimport.data.handler.FriendlyURLEntryStagedModelDataHandler.doImportStagedModel(FriendlyURLEntryStagedModelDataHandler.java:36)
              at com.liferay.exportimport.kernel.lar.BaseStagedModelDataHandler.importStagedModel(BaseStagedModelDataHandler.java:370)
              ... 50 more
      

      Reproduced on:
      Tomcat 8.0.32 + MySQL 5.6
      Portal master GIT ID: 2f55b89bd3cea6d657df8ccf0d9228c0ad305bf0

        Attachments

          Issue Links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  2 years, 25 weeks, 5 days ago

                  Packages

                  Version Package
                  7.1.X
                  Master