Uploaded image for project: 'Confluence Cloud'
  1. Confluence Cloud
  2. CONFCLOUD-82682

500 Internal Server Error when archiving multiple Confluence pages via /wiki/rest/api/content/archive (DataIntegrityViolationException, batch size)

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Medium Medium
    • Organize - Archive
    • None

      When attempting to archive multiple Confluence pages in a single request using the /wiki/rest/api/content/archive REST API endpoint, the operation intermittently fails with a 500 Internal Server Error. The error is a DataIntegrityViolationException related to a batch execution failure in the database, specifically:
      org.springframework.dao.DataIntegrityViolationException: could not execute batch; SQL [...]; nested exception is org.hibernate.exception.DataException: could not execute batch

      This appears to be similar to CONFCLOUD-68104 (which affected page export), but is occurring for the archive endpoint.

       

      Steps to Reproduce

      1. Prepare a list of 214-246 Confluence page IDs (all requests tested were below the documented 300-page limit).
      1. Make a POST request to /wiki/rest/api/content/archive with the list of page IDs, either via a Forge app using requestConfluence() or directly as an admin user.
      1. Observe that approximately 50% of requests fail with a 500 error, while others succeed.
      1. Retrying the same request with individual page IDs always succeeds.

       

      The API should archive all provided pages or return a 400 Bad Request if the request is invalid (e.g., too many pages).

      No 500 Internal Server Error should occur for valid requests within documented limits.

      Retrying the request with individual page IDs (one page per request) always succeeds.

              Unassigned Unassigned
              91f63e98a1b9 Gabriel Vilhena
              Votes:
              6 Vote for this issue
              Watchers:
              10 Start watching this issue

                Created:
                Updated: