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

RFC: Use Redis as celery broker in dev environment #213

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

zachmullen
Copy link
Contributor

@zachmullen zachmullen commented Oct 10, 2024

This change is sufficient to switch celery to Redis in development.

For our standard deployment, using Redis will depend on kitware-resonant/django-composed-configuration#213 and a not yet complete PR to our terraform module that I'll link to this later.

@brianhelba
Copy link
Contributor

I've just rebased this and included the changes from kitware-resonant/django-composed-configuration#213 too. This can now be handled in this single PR.

Comment on lines 57 to 59
CELERY_BROKER_POOL_LIMIT = 1
CELERY_BROKER_HEARTBEAT = None
CELERY_BROKER_CONNECTION_TIMEOUT = 30
Copy link
Contributor

Choose a reason for hiding this comment

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

Are all of these values still the appropriate defaults?

If they need to be set per-deployment, these should be moved out of the resonant_settings shared package and into the cookiecutter files.

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 went back and forth on this -- on the one hand, yes, this is deployment-specific. On the other hand, quite a few of these settings within django-resonant-settings are also just sensible defaults and overriding them is common for specific applications and deployments. I don't have a strong opinion on whether we should hide this for cookiecutter ejections or not, so let me know which you prefer.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

To be concrete here, note that CELERY_WORKER_CONCURRENCY is also here in this package rather than in the cookiecutter, and that's extremely application- and deployment-specific.

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