Skip to content

Commit

Permalink
remove dependency on rabbitmq (#86)
Browse files Browse the repository at this point in the history
  • Loading branch information
KentonParton authored Apr 25, 2023
1 parent 1a41904 commit 5719b7b
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 16 deletions.
2 changes: 1 addition & 1 deletion backend/app/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ class Settings(BaseSettings):
CELERY_INDEX: str = "celery"

SWIPLE_CELERY_CONFIG: dict = {
"broker_url": "pyamqp://localhost:5672",
"broker_url": "redis://redis:6379/1",
"result_backend": "app.worker.backends.opensearch.OpenSearchBackend://_:_@_:9200/celery",
"task_default_queue": "swiple-job-queue",
"task_soft_time_limit": "5400", # SOFT LIMIT: 90 minutes
Expand Down
7 changes: 0 additions & 7 deletions docker-compose-non-dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,6 @@ services:
depends_on:
- "swiple_api"

rabbit:
image: rabbitmq:3.9
ports:
- 5672:5672
- 15672:15672

celery_worker:
container_name: celery_worker
env_file: docker/.env
Expand All @@ -71,7 +65,6 @@ services:
environment:
<<: *aws-creds
depends_on:
- rabbit
- swiple_api

setup:
Expand Down
7 changes: 0 additions & 7 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,12 +73,6 @@ services:
volumes:
- ./backend/app/sample_data/:/code/app/sample_data/
rabbit:
image: rabbitmq:3.9
ports:
- 5672:5672
- 15672:15672
celery_worker:
container_name: celery_worker
env_file: docker/.env
Expand All @@ -90,7 +84,6 @@ services:
environment:
<<: *aws-creds
depends_on:
- rabbit
- swiple_api
postgres:
Expand Down
1 change: 0 additions & 1 deletion docker/.env
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,3 @@ [email protected]
ADMIN_PASSWORD=AdminUser12!
SECRET_KEY=jSE9Q7_5g1MDpCz7wU1xmcmz27RhSo8nRXCPRjjE6dg=
AUTH_COOKIE_SECURE=False
SWIPLE_CELERY_CONFIG='{"broker_url": "pyamqp://rabbit:5672", "result_backend": "app.worker.backends.opensearch.OpenSearchBackend://_:_@_:9200/celery", "task_default_queue": "swiple-job-queue", "task_soft_time_limit": "5400", "task_time_limit": "5700", "worker_prefetch_multiplier": "1"}'
2 changes: 2 additions & 0 deletions docker/.env-local
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,5 @@ [email protected]
ADMIN_PASSWORD=AdminUser12!
SECRET_KEY=jSE9Q7_5g1MDpCz7wU1xmcmz27RhSo8nRXCPRjjE6dg=
AUTH_COOKIE_SECURE=False

SWIPLE_CELERY_CONFIG='{"broker_url": "redis://localhost:6379/1", "result_backend": "app.worker.backends.opensearch.OpenSearchBackend://_:_@_:9200/celery", "task_default_queue": "swiple-job-queue", "task_soft_time_limit": "5400", "task_time_limit": "5700", "worker_prefetch_multiplier": "1"}'

0 comments on commit 5719b7b

Please sign in to comment.