TL;DR
Install Postgres 9.6, and then:
sudo pg_dropcluster 9.6 main --stop
sudo pg_upgradecluster 9.5 main
sudo pg_dropcluster 9.5 main| #!/usr/bin/env bash | |
| # https://docs.docker.com/install/linux/docker-ce/ubuntu/ | |
| sudo apt-get install apt-transport-https ca-certificates curl software-properties-common | |
| curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - | |
| sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable" | |
| sudo apt-get update | |
| sudo apt-get install docker-ce | |
| # https://docs.docker.com/compose/install/ |
TL;DR
Install Postgres 9.6, and then:
sudo pg_dropcluster 9.6 main --stop
sudo pg_upgradecluster 9.5 main
sudo pg_dropcluster 9.5 mainEach of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| <?php | |
| namespace App\Traits; | |
| use Monolog\Formatter\FormatterInterface; | |
| use Monolog\Formatter\JsonFormatter; | |
| use Monolog\Formatter\LineFormatter; | |
| use Monolog\Handler\RotatingFileHandler; | |
| use Monolog\Logger; | |
| use Monolog\Processor\GitProcessor; |
| ############################## | |
| ## Java | |
| ############################## | |
| .mtj.tmp/ | |
| *.class | |
| *.jar | |
| *.war | |
| *.ear | |
| *.nar | |
| hs_err_pid* |
| ## Consumer Throughput: Single consumer thread, no compression | |
| ## Consumer Throughput: 3 consumer thread, no compression | |
| bin/kafka-consumer-perf-test.sh --topic benchmark-3-3-none \ | |
| --zookeeper kafka-zk-1:2181,kafka-zk-2:2181,kafka-zk-3:2181 \ | |
| --messages 15000000 \ | |
| --threads 1 |
For this configuration you can use web server you like, i decided, because i work mostly with it to use nginx.
Generally, properly configured nginx can handle up to 400K to 500K requests per second (clustered), most what i saw is 50K to 80K (non-clustered) requests per second and 30% CPU load, course, this was 2 x Intel Xeon with HyperThreading enabled, but it can work without problem on slower machines.
You must understand that this config is used in testing environment and not in production so you will need to find a way to implement most of those features best possible for your servers.
| # source: https://github.com/kiasaki/docker-alpine-postgres | |
| FROM alpine | |
| RUN echo "@edge http://nl.alpinelinux.org/alpine/edge/main" >> /etc/apk/repositories && \ | |
| apk update && \ | |
| apk add curl "libpq@edge<9.7" "postgresql-client@edge<9.7" "postgresql@edge<9.7" "postgresql-contrib@edge<9.7" && \ | |
| curl -o /usr/local/bin/gosu -sSL "https://github.com/tianon/gosu/releases/download/1.2/gosu-amd64" && \ | |
| chmod +x /usr/local/bin/gosu && \ | |
| apk del curl && \ | |
| rm -rf /var/cache/apk/* |
| package cache | |
| import ( | |
| "crypto/sha256" | |
| "encoding/json" | |
| "fmt" | |
| "os" | |
| "sync" | |
| "time" | |
| ) |
... or Why Pipelining Is Not That Easy
Golang Concurrency Patterns for brave and smart.
By @kachayev