Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
configuration
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
configuration
Commits
2cb13471
Commit
2cb13471
authored
Oct 26, 2015
by
Clinton Blackburn
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2409 from edx/clinton/revert-gunicorn-change
Reverted changes to ecommerce-related gunicorn files
parents
1b23f9d9
1fa7f538
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
33 deletions
+0
-33
playbooks/roles/ansible-role-django-ida/templates/templates/edx/app/ROLE_NAME/ROLE_NAME_gunicorn.py.j2
+0
-11
playbooks/roles/ecommerce/templates/edx/app/ecommerce/ecommerce_gunicorn.py.j2
+0
-11
playbooks/roles/programs/templates/edx/app/programs/programs_gunicorn.py.j2
+0
-11
No files found.
playbooks/roles/ansible-role-django-ida/templates/templates/edx/app/ROLE_NAME/ROLE_NAME_gunicorn.py.j2
View file @
2cb13471
...
...
@@ -9,15 +9,4 @@ pythonpath = "{{ '{{' }} {{ role_name }}_code_dir }}"
workers = {{ '{{' }} {{ role_name|upper }}_GUNICORN_WORKERS }}
worker_class = "{{ '{{' }} {{ role_name|upper }}_GUNICORN_WORKER_CLASS }}"
def post_fork(server, worker):
"""
Close the cache so that newly forked workers cannot accidentally share the
socket with the processes they were forked from. This prevents a race
condition in which one worker could get a cache response intended for
another worker.
"""
from django.core.cache import cache
if hasattr(cache, 'close'):
cache.close()
{{ '{{' }} {{ role_name|upper }}_GUNICORN_EXTRA_CONF }}
playbooks/roles/ecommerce/templates/edx/app/ecommerce/ecommerce_gunicorn.py.j2
View file @
2cb13471
...
...
@@ -9,15 +9,4 @@ pythonpath = "{{ ecommerce_code_dir }}"
workers = {{ ECOMMERCE_GUNICORN_WORKERS }}
worker_class = "{{ ECOMMERCE_GUNICORN_WORKER_CLASS }}"
def post_fork(server, worker):
"""
Close the cache so that newly forked workers cannot accidentally share the
socket with the processes they were forked from. This prevents a race
condition in which one worker could get a cache response intended for
another worker.
"""
from django.core.cache import cache
if hasattr(cache, 'close'):
cache.close()
{{ ECOMMERCE_GUNICORN_EXTRA_CONF }}
playbooks/roles/programs/templates/edx/app/programs/programs_gunicorn.py.j2
View file @
2cb13471
...
...
@@ -9,15 +9,4 @@ pythonpath = "{{ programs_code_dir }}"
workers = {{ PROGRAMS_GUNICORN_WORKERS }}
worker_class = "{{ PROGRAMS_GUNICORN_WORKER_CLASS }}"
def post_fork(server, worker):
"""
Close the cache so that newly forked workers cannot accidentally share the
socket with the processes they were forked from. This prevents a race
condition in which one worker could get a cache response intended for
another worker.
"""
from django.core.cache import cache
if hasattr(cache, 'close'):
cache.close()
{{ PROGRAMS_GUNICORN_EXTRA_CONF }}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment