urnauzao / php-jit-enabled-with-docker

PHP with JIT enabled, Dockerfile and Docker Compose stack

Home Page:https://youtu.be/ZJ1U3aOXd_g

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PHP with JIT enabled with Dockerfile and Docker Compose stack.

  • Neste projeto teremos um ambiente Docker com as configurações necessárias para ativar o JIT, além disso todo ambiente será feito com Docker e estará pronto para ser executado via Docker Compose.
  • O projeto será executado por padrão na porta 8000. Você pode acessar clicando aqui localhost:8000
  • Vídeos com todo o tutorial de utilização do JIT + Benchmarking

Scripts

  • Fazer buikd ambiente Docker
sh dc-build.sh
  • Subir ambiente Docker
sh dc-up.sh
  • Derrubar ambiente Docker
sh dc-down.sh
  • Reiniciar ambiente Docker
sh dc-restart.sh
  • Entrar no container do PHP
sh dc-container.sh
  • Checar se JIT está ativo
sh dc-check-jit.sh
  • Remover todos os logs/results/docs
rm -rf ./public/results/*.html
rm -rf ./public/docs/*.json
rm -rf ./public/logs/*.log

/////////////////////////////////////

Usando o Vegeta para test de stress

  • Confira o vídeo em que faço um tutorial sobre o uso do Vegeta https://youtu.be/FNj0e1ZT4fI

  • Dentro do terminal WSL, já com o Vegeta configurado, execute:

    # TESTE 1 - Script teste5.php
    #### Com JIT max 900 | Sem JIT max 180 ####
    echo "GET http://127.0.0.1:8000/teste5.php" | vegeta attack -rate=900 -duration=30s | vegeta report

    # Teste 2 - Script index.php
    #### Com Jit Max 3700 | Sem JIT max 4100
    echo "GET http://127.0.0.1:8000/index.php" | vegeta attack -rate=3700 -duration=10s | vegeta report

About

PHP with JIT enabled, Dockerfile and Docker Compose stack

https://youtu.be/ZJ1U3aOXd_g

License:MIT License


Languages

Language:PHP 98.0%Language:Dockerfile 1.7%Language:Shell 0.3%