Created
November 2, 2015 17:44
-
-
Save ultrabug/e863a7c7b1221b5e0783 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
from flask import Flask | |
from time import sleep | |
import uwsgi | |
app = Flask(__name__) | |
@app.route('/') | |
def cheap_me_maybe(): | |
""" | |
""" | |
sleep(0.1) | |
return "OK" | |
def graceful_reload(): | |
""" | |
""" | |
print('I got gracefully reloaded') | |
uwsgi.atexit = graceful_reload |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment