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

Order parameters in discovery document by using an array, not a map

    Details

      Description

      JSONWS API discovery document lists *parameters* as a map. Although parameters are listed in correct order, on the client side (that consumes the discovery document), parameters will be deserialized as a Map, meaning the order of arguments is lost.

      For examples one of the actions is:

      /dlapp/unsubscribe-file-entry-type: 
      {
          method: "POST",
          parameters: 
          {
              groupId: "long",
              fileEntryTypeId: "long"
          },
          path: "/dlapp/unsubscribe-file-entry-type",
          response: "void"
      },
      

      The parameters is JSONObject and not a JSONArray. This is a problem because I'm generating this method:

      public void unsubscribeFileEntryType(long fileEntryTypeId, long groupId);
      

      When the correct parameter order should be:

      public void unsubscribeFileEntryType(long groupId, long fileEntryTypeId);
      

      This LPS replaces parameters map with an array.

        Attachments

          Activity

            People

            • Assignee:
              hugo.huijser Hugo Huijser
              Reporter:
              igor.spasic Igor Spasic (Inactive)
              Participants of an Issue:
              Recent user:
              Esther Sanz
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                7 years, 1 week, 6 days ago

                Packages

                Version Package
                6.2.0 CE B2