digitalfabrik / integreat-cms

Simplified content management back end for the Integreat App - a multilingual information platform for newcomers
https://digitalfabrik.github.io/integreat-cms/
Apache License 2.0
56 stars 33 forks source link

Delete useless links #3020

Open david-venhoff opened 3 weeks ago

david-venhoff commented 3 weeks ago

Motivation

Right now we keep links for translations which are outdated or archived in the database. However, there is no reason to do so. We have a lot of link objects in the database, and removing unused links will be a nice performance improvement. If we can rely on only useful links existing, we could also simplify some database queries.

Proposed Solution

Remove all links for content objects which are archived or outdated (There may be more cases where we don't want to have links)

Alternatives

Do nothing

Additional Context

https://chat.tuerantuer.org/digitalfabrik/pl/ykbppm73hi8pim98khpgja6z9h

timobrembeck commented 3 weeks ago

This should be an infra ticket. There links for old versions are not kept in the database on purpose, but they are a side effect of the link check library not being race condition safe. If you find a specific bug, where old links are not deleted as they should, this ticket would be valid, but last time I checked, I did not find such a problem.