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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
config.vm.box = "ubuntu/trusty64" | |
config.vm.hostname = "cygnus" | |
config.vm.network "private_network", ip: "192.168.33.10" | |
config.vm.provision "shell", path: "setup_environment.sh" | |
end |
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
alias vi='vim' | |
alias ls='ls -lh --color=auto' | |
export LC_ALL=C.UTF-8 | |
export LANG=C.UTF-8 | |
export FLASK_APP=runserver.py |
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
[supervisord] | |
# [program:<samplepyservice>] | |
[program:myapp] | |
# directory=<path_to_project> | |
directory=/var/www/myapp | |
# command=<path_to_project_env>/env/bin/gunicorn -b 127.0.0.1:<port_num> -w 4 <app_name>:app | |
command=/var/www/myapp/env/bin/gunicorn -b 127.0.0.1:5000 -w 4 myapp:app | |
autostart=true | |
autorestart=true | |
# user=<username> |
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
# Refer https://adikrishnan.in/2018/05/30/celery-groups-loops-parallelism/ for understanding the concept. | |
from tasks import run_ping, hello, loop_service, group_service | |
hello.delay() | |
loop_service.delay() | |
group_service.delay() |
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
# Refer https://adikrishnan.in/2018/05/30/playing-with-chords-celery/ for understanding the concept. | |
from tasks import hello, chord_service, non_chord_service | |
hello.delay() | |
chord_service.delay() | |
non_chord_service.delay() |
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
from tasks import hello, timeout_test, retry_timeout_test, max_retries_test, max_retries_test_2 | |
hello.delay() | |
timeout_test.delay() | |
retry_timeout_test.delay() | |
max_retries_test.delay() | |
max_retries_test_2.delay() |
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
from tasks import timeout_and_chords | |
timeout_and_chords.delay() |
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
Parser Type | File Size / Data Size | Number of Lines | Time Taken | Memory Consumed | |
---|---|---|---|---|---|
pygrok based Parser | 50kb / 2.5kb | 302 | 1.43s | 40.3MiB | |
Custom Parser [O(mxn)] | 50 kb / 2.5kb | 302 | 0.14s | 40.5MiB | |
Improvements | - | - | ~920% [Time reduction] | ~-0.49% [Space increase] |