Skip to content

Fix: clean up old space image - #480

Merged
kobergj merged 3 commits into
owncloud:mainfrom
max65482:fix/delete_old_space_images
Jan 7, 2026
Merged

kobergj merged 3 commits into
owncloud:mainfrom
max65482:fix/delete_old_space_images

Conversation

@max65482

Copy link
Copy Markdown

Currently, old space images are not cleaned up and take up storage space. They are a "memory leak". With this PR, the previous space image is deleted upon setting a new one.

Fixes owncloud/ocis#11821

@max65482 max65482 mentioned this pull request Dec 24, 2025
2 of 9 tasks

@kobergj kobergj left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

@max65482 very good idea. I like the approach. Just one small comment.

And could I also ask you to add a changelog to this PR? We need to keep track of changes for the next release. See for example this old PR: https://github.com/owncloud/reva/pull/443/changes#diff-1428f49bdd09346722ee0d07b93800829abdc5f8c142cf0b7bf2fd62bb8bf0e9

@max65482

max65482 commented Jan 5, 2026

Copy link
Copy Markdown
Author

Ok, implemented your suggestion and added changelog.

@kobergj kobergj left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I love it ❤️ Thank you for your contribution!

@kobergj
kobergj merged commit 44bf3e3 into owncloud:main Jan 7, 2026
dragonchaser pushed a commit to opencloud-eu/reva that referenced this pull request Nov 11, 2026
Setting a new space image left the previous image file in the space, so
every image change wasted storage. We now remember the old image id and
delete it after the new one was successfully set. A failed delete is
ignored, the update itself already succeeded.

backport of owncloud#480

Assisted-by: Claude Code:claude-opus-5-5
Signed-off-by: Jörn Friedrich Dreyer <[email protected]>
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.

Space images are kept forever

2 participants