Skip to content

feat: remove persons with cronjob when retention period has exceeded#409

Merged
nikomakela merged 1 commit into
mainfrom
PT-1932-cronjob-delete-persons
Jun 5, 2025
Merged

feat: remove persons with cronjob when retention period has exceeded#409
nikomakela merged 1 commit into
mainfrom
PT-1932-cronjob-delete-persons

Conversation

@nikomakela

Copy link
Copy Markdown
Contributor

PT-1932.

The delete_retention_period_exceeding_contact_info cronjob has deleted contact info from PalvelutarjotinEvent when the retention period (48h) has exceeded, but the persons have been deleted manually from the enrollee personal data admin view. Since it's been a manual task, it has always needed some one to take care of it. There is no reason why that job could not be done automatically with a cronjob.

The delete_retention_period_exceeding_contact_info cronjob is now extended with that feature, but there are also new flags that can be used to run only 1 of the tasks (with the management command that the cronjob executes) and tehre is also a flag to make a dry drun, that does not acutally delete anything, but just reports how many instances it would delete if it would be ran.

@terovirtanen

Copy link
Copy Markdown
Contributor

KULTUS-API branch is deployed to platta: https://kultus-pr409.api.dev.hel.ninja 🚀🚀🚀

@nikomakela nikomakela marked this pull request as ready for review June 5, 2025 06:17
@nikomakela nikomakela requested a review from karisal-anders June 5, 2025 06:17
@nikomakela nikomakela force-pushed the PT-1932-cronjob-delete-persons branch from e249963 to d1dd17d Compare June 5, 2025 06:58
@terovirtanen

Copy link
Copy Markdown
Contributor

KULTUS-API branch is deployed to platta: https://kultus-pr409.api.dev.hel.ninja 🚀🚀🚀

@nikomakela nikomakela force-pushed the PT-1932-cronjob-delete-persons branch from d1dd17d to 499ed73 Compare June 5, 2025 08:30
@terovirtanen

Copy link
Copy Markdown
Contributor

KULTUS-API branch is deployed to platta: https://kultus-pr409.api.dev.hel.ninja 🚀🚀🚀

PT-1932.

The `delete_retention_period_exceeding_contact_info` cronjob has deleted
contact info from PalvelutarjotinEvent when the retention period (48h)
has exceeded, but the persons have been deleted manually from the
enrollee personal data admin view. Since it's been a manual task, it has
always needed some one to take care of it. There is no reason why that
job could not be done automatically with a cronjob.

The `delete_retention_period_exceeding_contact_info` cronjob is now
extended with that feature, but there are also new flags that can be
used to run only 1 of the tasks (with the management  command that the
cronjob executes) and tehre is also a flag to make a dry drun, that does
not acutally delete anything, but just reports how many instances it
would delete if it would be ran.
@nikomakela nikomakela force-pushed the PT-1932-cronjob-delete-persons branch from 499ed73 to 03ba0ab Compare June 5, 2025 09:02
@sonarqubecloud

sonarqubecloud Bot commented Jun 5, 2025

Copy link
Copy Markdown

@terovirtanen

Copy link
Copy Markdown
Contributor

KULTUS-API branch is deployed to platta: https://kultus-pr409.api.dev.hel.ninja 🚀🚀🚀

@nikomakela nikomakela merged commit d211e7f into main Jun 5, 2025
22 checks passed
@nikomakela nikomakela deleted the PT-1932-cronjob-delete-persons branch June 5, 2025 12:58
@nikomakela nikomakela requested a review from jakezu June 5, 2025 12:58
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