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

Run dispatchProcesses on Heroku #1841

Merged
merged 3 commits into from
Jan 27, 2021

Conversation

jeffm2001
Copy link
Collaborator

Description

This adds a command for triggering dispatchProcesses on a Heroku install. When triggered, it runs the following jobs:

  • erroredMessageSender,
  • handleIncomingMessages,
  • checkMessageQueue,
  • fixOrgless,
  • clearOldJobs,
  • updateOptOuts

To use configure the Heroku Scheduler add on and add a job running every 10 minutes with the command yarn prod-heroku-dispatch.

Unfortunately, 10 minutes is the most frequent scheduling the heroku add-on allows, while AWS is set to dispatch every 5 minutes. Although, maybe every 10 minutes is good enough. If not, I may look into other options like a custom clock process or a worker using Bull.

Checklist:

  • I have manually tested my changes on desktop and mobile
  • The test suite passes locally with my changes
  • If my change is a UI change, I have attached a screenshot to the description section of this pull request
  • My change is 300 lines of code or less, or has a documented reason in the description why it’s longer
  • I have made any necessary changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • My PR is labeled [WIP] if it is in progress

Copy link
Collaborator

@schuyler1d schuyler1d left a comment

Choose a reason for hiding this comment

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

👍

@schuyler1d schuyler1d mentioned this pull request Dec 3, 2020
@schuyler1d schuyler1d merged commit dfe1ee9 into StateVoicesNational:main Jan 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants