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

Liferay starts Data Migration eventhough incorrect settings to S3 are detected


    • Type: Bug
    • Status: Closed
    • Resolution: Inactive
    • Affects Version/s: 6.1.1 CE GA2
    • Fix Version/s: None
    • Labels:
    • Environment:
      Liferay 6.1.1 CE GA2 bundled with Tomcat 7.0.27, CentOS 2.6.32-358.6.2.el6.x86_64


      Data Migration from local storage to S3Store is started eventhough there is incorrect or missing setup for Amazon S3 in Liferay. Once migration completes, Liferay needs restart to get documents library back to operations.

      Steps to reproduce
      1) Set up clean Liferay portal (default file repository) and upload document to Documents Library. Verify that document is accessible.
      2) Don't setup or set incorrect login credentials to S3Store in portal-ext.properties.
      3) Launch Data migration to S3Store in Server / Server administration
      4) Watch logs/catalina.out:
      If S3 aren't set
      07:33:59,621 ERROR [liferay/convert_process-1][S3Store:63] S3 access and secret keys are not set
      If S3 has incorrect settings
      07:47:48,393 ERROR [liferay/convert_process-1][S3Store:63] S3 Error Message.
      5) Data migration is started although Liferay has detected the bad settings.

      • There are NullPointerExceptions thrown for com.liferay.portlet.documentlibrary.store.S3Store.addFile.
        6) Access originally uploaded document from Documents library.
        7) Once Data Migration is completed, it's not possible to use originally uploaded documents. At this point system throws NullPointerException.
        13:39:59,607 ERROR [http-bio-8080-exec-8][DLPreviewableProcessor:740] java.lang.NullPointerException
        at com.liferay.portlet.documentlibrary.store.S3Store.hasFile(S3Store.java:274)

      Seems that system remembers that S3 should be used after migration, eventhugh settings to S3 are not provided.
      User must restart whole Liferay in order to use default file repository again.

      First, it might be good to start migration process only when correct setup to S3 is provided.
      Second, if Data Migration fails, Liferay should not require restart in order for documents repository to be accessible.
      Third, NullPointerExceptions should be handled. (Will be reported as separate bugs).




            michael.saechang Michael Saechang
            jan.profiq Jan Hájovský (Inactive)
            Participants of an Issue:
            Recent user:
            Esther Sanz
            0 Vote for this issue
            2 Start watching this issue


              Days since last comment:
              8 years, 2 weeks ago


                Version Package