Skip to content

Comments

Retention policy workflow#51

Merged
rugeli merged 5 commits intomainfrom
feature/retention-policy
Aug 7, 2025
Merged

Retention policy workflow#51
rugeli merged 5 commits intomainfrom
feature/retention-policy

Conversation

@rugeli
Copy link
Contributor

@rugeli rugeli commented Jul 30, 2025

Problem

What is the problem this work solves, including
closes #41

Solution

What I/we did to solve this problem

  • add retention policy configs, like retention periods, and collection names
  • add github action workflow to remove old docs daily
  • add cleanup script to be called by the cleanup workflow

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)

Steps to Verify:

  • manually run bun run scripts/cleanup.ts and then verify the documents in staging database
Screenshot 2025-08-04 at 2 58 53 PM

@github-actions
Copy link

github-actions bot commented Jul 30, 2025

PR Preview Action v1.6.2
Preview removed because the pull request was closed.
2025-08-07 23:24 UTC

@rugeli rugeli changed the base branch from main to feature/routing July 30, 2025 22:03
@rugeli rugeli requested a review from ascibisz August 4, 2025 21:19
RECIPES_EDITED: 24 * 60 * 60 * 1000, // 24 hours
JOB_STATUS: 24 * 60 * 60 * 1000, // 24 hours
},

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I removed batch deletion related configs for now, as they feel overkill for our current doc size, for 1-100 docs, Promise.all() handles deletion faster, plus we run cleanup daily so batching isn't necessary at the moment.

@rugeli rugeli changed the base branch from feature/routing to main August 4, 2025 21:57
@rugeli rugeli force-pushed the feature/retention-policy branch from b5d1c69 to 9835e1e Compare August 7, 2025 17:50
@rugeli rugeli merged commit 0e96bc0 into main Aug 7, 2025
1 check passed
@rugeli rugeli deleted the feature/retention-policy branch August 7, 2025 23:23
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.

Implement Retention Policy for Edited Recipes

2 participants