com.liferay.portlet.documentlibrary.NoSuchFileException: {companyId=20202, repositoryId=20229, fileName=1, version=1.0, cause=com.liferay.portlet.documentlibrary.NoSuchContentException: No DLContent exists with the key {companyId=20202, repositoryId=20229, path=1, version=1.0}}

Liferay Issues | Istvan Dezsi | 1 year ago
  1. 0

    *Description:* 1) Obtain 6.2 vanilla, set {{dl.store.impl=com.liferay.portal.store.db.DBStore}} and DB connection to MySql. Start the server 2) Upload 1 document in the DM, then go to Control Panel - Server Administration - Data Migration 3) Perform migration with a fresh PostGreSQL DB as target. During the migration process, observe that when it get's to DLContent, this error is printed {code} 10:52:19,517 ERROR [liferay/convert_process-1][ConvertDatabase:281] java.sql.BatchUpdateException: Batch entry 0 INSERT INTO DLContent (contentId, groupId, companyId, repositoryId, path_, version, data_, size_) VALUES ('20466', '0', '20155', '20182', '1', '1.0', '<stream of 33318 bytes>', '33318') w as aborted. Call getNextException to see the cause. {code} Leave the migration finishing 4) Shut down the portal, update the DB connection properties in the portal-ext.properties file, start up the portal. and login as admin 5) Go to DM and click on the file +Expected+: The file to be displayed and manageable +Actual Behavior+: No preview will be displayed. If trying to update the same file, the exception will be thrown: {code} ERROR [http-bio-8080-exec-13][render_portlet_jsp:132] null com.liferay.portlet.documentlibrary.NoSuchContentException: No DLContent exists with the key {companyId=20155, repositoryId=20182, path=1, version=1.0} at com.liferay.portlet.documentlibrary.service.persistence.DLContentPersistenceImpl.findByC_R_P_V(DLContentPersistenceImpl.java:1888) {code}

    Liferay Issues | 1 year ago | Istvan Dezsi
    com.liferay.portlet.documentlibrary.NoSuchFileException: {companyId=20202, repositoryId=20229, fileName=1, version=1.0, cause=com.liferay.portlet.documentlibrary.NoSuchContentException: No DLContent exists with the key {companyId=20202, repositoryId=20229, path=1, version=1.0}}
  2. 0

    *Description:* 1) Obtain 6.2 vanilla, set {{dl.store.impl=com.liferay.portal.store.db.DBStore}} and DB connection to MySql. Start the server 2) Upload 1 document in the DM, then go to Control Panel - Server Administration - Data Migration 3) Perform migration with a fresh PostGreSQL DB as target. During the migration process, observe that when it get's to DLContent, this error is printed {code} 10:52:19,517 ERROR [liferay/convert_process-1][ConvertDatabase:281] java.sql.BatchUpdateException: Batch entry 0 INSERT INTO DLContent (contentId, groupId, companyId, repositoryId, path_, version, data_, size_) VALUES ('20466', '0', '20155', '20182', '1', '1.0', '<stream of 33318 bytes>', '33318') w as aborted. Call getNextException to see the cause. {code} Leave the migration finishing 4) Shut down the portal, update the DB connection properties in the portal-ext.properties file, start up the portal. and login as admin 5) Go to DM and click on the file +Expected+: The file to be displayed and manageable +Actual Behavior+: No preview will be displayed. If trying to update the same file, the exception will be thrown: {code} ERROR [http-bio-8080-exec-13][render_portlet_jsp:132] null com.liferay.portlet.documentlibrary.NoSuchContentException: No DLContent exists with the key {companyId=20155, repositoryId=20182, path=1, version=1.0} at com.liferay.portlet.documentlibrary.service.persistence.DLContentPersistenceImpl.findByC_R_P_V(DLContentPersistenceImpl.java:1888) {code}

    Liferay Issues | 1 year ago | Istvan Dezsi
    com.liferay.portlet.documentlibrary.NoSuchContentException: No DLContent exists with the key {companyId=20155, repositoryId=20182, path=1, version=1.0}

    Root Cause Analysis

    1. com.liferay.portlet.documentlibrary.NoSuchContentException

      No DLContent exists with the key {companyId=20202, repositoryId=20229, path=1, version=1.0}

      at com.liferay.portlet.documentlibrary.service.persistence.impl.DLContentPersistenceImpl.findByC_R_P_V()
    2. com.liferay.portlet
      DLContentPersistenceImpl.findByC_R_P_V
      1. com.liferay.portlet.documentlibrary.service.persistence.impl.DLContentPersistenceImpl.findByC_R_P_V(DLContentPersistenceImpl.java:1933)
      1 frame
    3. Liferay Portal Impl
      DLContentLocalServiceImpl.getContent
      1. com.liferay.portlet.documentlibrary.service.impl.DLContentLocalServiceImpl.getContent(DLContentLocalServiceImpl.java:147)
      1 frame
    4. Java RT
      Method.invoke
      1. sun.reflect.GeneratedMethodAccessor749.invoke(Unknown Source)
      2. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      3. java.lang.reflect.Method.invoke(Method.java:606)
      3 frames
    5. Liferay Portal Impl
      ServiceBeanAopProxy.invoke
      1. com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:153)
      2. com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:84)
      3. com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:55)
      4. com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      5. com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.java:173)
      5 frames
    6. com.sun.proxy
      $Proxy257.getContent
      1. com.sun.proxy.$Proxy257.getContent(Unknown Source)
      1 frame
    7. com.liferay.portal
      DBStore.getFileAsStream
      1. com.liferay.portal.store.db.DBStore.getFileAsStream(DBStore.java:192)
      1 frame
    8. Java RT
      Method.invoke
      1. sun.reflect.GeneratedMethodAccessor747.invoke(Unknown Source)
      2. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      3. java.lang.reflect.Method.invoke(Method.java:606)
      3 frames
    9. Liferay Portal Impl
      ServiceBeanMethodInvocation.proceed
      1. com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:153)
      1 frame
    10. Liferay Portal Service
      TempFileMethodInterceptor.invoke
      1. com.liferay.portlet.documentlibrary.store.TempFileMethodInterceptor.invoke(TempFileMethodInterceptor.java:35)
      1 frame
    11. Liferay Portal Impl
      MethodInterceptorInvocationHandler.invoke
      1. com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      2. com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:84)
      3. com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:55)
      4. com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      5. com.liferay.portal.spring.aop.MethodInterceptorInvocationHandler.invoke(MethodInterceptorInvocationHandler.java:67)
      5 frames
    12. com.sun.proxy
      $Proxy475.getFileAsStream
      1. com.sun.proxy.$Proxy475.getFileAsStream(Unknown Source)
      1 frame
    13. com.liferay.portal
      DBStoreRegistrator$DelegatorDBStore.getFileAsStream
      1. com.liferay.portal.store.db.DBStoreRegistrator$DelegatorDBStore.getFileAsStream(DBStoreRegistrator.java:194)
      1 frame
    14. Liferay Portal Service
      DLStoreUtil.getFileAsStream
      1. com.liferay.portlet.documentlibrary.store.DLStoreImpl.getFileAsStream(DLStoreImpl.java:301)
      2. com.liferay.portlet.documentlibrary.store.DLStoreUtil.getFileAsStream(DLStoreUtil.java:407)
      2 frames
    15. Liferay Portal Impl
      DLFileEntryLocalServiceImpl.getFileAsStream
      1. com.liferay.portlet.documentlibrary.service.impl.DLFileEntryLocalServiceImpl.getFileAsStream(DLFileEntryLocalServiceImpl.java:1197)
      2. com.liferay.portlet.documentlibrary.service.impl.DLFileEntryLocalServiceImpl.getFileAsStream(DLFileEntryLocalServiceImpl.java:1180)
      2 frames
    16. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      4. java.lang.reflect.Method.invoke(Method.java:606)
      4 frames
    17. Liferay Portal Impl
      ServiceBeanAopProxy.invoke
      1. com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:153)
      2. com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(DefaultTransactionExecutor.java:84)
      3. com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:55)
      4. com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMethodInvocation.java:127)
      5. com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.java:173)
      5 frames
    18. com.sun.proxy
      $Proxy64.getFileAsStream
      1. com.sun.proxy.$Proxy64.getFileAsStream(Unknown Source)
      1 frame
    19. Liferay Portal Service
      DLFileEntryLocalServiceUtil.getFileAsStream
      1. com.liferay.portlet.documentlibrary.service.DLFileEntryLocalServiceUtil.getFileAsStream(DLFileEntryLocalServiceUtil.java:536)
      1 frame
    20. Liferay Portal Impl
      LiferayFileVersion.getContentStream
      1. com.liferay.portlet.documentlibrary.model.impl.DLFileVersionImpl.getContentStream(DLFileVersionImpl.java:60)
      2. com.liferay.portal.repository.liferayrepository.model.LiferayFileVersion.getContentStream(LiferayFileVersion.java:108)
      2 frames
    21. Liferay Portal Service
      ImageProcessorUtil.generateImages
      1. com.liferay.portlet.documentlibrary.util.ImageProcessorImpl._generateImages(ImageProcessorImpl.java:284)
      2. com.liferay.portlet.documentlibrary.util.ImageProcessorImpl.generateImages(ImageProcessorImpl.java:81)
      3. com.liferay.portlet.documentlibrary.util.ImageProcessorUtil.generateImages(ImageProcessorUtil.java:53)
      3 frames
    22. Liferay Portal Impl
      BaseProcessorMessageListener.doReceive
      1. com.liferay.portlet.documentlibrary.messaging.ImageProcessorMessageListener.generate(ImageProcessorMessageListener.java:31)
      2. com.liferay.portlet.documentlibrary.messaging.BaseProcessorMessageListener.doReceive(BaseProcessorMessageListener.java:36)
      2 frames
    23. Liferay Portal Service
      ThreadPoolExecutor$WorkerTask.run
      1. com.liferay.portal.kernel.messaging.BaseMessageListener.receive(BaseMessageListener.java:26)
      2. com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener.java:72)
      3. com.liferay.portal.kernel.messaging.SerialDestination$1.run(SerialDestination.java:58)
      4. com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExecutor.java:756)
      5. com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor.java:667)
      5 frames
    24. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:724)
      1 frame