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

REST API call to delete touch relation on published page returns HTTP 404 during Page Editing

XMLWordPrintable

    • 1
    • 5
    • We collect Confluence feedback from various sources, and we evaluate what we've collected when planning our product roadmap. To understand how this piece of feedback will be reviewed, see our Implementation of New Features Policy.

      Issue Summary

      In Confluence, there can only be one touch relation per contentId pair (shared draft, published page) and If there is a shared draft available(which exists mostly), the touch relation should be on the shared draft.

      Whenever a page is edited with CE enabled, a DELETE REST API call is made to delete the touch relation for the published version, which doesn't exist in the usercontent_relation table in the database if there's a shared draft available for that page.

      This causes the below DELETE REST API call to delete the touch relation for the published version of the page to return HTTP 404, as the corresponding data doesn't exist.

       

      /rest/experimental/relation/touched/from/user/current/to/content/<contentid>?targetStatus=current

       

      This is reproducible on Data Center: (yes) / (no) Yes

      Steps to Reproduce

      1. Edit a page for which a shared draft exists.
      2. DELETE REST call will be triggered during the page edit and fail with HTTP 404 for deleting the touch relation of the published page from the usercontent_relation database table.

      Expected Results

      A precheck condition can be included to execute the delete REST call for the touch relation of the published version of the page only if the shared draft doesn't exist for that page.

      Actual Results

      DELETE Rest call returns HTTP 404 error and the same can be observed in the confluence_access.yyyy-mm-dd.log file :

      ***.**.*.** admin [26/Feb/2024:15:22:38 +0000] "DELETE /confluence/rest/experimental/relation/touched/from/user/current/to/content/1966082?targetStatus=current HTTP/1.1" 404 214 97 /confluence/rest/experimental/relation/touched/from/user/current/to/content/1966082 http-nio-8090-exec-4 "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36"  

      Workaround

      Currently there is no known workaround for this behavior. A workaround will be added here when available

              Unassigned Unassigned
              33df95c63117 Nitin Rastogi
              Votes:
              12 Vote for this issue
              Watchers:
              8 Start watching this issue

                Created:
                Updated: