Uploaded image for project: 'Crucible'
  1. Crucible
  2. CRUC-3716

Delete review via REST API

    XMLWordPrintable

Details

    Description

      In REST API, you would need to abandon a review prior to delete it.

      Abandon review e.g http://localhost:8060/rest-service/reviews-v1/CR-5/transition?action=action:abandonReview

      Then delete it with http://localhost:8060/rest-service/reviews-v1/CR-5/transition?action=action:deleteReview, you won't be able to delete it as you are prompted with message "You can't do action:deleteReview in state Dead"

      <?xml version="1.0" encoding="UTF-8" standalone="yes"?><error><code>Runtime</code><message>com.cenqua.crucible.model.AuthorizationException: You can't do action:deleteReview in state Dead</message><stacktrace>java.lang.RuntimeException: com.cenqua.crucible.model.AuthorizationException: You can't do action:deleteReview in state Dead&#xD;
      

      If you run http://localhost:8060/rest-service/reviews-v1/CR-5/transitions, it will listed that the only action allowed is recoverReview.

      Hence, looks like action:deleteReview is never achievable.

      The actual way to delete a review is DELETE http://localhost:8060/rest-service/reviews-v1/CR-5 which has been abandoned earlier.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              tlum Tracey Lum [Atlassian]
              Votes:
              2 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: