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

Update the Cron Schedule for Some VBADocuments Jobs #12417

Merged
merged 0 commits into from
Apr 18, 2023

Conversation

kristen-brown
Copy link
Contributor

@kristen-brown kristen-brown commented Apr 17, 2023

Summary

A handful of VBADocuments job schedules were updated in #12366. At one point, the job scheduler supported a "seconds" column, and it appears it no longer does. The intent of this PR is to reevaluate and update the schedule for a handful of these jobs and possibly solve a bug we're seeing where the SlackNotifier job is no longer reporting results, which began around the same time that #12366 was merged.

Testing done

Checked the validity and intent of the cron syntax in crontab.guru.

Screenshots

None

What areas of the site does it impact?

This PR impacts the schedule of a few VBADocuments jobs.

Acceptance criteria

  • I fixed|updated|added unit tests and integration tests for each feature (if applicable). – N/A
  • No error nor warning in the console.
  • Events are being sent to the appropriate logging solution – N/A
  • Documentation has been updated (link to documentation) – N/A
  • No sensitive information (i.e. PII/credentials/internal URLs/etc.) is captured in logging, hardcoded, or specs
  • Feature/bug has a monitor built into Datadog or Grafana (if applicable) – N/A
  • If app impacted requires authentication, did you login to a local build and verify all authenticated routes work as expected – N/A
  • I added a screenshot of the developed feature – N/A

Requested Feedback

I did my best to pick a schedule that seemed logical to me for these jobs that needed to be updated. If you have other ideas for the schedule, feel free to suggest.

@kristen-brown kristen-brown added Lighthouse lighthouse banana-peels Lighthouse Banana Peels Team labels Apr 17, 2023
@kristen-brown kristen-brown requested review from a team as code owners April 17, 2023 16:21
@@ -267,17 +267,17 @@ VBADocuments::FlipperStatusAlert:
description: "Checks status of Flipper features expected to be enabled and alerts to Slack if any are not enabled"

VBADocuments::ReportMonthlySubmissions:
cron: "3 2 1 * * America/New_York"
cron: "0 2 1 * * America/New_York"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Didn't think the 3 needed to be there, so I updated it to be 2:00 AM ET on the first of the month.


VBADocuments::ReportUnsuccessfulSubmissions:
cron: "0 0 * * MON-FRI America/New_York"
class: VBADocuments::ReportUnsuccessfulSubmissions
description: "Daily report of unsuccessful benefits intake submissions"

VBADocuments::SlackNotifier:
cron: "0 0 * * * America/New_York"
cron: "0 2,9,16 * * MON-FRI America/New_York"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is the same schedule as our new VBADocuments::FlipperStatusAlert job.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is also the job we stopped receiving Slack notifications for on 4/10. We'll have to see if this change to the schedule helps.

@@ -287,12 +287,12 @@ VBADocuments::RunUnsuccessfulSubmissions:
description: "Run VBADocuments::UploadProcessor for submissions that are stuck in uploaded status"

VBADocuments::UploadRemover:
cron: "15,45 * * * * America/New_York"
cron: "*/2 * * * * America/New_York"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

At one point, this was actually running every 30 seconds, so I've updated it to be every 2 minutes, which seemed slightly more reasonable while still being timely in removing documents from S3.

class: VBADocuments::UploadRemover
description: "Clean up submitted documents from S3"

VBADocuments::UploadScanner:
cron: "0,30 * * * * America/New_York"
cron: "*/2 * * * * America/New_York"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Similar to the job above, and every two minutes seemed reasonable enough to catch records that we failed to receive SNS notifications for. (This is a backup job for the /upload_complete endpoint.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
banana-peels Lighthouse Banana Peels Team console-services-review Lighthouse lighthouse
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants