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

JournalArticle model validator does not throw errors to logs when a file is missing

    Details

    • Fix Priority:
      3

      Description

      Description:
      If a file included in a Web Content article is missing, the JournalArticle model validator is not printing the correct information.

      Steps to Reproduce:

      1.  Start with a clean bundle and sign in as the default administrator.
      2. Create a web content article with a featured image uploaded from a local image file. Obtain its resourcePrimKey value from the database (usually the articleId displayed in the UI + 2).
      3. Substitute the value of the resourcePrimKey into the attached Groovy script and run it in Server Administration -> Script.
        Expected Result
        Script prints the filename of the featured image.
        Actual Result
        Script prints the name of some temporary file, e.g. 20200703172226709XNMOJAOB
      4. Create an invalid condition in the document library by deleting the contents of ${liferay_home}/data/document_library. Run the script again.

      Expected Result
      The model validator should catch the exception and the script should print its message text.
      Actual Result
      Portal UI displays a "Your request failed to complete" error popup and a "null" error popup and nothing is printed in the script output console. A "FileNotFoundException" is thrown in the portal log.

        Attachments

          Activity

            People

            • Assignee:
              noor.najjar Noor Najjar
              Reporter:
              noor.najjar Noor Najjar
              Participants of an Issue:
              Recent user:
              Noor Najjar
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

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

                Packages

                Version Package