Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-40475

Search REST API fails on casting error "ContentConvertible" related to the Space description

    XMLWordPrintable

Details

    Description

      NOTE: This bug report is for Confluence Server. Using Confluence Cloud? See the corresponding bug report.

      I was able to reproduce on our cloud instance (and some other instance like yours).

      Atlassian Confluence v5.8.17:
      https://confluence.atlassian.com/rest/api/content/search?cql=(space=%22TEAMCAL%22%20AND%20type=%22attachment%22)&limit=50&start=650&expand=container
      Error: The entity spacedesc: Team Calendars for Confluence v.9 (240912700) is not ContentConvertible or API available.

      https://confluence.atlassian.com/rest/api/content/search?cql=(space=%22SMT%22%20AND%20type=%22attachment%22)&limit=50&start=0&expand=container
      Error: The entity spacedesc: Summit 2011 Speaker Guidelines v.7 (173768813) is not ContentConvertible or API available.

      Public Apache Wiki v.5.8.4:
      https://cwiki.apache.org/confluence/rest/api/content/search?cql=(space=%22ACE%22%20AND%20type=%22attachment%22)&limit=50&start=0&expand=container
      Error: The entity spacedesc: Apache ACE v.2 (115845) is not ContentConvertible or API available.

      On our Cloud instance v6.0.0 (coveord.atlassian.net):
      https://coveord.atlassian.net/wiki/rest/api/content/search?cql=(space=%22SC%22%20AND%20type=%22attachment%22)&limit=50&start=0&expand=container
      Error: The entity spacedesc: Sitecore v.1 (5865532) is not ContentConvertible or API available.

      We have two instance on-premise 5.7.1 and 5.8.5 and they don't seem to be affected.

      Workaround

      Workaround from dstuder@tvc.org in the comment. Thank you for this.

      1. The REST call can work if this is added to the CQL
        • type="attachment" AND space="TEST" and container!="{id of the space description container}"
          • We will first have to get the ID of the SPACEDESCRIPTION content from the error message.
      2. The second workaround below will only work if there are no attachment on a page with the title being the Space Key of the Space itself without a file extension.
        • type="attachment" AND space="TEST" and title!="TEST"

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              397df0915fa4 Matthieu Theriault
              Votes:
              8 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated: