Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Delete permissions for Submission and Publication #81

Merged
merged 1 commit into from
Feb 27, 2024

Conversation

jabrah
Copy link
Contributor

@jabrah jabrah commented Feb 22, 2024

Related: eclipse-pass/main#549

pass-ui PR: eclipse-pass/pass-ui#1256

Question:

Are we OK with having a multi-step process for deleting and cleaning up a draft Submission and related entities? Deleting draft submissions does not produce SubmissionEvents (from the UI) so shouldn't trigger notification services.

To deleted a submission, a client would need to:

  • Remove associated Files, since these Files reference the Submission)
  • Remove the submission
  • I think removing the submission's Publication, would be last, since the submission would hold a reference to it ?
    • only if no other submissions reference the Publication

There are multiple points of failure in this chain, none of which are really recoverable by the client, although chances of errors should be pretty low.

@markpatton
Copy link
Contributor

You will have to remove the Publication first, and then the Files, and then the Submission. Removing the submission or publication will fail if other things point to them, but this should work fine for draft submissions.

Copy link
Contributor

@markpatton markpatton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good.

@jabrah
Copy link
Contributor Author

jabrah commented Feb 26, 2024

Tested locally fine after some UI tweaks to fix some bad rsql queries

@jabrah jabrah merged commit 4cea8f4 into main Feb 27, 2024
2 checks passed
@jabrah jabrah deleted the 549-delete-draft-submissions branch February 27, 2024 15:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants