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

Internal Server Error when AssetTagName exception occurs

Details

    Description

      Internal Server Error (500) is thrown when tags are incorrectly informed within the request body.

      Steps to reproduce:

      1. Add a new tag "tag1".
      2. Add from the UI a new basic web content selecting "tag1" within its metadata.
      3. Get, using the headless api, the recently created web content. For example: http://localhost:8080/o/headless-delivery/v1.0/structured-contents/41513
      4. Add (post), using the headless api, a new webcontent using the obtained (and relevant) data from 3. Change the tag name:
        1. To an empty string "" (body_data.txt attached).
        2. To an invalid title "tag&" (body_data2.txt attached).

      Expected result: a 400 error (bad request) is obtained in both cases.

      Current result: a 500 error (internal server error) is thrown. In the second case, the error title is too ambiguous:
       

      {     
          "status""INTERNAL_SERVER_ERROR",     "title""Tag name cannot be an empty string" 
      }

       

      {     
          "status""INTERNAL_SERVER_ERROR",     "title""& ' @ \\ ] } : , = > / < \n [ { % | + # ` ? \" \r ; / * ~" 
      }

       
       

      Attachments

        1. body_data.txt
          1.0 kB
          Cristina Rodriguez
        2. body_data2.txt
          1.0 kB
          Cristina Rodriguez

        Activity

          People

            team-headless Product Team Headless
            cristina.rodriguez Cristina Rodriguez
            Kiyoshi Lee Kiyoshi Lee
            Jürgen Kappler Jürgen Kappler
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              2 years, 21 weeks ago

              Packages

                Version Package
                7.1.10 DXP FP21
                7.1.X
                7.2.10 DXP FP11
                7.2.10.4 DXP SP4
                7.2.X
                7.3.10 DXP FP1
                7.3.10.1 DXP SP1
                7.3.6 CE GA7
                7.3.X
                7.4.13 DXP GA1
                Master