Skip to content

Commit

Permalink
Scalability Enhancements (#14)
Browse files Browse the repository at this point in the history
* forcing restart of webserver every 10m since gunicorn keeps dying :(
* adding more max connections and shared memory to postgres to connect  more workers
* Increase sql_alchemy_pool_size
* Adding subnet configuration to allow for more ip addresses
* removing dag accidentally checked in from previous merge
  • Loading branch information
wongwill86 authored Dec 8, 2017
1 parent c68bb3a commit 66f42b2
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 34 deletions.
33 changes: 0 additions & 33 deletions dags/examples/gpu.py

This file was deleted.

2 changes: 1 addition & 1 deletion docker/config/airflow.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ sql_alchemy_conn = postgresql+psycopg2://airflow:airflow@postgres/airflow

# The SqlAlchemy pool size is the maximum number of database connections
# in the pool.
sql_alchemy_pool_size = 5
sql_alchemy_pool_size = 300

# The SqlAlchemy pool recycle is the number of seconds a connection
# can be idle in the pool before it is invalidated. This config does
Expand Down
13 changes: 13 additions & 0 deletions docker/docker-compose-CeleryExecutor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ services:
deploy:
placement:
constraints: [ engine.labels.infrakit-role == manager ]
command: postgres -c max_connections=1000 -c shared_buffers=4096MB

webserver:
image: wongwill86/air-tasks:latest
Expand Down Expand Up @@ -50,6 +51,10 @@ services:
deploy:
placement:
constraints: [ engine.labels.infrakit-role == manager ]
restart_policy:
condition: any
delay: 10m
window: 120s

flower:
image: wongwill86/air-tasks:latest
Expand Down Expand Up @@ -313,3 +318,11 @@ secrets:
external: true
ssl_certificate_key:
external: true

networks:
default:
attachable: true
ipam:
driver: default
config:
- subnet: 10.0.0.0/16

0 comments on commit 66f42b2

Please sign in to comment.