Skip to content

Conversation

vlovini
Copy link
Collaborator

@vlovini vlovini commented Oct 14, 2025

This pull request addresses a bug where attachments were not deleted from AWS due to incorrect entity path resolution. The fix adds support for both .attachments and _attachments suffixes.

Note: this is a temporary fix and I suggest to find another solution instead of hardcoding the children entities by the name,

@vlovini
Copy link
Collaborator Author

vlovini commented Oct 14, 2025

Talking with a colleague, we just noticed that this code may ignore two level cascading - e.g. Delete a Collection of Books that have attachments

@vlovini
Copy link
Collaborator Author

vlovini commented Oct 14, 2025

Additionally observed - if the transaction fails at the last part, the database part will rollback. But the file would be deleted from the S3, since the delete file is called at the after handler.

@KoblerS KoblerS requested review from KoblerS and schiwekM October 16, 2025 13:06
@KoblerS KoblerS added the bug Something isn't working label Oct 16, 2025
@KoblerS
Copy link
Collaborator

KoblerS commented Oct 16, 2025

#268

@KoblerS KoblerS marked this pull request as ready for review October 16, 2025 13:06
@schiwekM
Copy link
Contributor

Tests for outboxing behaviour are missing then it can be merged.

@KoblerS KoblerS requested a review from SirSimon04 October 20, 2025 07:19
@schiwekM schiwekM requested a review from a team as a code owner October 20, 2025 07:24
Co-authored-by: Simon Kobler <[email protected]>
@schiwekM schiwekM merged commit 97b0858 into main Oct 20, 2025
6 of 8 checks passed
@schiwekM schiwekM deleted the fix/delete-attachments-when-delete-parent branch October 20, 2025 11:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants