Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Purge unsubmitted journey sessions #2951

Merged
merged 1 commit into from
Jul 2, 2024

Conversation

rjlynch
Copy link
Contributor

@rjlynch rjlynch commented Jul 1, 2024

Now we only create a claim once the claimant has completed the journey
we need to update the purge job to work on journey sessions rather than
claims as all claims are submitted claims.

old_submitted_claim = create(:claim, :submitted, updated_at: over_24_hours_ago)
Journeys::JOURNEYS.each do |journey|
submitted_journeys << journey::Session.create!(
journey: journey::ROUTING_NAME,
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 think we might want to consider switching from storing the journey on the journey session like this to proper STI. (Not sure if it's worth the effort as I don't expect us to do much querying on the journey session table)

@rjlynch rjlynch requested review from slorek and kenfodder July 1, 2024 10:54
@rjlynch rjlynch force-pushed the CAPT-1750/purge-unsubmitted-journey-sessions branch from d6327ee to f1d6821 Compare July 2, 2024 09:22
Now we only create a claim once the claimant has completed the journey
we need to update the purge job to work on journey sessions rather than
claims as all claims are submitted claims.
@rjlynch rjlynch force-pushed the CAPT-1750/purge-unsubmitted-journey-sessions branch from f1d6821 to f39ab4e Compare July 2, 2024 09:29
@rjlynch rjlynch merged commit 4f53a8c into master Jul 2, 2024
16 checks passed
@rjlynch rjlynch deleted the CAPT-1750/purge-unsubmitted-journey-sessions branch July 2, 2024 09:34
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